Returns or sets the status of the test after the test is complete.
Object.Status [ = enTestStatus ]
The Status property syntax has the following parts:
Name |
Type |
Description |
Object |
ATest |
ATest object |
enTestStatus |
enumATestStatus |
An integer specifying the status of this Test. |
enumATestStatus can be one of the following:
Name |
Value |
Description |
NONE |
0 |
None |
PASS |
1 |
Pass |
FAIL |
2 |
Fail |
ERR |
3 |
Error |
This Status property value is set by the ATEasy run-time from TestStatus after the test ends (after OnEndTest event). The test code need to set the TestStatus during the test (not the Test.Status). You can use the Status property after the test is complete. For example you can check the status of previous tests which already completed, please see an example below.
The following statement checks the status of the second test of the current task :
if Task.Tests(1).Status = FAIL
! do something
endif
Status Property (AProgram), Status Property (ATask), TestStatus Variable