![]() |
OTX Reference
|
|
A TestResultState is an enumeration type describing the state of the test result evaluation. The allowed values are specified in the TestResultStates enumeration More...
Public Attributes | |
TestResultStateLiteral | init |
This optional element stands for the hard-coded initialisation value of the identifier at declaration time. More... | |
A TestResultState is an enumeration type describing the state of the test result evaluation. The allowed values are specified in the TestResultStates enumeration
All TestResultContainers in the TestResultHandling data model shall have a defined TestResultState with NOT_TESTED as the initial value.
It is possible, that there are TestResultContainers, which have got no own test result but consist of child TestResultContainers.In this case the TestResultContainer gets the highest-order TestResultState of its children.This rule leads to the following behaviour:
The parent TestResultContainer's TestResultState shall reflect the most critical TestResultState of its child TestResultContainers TestResultStates.E.g.the parent TestResultContainer TestResultState is OK, if at least one child TestResultContainer TestResultState is OK and no one is NOT_OK or ERROR or NOT_TESTED.
Order Relation
TestResultState values may occur as operands of comparisons (cf. ISO 13209-2, 7.15.8). For this case, the following order relation will apply:
NOT_TESTED < ERROR < NOT_OK < OK < INFO < NOT_AVAILABLE
Literal
The syntax for Literals for complex data types will be used, where the member value is one of the values in the list.
@TestResultState:NOT_TESTED|ERROR|NOT_OK|OK|INFO|NOT_AVAILABLE
Conversion terms
The following table shows the rules for conversion to another data type:
Conversion | Result | Sample |
---|---|---|
ToBoolean | Undefined (should not be used) | |
ToInteger | Returns the index of the value in the TestResultStates enumeration (smallest index is 0) | Integer val = ToInteger(@TestResultStates:NOT_TESTED); // Returns 0 |
ToFloat | Undefined (should not be used) | |
ToString | The resulting string will be the name of the enumeration value | String s = ToString(@TestResultStates:NOT_OK); // Returns "NOT_OK" |
ToByteField | Undefined (should not be used) |
Sample
TestResultHandling.TestResultState TestResultState1 = @TestResultState:NOT_TESTED;
TestResultStateLiteral OpenTestSystem.Otx.Extensions.TestResultHandling.DataTypes.TestResultState.init |
This optional element stands for the hard-coded initialisation value of the identifier at declaration time.
This attribute shall contain one of the values defined in the TestResultStates enumeration. IMPORTANT - If the TestResultState declaration is not explicitly initialised(omitted < init> element), the default value shall be NOT_TESTED.