Forum Discussion

mpw83's avatar
mpw83
Contributor
5 years ago
Solved

Run a test case only if specified test case is passed

I have a test case called 'Fund loans'. In this Test case, I have a step called "Funded by Investor".  What this is doing, funding the loan by the investor. To fund the loan, the investor should have...
  • jsheph01's avatar
    5 years ago

    On your second if statement try adding .toString() after status. After I did that, funds added printed in my log

    if (r.status.toString() == 'PASS' ) {

    Also I think you need to use double quotes when you try to run the test step by name. That did not work for me until I changed it.

     

    testRunner.runTestStepByName("Add Funds to Investor");