We've started looking at using the saved test cases functionality and startR

Certified Senior Developer
We've started looking at using the saved test cases functionality and startRuleTestsApplications (and related) functions to run daily tests of all of our expression rules but am unsure how best to include tests for expressions that retrieve data from a database table. Given that the tests can either check that there was no error (of limited use), check that the output matches a given value or test that an assertion is true we're struggling to see how this can be made dynamic. In our current, process model based testing framework, we have used a Query Database node to directly query the database table to get both valid input parameters and expected output, before calling the expression rule with differing input parameters and then asserting the actual expression results matches the expected results. If we were trying to replicate this using the saved test cases we would have to be using another expression to return the expected result bu...

OriginalPostID-225576

OriginalPostID-225576

  Discussion posts and replies are publicly visible

Parents
  • 0
    Certified Senior Developer
    Thanks for the response Tom, it's much as I suspected. I suspect that, for simple queries we'll rely on testing that there are no errors and for more complex expressions we'll separate the query from any additional logic and inject the query results into that expression, in that way we can more thoroughly test the additional logic.
Reply
  • 0
    Certified Senior Developer
    Thanks for the response Tom, it's much as I suspected. I suspect that, for simple queries we'll rely on testing that there are no errors and for more complex expressions we'll separate the query from any additional logic and inject the query results into that expression, in that way we can more thoroughly test the additional logic.
Children
No Data