GetUutStatus Procedure

Returns the status of the current program.

Syntax

[ enStatus = ] GetUutStatus ( [pnStatus] [, pnFails] [, pnFlags] [, pdElapsedTime] )

The GetUutStatus procedure syntax has the following parts:

 

Name

Type

Description

enStatus

enumATestStatus

The UUT status enumerated type

pnStatus

[Var] Short

Returned. The UUT status, same value as enStatus.

pnFails

[Var] Short

Returned. Number of tests which have failed since the current program started.

plFlags

[Var] Long

Returned application flags See Comments section  below.

pdElapsedTime

[Var] Double

Returned. Time elapsed since this program started in seconds..

Where

enumATestStatus can be one of the following TestStatus values:

 

Name

Value

Description

NONE

0

None

PASS

1

Pass

FAIL

2

Fail

ERR

3

Error

Comments

Each bit in lFlags represents a condition that occurred since Run-Start was selected or since GetUutStatus was last executed. The conditions are listed below. Each bit is set to 1 if the condition occurred, or to 0 if it didn't. The flags are the same as AProgram.Flags property. The following bits are available:

 

Name

Value

Description

aFlagsTaskSkipped

0x00000001

Task Skipped

aFlagsTestSkipped

0x00000002

Test Skipped

aFlagsLoopOnTestCalled

0x00000004

Loop On Test Called

aFlagsCurrentTestCalled

0x00000008

Current Test Called

aFlagsStepTraceCalled

0x00000010

Step/Trace Called

aFlagsDoitLoopitCalled

0x00000020

Doit/Loopit

aFlagsPauseCalled

0x00000040

Pause

aFlagsAbortCalled

0x00000080

Abort

aFlagsErrorCalled

0x00000100

Error

aFlagsIgnoreCalled

0x00000200

Ignore

aFlagsRetryCalled

0x00000400

Retry

aFlagsValueChanged

0x00000800

Change Value

aFlagsSetNextStatementCalled

0x00001000

Set Next Statement

aFlagsSerialNumber

0x00010000

Serial Number

aFlagsProfile

0x00020000

Profile

aFlagsTaskByTask

0x00040000

Task By Task

aFlagsTestByTest

0x00080000

Test By Test

aFlagsStopOnFail

0x00100000

Stop On Fail

aFlagsLoopOnTest

0x01000000

Loop On Test

aFlagsCurrentTest

0x02000000

Current Test

aFlagsStepTrace

0x04000000

Step/Trace

aFlagsDoitLoopit

0x08000000

Doit/Loopit

The pdElapsedTime specifies the elapsed time in seconds since the current running program was started.

Each status can be accessed via the internal variable, AProgram and its properties: Status, Flags, Fails, ElapsedTime.

Example

OnEndProgram ( )

{

GetUutStatus (nStatus, nFails, lFlags, dTime)

If nStatus = PASS Then

Print "This UUT PASSED"

Else

Print "This UUT FAILED"

Endif

}

See Also

AProgramStatus, AProgram, AProgramElapsedTime, AProgramFails, GetUserLevel, AApp.Flags