Refactor/property lists member function (#609)

* Refactor property lists member function for WriteProperty default case.

* Refactor time-value object unit testing

* Added test for unsupported property to common property test
This commit is contained in:
Steve Karg
2024-03-27 09:52:01 -05:00
committed by GitHub
parent 4e0a37fd75
commit 6bd1942635
14 changed files with 118 additions and 304 deletions
+10
View File
@@ -170,6 +170,7 @@ void bacnet_object_properties_read_write_test(BACNET_OBJECT_TYPE object_type,
const int *pProprietary = NULL;
unsigned count = 0;
int len = 0;
bool status = false;
/* ReadProperty parameters */
rpdata.application_data = &apdu[0];
@@ -207,4 +208,13 @@ void bacnet_object_properties_read_write_test(BACNET_OBJECT_TYPE object_type,
&wpdata, write_property, skip_fail_property_list);
pProprietary++;
}
/* check for unsupported property - use ALL */
rpdata.object_property = PROP_ALL;
rpdata.array_index = BACNET_ARRAY_ALL;
len = read_property(&rpdata);
zassert_equal(len, BACNET_STATUS_ERROR, NULL);
wpdata.object_property = PROP_ALL;
wpdata.array_index = BACNET_ARRAY_ALL;
status = write_property(&wpdata);
zassert_false(status, NULL);
}