Bugfix/property list consistency testing (#910)
* Added unit test while reading all object properties to flag properties not in the property-list. * Added enumeration for last-property used in unit testing. * Added missing reliability property in the basic multistate output object example. * Removed polarity property in binary value object as it is not standard.
This commit is contained in:
@@ -55,23 +55,28 @@ static const char *Default_State_Text = "State 1\0"
|
||||
"State 2\0"
|
||||
"State 3\0";
|
||||
/* These three arrays are used by the ReadPropertyMultiple handler */
|
||||
static const int Properties_Required[] = { PROP_OBJECT_IDENTIFIER,
|
||||
PROP_OBJECT_NAME,
|
||||
PROP_OBJECT_TYPE,
|
||||
PROP_PRESENT_VALUE,
|
||||
PROP_STATUS_FLAGS,
|
||||
PROP_EVENT_STATE,
|
||||
PROP_OUT_OF_SERVICE,
|
||||
PROP_NUMBER_OF_STATES,
|
||||
PROP_PRIORITY_ARRAY,
|
||||
PROP_RELINQUISH_DEFAULT,
|
||||
static const int Properties_Required[] = {
|
||||
/* list of required properties in the object */
|
||||
PROP_OBJECT_IDENTIFIER,
|
||||
PROP_OBJECT_NAME,
|
||||
PROP_OBJECT_TYPE,
|
||||
PROP_PRESENT_VALUE,
|
||||
PROP_STATUS_FLAGS,
|
||||
PROP_EVENT_STATE,
|
||||
PROP_OUT_OF_SERVICE,
|
||||
PROP_NUMBER_OF_STATES,
|
||||
PROP_PRIORITY_ARRAY,
|
||||
PROP_RELINQUISH_DEFAULT,
|
||||
#if (BACNET_PROTOCOL_REVISION >= 17)
|
||||
PROP_CURRENT_COMMAND_PRIORITY,
|
||||
PROP_CURRENT_COMMAND_PRIORITY,
|
||||
#endif
|
||||
-1 };
|
||||
-1
|
||||
};
|
||||
|
||||
static const int Properties_Optional[] = { PROP_STATE_TEXT, PROP_DESCRIPTION,
|
||||
-1 };
|
||||
static const int Properties_Optional[] = {
|
||||
/* list of required properties in the object */
|
||||
PROP_STATE_TEXT, PROP_DESCRIPTION, PROP_RELIABILITY, -1
|
||||
};
|
||||
|
||||
static const int Properties_Proprietary[] = { -1 };
|
||||
|
||||
|
||||
Reference in New Issue
Block a user