SJ1
7 years agoOccasional Contributor
How to get the test case execution status(pass/fail) after the test run?
Hi, A newbie question - I have a set of tests which are being executed in TestComplete 12.5.
1. How do we add assertion for the test case's expected result?
2. Also, can you assist me wi...
- 7 years ago
For your assertions, take a look at Property Checkpoints:
https://support.smartbear.com/testcomplete/docs/testing-with/checkpoints/property/about.html
Here's some information about exporting log results. See if this works for what you want. If not, give us some more specific details about what you are trying to do and we can help further.
https://support.smartbear.com/testcomplete/docs/testing-with/log/working-with/exporting/about.html
- 7 years ago
I use this in an on test stop event handler:
function GetTestStatus() { Let result = "CHECK"; try { if(Log.ErrCount == 0) { result = "PASSED"; } else { result = "FAILED"; } } catch(err) { Log.Warning(err); } finally { return result; } }
It returns the number of errors in the currently running test item.