Loading
feat(entity-attributes): Set Attribute Value (§7.6 PUT) - value, observedAt, errors
Adds Test Cases for Set Attribute Value, PUT /entities/{entityId}/attrs/{attrId}/value (TS 104 176 clause 7.6.3.2; TS 104 175 clause 10.2.6). Based on develop. It follows !327 (merged) and !333 (merged), which are merged.
- 063_01: the value is replaced and the Attribute is still a Property (204).
- 063_02: observedAt takes the value of the observedAt parameter, and is removed without it.
- 063_03: the errors, with the ProblemDetails type checked:
- 400 BadRequestData: an entity id that is not a URI, and setting the value of scope;
- 400 InvalidRequest: a body that is not JSON, and the value null;
- 404: an unknown entity, and an unknown attribute.
These Test Cases use the same conventions as !327 (merged):
- tagged
since_ts104_v1.1.1, because the operation has no ETSI GS CIM 009 counterpart; - the template argument is named after its column.
The MR adds the request keyword in ContextInformationProvision.resource and its entries in the documentation generator.
Coverage (scripts/api_coverage), for PUT …/attrs/{attrId}/value:
- operations: +1;
- URL parameters: 0 → 1 of 3;
- status codes: 0 → 3 of 4 (204, 400, 404; 207 needs a registered context source).
Checks: 9 Test Cases, all of which pass against coraine. Also run: robocop format --check, robot --dryrun, the documentation generator, doc/tests (13/13), statistics.
Edited by Ken Zangelin