Reputation: 2387
I'm currently facing a problem with ReadyAPI testRunner results. In order to design my tests, I use a small teardown script in order to check my testCase's steps status:
log.info "****************** EXECUTION SUMMARY *****"
log.info "nb test steps = "+ testRunner.getTestCase().getTestStepCount()
for (testStep in testRunner.getResults()){
log.info "step " + testStep.getTestStep().getName() + " : " + testStep.getStatus()
}
log.info "**********************************************"
In most of my tests it fits my requirements but I have a test that gives me incoherent results, ie. It contains 10 steps and displays results for only the five latest
:INFO:nb steps : 10
:INFO:step pending or success : OK
:INFO:step while pending : OK
:INFO:step GetPendingRequest - terminated : OK
:INFO:step while not terminated : OK
:INFO:step disconnect : OK
I have another test from another testSuite which contains similar test structure and which gives me a correct output. I event tried to modify both testCases in order to have the same sequence but I still have the problem.
Has someone already been through an issue like this one ? Any help appreciated
here is a screenshot : Copy of TTM API has the problem, Copy of Use Cases don't
Upvotes: 0
Views: 725
Reputation: 81
It looks like not all your steps have results. You can add testRunner.getResults().size()
to your teardown script to confirm how many of your steps have results.
I can't find confirmation on when a step result is created, but the documentation for getResults()
says
it "Gets the accumulated results so far; each TestStep returns a TestStepResult when running."
Upvotes: 1