Status Property (ATest)

Returns or sets the status of the test after the test is complete.

Syntax

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.

Where

enumATestStatus can be one of the following:

 

Name

Value

Description

NONE

0

None

PASS

1

Pass

FAIL

2

Fail

ERR

3

Error

Comment

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.

Example

The following statement checks the status of the second test of the current task :

if Task.Tests(1).Status = FAIL

! do something

endif

Applies to

ATest

See Also

Status Property (AProgram), Status Property (ATask), TestStatus Variable