Skip to content

Validator_Test

class Validator_Test : public CPPUNIT_NS::TestFixture

Functions

Name Description
testTableOptionalColumn @brief Checks that optional columns with default values in the row schema are properly initialized to their default values, even when the default row value for the table element is an empty Hash.
testTableMandatoryColumn @brief Checks that mandatory columns in the row schema are indeed required.
testTableMinMaxRows @brief Checks that minSize and maxSize attributes for table elements size are enforced.
testColumnMinMaxAttrs @brief Checks that minInc, maxInc, minExc, and maxExc attributes for table cells (elements in the RowSchema) are enforced.
testVectorCharVectorByteSize @brief Checks that minSize and maxSize attributes are enforced for vector types VECTOR_CHAR_ELEMENT and VECTOR_UINT8_ELEMENT.
testState @brief Checks that the validator rejects non standard states and sets the indicate attribute
testAlarms @brief Checks that the validator rejects non standard alarm strings and sets the indicate attribute
testSlots @brief Checks that the Validator::validate does not create nodes for slots
testLeafAssignmentInternal @brief Checks that the Validator::validate can verify for assignment internal leaf elements
testOutputChannelSchemaRemoval @brief An output channel should not expose its schema node should for its configuration.
testPropertyTestValidation @brief Check validation for every property of PropertyTest class with 'reconfiguration' validation rules.

Function Details

testAlarms

void testAlarms()

@brief Checks that the validator rejects non standard alarm strings and sets the indicate attribute

testColumnMinMaxAttrs

void testColumnMinMaxAttrs()

@brief Checks that minInc, maxInc, minExc, and maxExc attributes for table cells (elements in the RowSchema) are enforced.

testLeafAssignmentInternal

void testLeafAssignmentInternal()

@brief Checks that the Validator::validate can verify for assignment internal leaf elements

testOutputChannelSchemaRemoval

void testOutputChannelSchemaRemoval()

@brief An output channel should not expose its schema node should for its configuration.

testPropertyTestValidation

void testPropertyTestValidation()

@brief Check validation for every property of PropertyTest class with 'reconfiguration' validation rules.

testSlots

void testSlots()

@brief Checks that the Validator::validate does not create nodes for slots

testState

void testState()

@brief Checks that the validator rejects non standard states and sets the indicate attribute

testTableMandatoryColumn

void testTableMandatoryColumn()

@brief Checks that mandatory columns in the row schema are indeed required.

An attempt to set the default value for the table rows with a mandatory column missing throws an exception (ParameterException).

A table element (actually a vector of Hashes with a defined RowSchema) fails validation if any mandatory column specified in the row schema is missing.

Note

As mandatory columns will be dropped in the future, this test case will only be kept until the dropping happens. In the meantime, the checkings made in here guarantee the contract of validation for mandatory columns.

testTableMinMaxRows

void testTableMinMaxRows()

@brief Checks that minSize and maxSize attributes for table elements size are enforced.

testTableOptionalColumn

void testTableOptionalColumn()

@brief Checks that optional columns with default values in the row schema are properly initialized to their default values, even when the default row value for the table element is an empty Hash.

The initialization is performed as part of the validation process.

testVectorCharVectorByteSize

void testVectorCharVectorByteSize()

@brief Checks that minSize and maxSize attributes are enforced for vector types VECTOR_CHAR_ELEMENT and VECTOR_UINT8_ELEMENT. Those two types are Base64 encoded when converted from/to strings, hence the special test case.