diff --git a/CHANGES_NEXT_RELEASE b/CHANGES_NEXT_RELEASE index e2326f8d7..4ae6ee2eb 100644 --- a/CHANGES_NEXT_RELEASE +++ b/CHANGES_NEXT_RELEASE @@ -1,3 +1,4 @@ +Use null instead of ' ' as default attribute value in entity provisioned (#938) Add: defaultEntityNameConjunction config (env var IOTA_DEFAULT_ENTITY_NAME_CONJUNCTION) and configuration group API field for default entity_name conjunction (#944) Add basic NGSI-LD support as experimental feature (#842) - Active measures diff --git a/lib/constants.js b/lib/constants.js index 7469ea52c..dd38aa93b 100644 --- a/lib/constants.js +++ b/lib/constants.js @@ -25,7 +25,7 @@ const LOCATION_DEFAULT = '0, 0'; const DATETIME_DEFAULT = '1970-01-01T00:00:00.000Z'; -const ATTRIBUTE_DEFAULT = ' '; +const ATTRIBUTE_DEFAULT = null; /** * Provides a default value for DateTime, GeoProperty and Property Attributes. @@ -82,6 +82,7 @@ module.exports = { MONGO_ALARM: 'MONGO-ALARM', ORION_ALARM: 'ORION-ALARM', IOTAM_ALARM: 'IOTAM-ALARM', + ATTRIBUTE_DEFAULT, DATETIME_DEFAULT, diff --git a/test/unit/examples/contextRequests/createMinimumProvisionedDevice.json b/test/unit/examples/contextRequests/createMinimumProvisionedDevice.json index 9c89b65a6..603149496 100644 --- a/test/unit/examples/contextRequests/createMinimumProvisionedDevice.json +++ b/test/unit/examples/contextRequests/createMinimumProvisionedDevice.json @@ -8,7 +8,7 @@ { "name": "attr_name", "type": "string", - "value": " " + "value": null } ] } diff --git a/test/unit/examples/contextRequests/createProvisionedDevice.json b/test/unit/examples/contextRequests/createProvisionedDevice.json index 03849801e..1854c5082 100644 --- a/test/unit/examples/contextRequests/createProvisionedDevice.json +++ b/test/unit/examples/contextRequests/createProvisionedDevice.json @@ -8,7 +8,7 @@ { "name": "attr_name", "type": "string", - "value": " " + "value": null }, { "name": "hardcodedAttr", diff --git a/test/unit/examples/contextRequests/createProvisionedDeviceMultientity.json b/test/unit/examples/contextRequests/createProvisionedDeviceMultientity.json index 03849801e..1854c5082 100644 --- a/test/unit/examples/contextRequests/createProvisionedDeviceMultientity.json +++ b/test/unit/examples/contextRequests/createProvisionedDeviceMultientity.json @@ -8,7 +8,7 @@ { "name": "attr_name", "type": "string", - "value": " " + "value": null }, { "name": "hardcodedAttr", diff --git a/test/unit/examples/contextRequests/createProvisionedDeviceWithGroup.json b/test/unit/examples/contextRequests/createProvisionedDeviceWithGroup.json index 495f2f78e..33bea352e 100644 --- a/test/unit/examples/contextRequests/createProvisionedDeviceWithGroup.json +++ b/test/unit/examples/contextRequests/createProvisionedDeviceWithGroup.json @@ -8,12 +8,12 @@ { "name": "attr_name", "type": "string", - "value": " " + "value": null }, { "name": "status", "type": "Boolean", - "value": " " + "value": null }, { "name": "hardcodedAttr", diff --git a/test/unit/examples/contextRequests/createProvisionedDeviceWithGroupAndStatic.json b/test/unit/examples/contextRequests/createProvisionedDeviceWithGroupAndStatic.json index 38b3b8a84..e4fd7ce7c 100644 --- a/test/unit/examples/contextRequests/createProvisionedDeviceWithGroupAndStatic.json +++ b/test/unit/examples/contextRequests/createProvisionedDeviceWithGroupAndStatic.json @@ -8,12 +8,12 @@ { "name": "attr_name", "type": "string", - "value": " " + "value": null }, { "name": "status", "type": "Boolean", - "value": " " + "value": null }, { "name": "hardcodedAttr", diff --git a/test/unit/examples/contextRequests/createProvisionedDeviceWithGroupAndStatic2.json b/test/unit/examples/contextRequests/createProvisionedDeviceWithGroupAndStatic2.json index 15945479b..6deb762c7 100644 --- a/test/unit/examples/contextRequests/createProvisionedDeviceWithGroupAndStatic2.json +++ b/test/unit/examples/contextRequests/createProvisionedDeviceWithGroupAndStatic2.json @@ -8,12 +8,12 @@ { "name": "attr_name", "type": "string", - "value": " " + "value": null }, { "name": "status", "type": "Boolean", - "value": " " + "value": null }, { "name": "hardcodedAttr", diff --git a/test/unit/examples/contextRequests/createTimeinstantDevice.json b/test/unit/examples/contextRequests/createTimeinstantDevice.json index a35d1962c..23beabd5c 100644 --- a/test/unit/examples/contextRequests/createTimeinstantDevice.json +++ b/test/unit/examples/contextRequests/createTimeinstantDevice.json @@ -8,7 +8,7 @@ { "name": "TimeInstant", "type": "ISO8601", - "value": " " + "value": null } ] } diff --git a/test/unit/examples/contextRequests/updateContext5.json b/test/unit/examples/contextRequests/updateContext5.json index da96ec560..0adfb3e16 100644 --- a/test/unit/examples/contextRequests/updateContext5.json +++ b/test/unit/examples/contextRequests/updateContext5.json @@ -6,14 +6,14 @@ "attributes": [{ "name": "state", "type": "Boolean", - "value": " " + "value": null }, { "name": "dimming", "type": "Percentage", - "value": " " + "value": null } ] }], "updateAction": "APPEND" -} \ No newline at end of file +} diff --git a/test/unit/examples/contextRequests/updateProvisionActiveAttributes1.json b/test/unit/examples/contextRequests/updateProvisionActiveAttributes1.json index fb532c48e..d3e7d7c2e 100644 --- a/test/unit/examples/contextRequests/updateProvisionActiveAttributes1.json +++ b/test/unit/examples/contextRequests/updateProvisionActiveAttributes1.json @@ -8,7 +8,7 @@ { "name": "temperature", "type": "centigrades", - "value": " " + "value": null } ] } diff --git a/test/unit/examples/contextRequests/updateProvisionCommands1.json b/test/unit/examples/contextRequests/updateProvisionCommands1.json index 182eb211f..4c1ef9281 100644 --- a/test/unit/examples/contextRequests/updateProvisionCommands1.json +++ b/test/unit/examples/contextRequests/updateProvisionCommands1.json @@ -8,7 +8,7 @@ { "name": "temperature", "type": "centigrades", - "value": " " + "value": null }, { "name": "move_status", diff --git a/test/unit/examples/contextRequests/updateProvisionDeviceStatic.json b/test/unit/examples/contextRequests/updateProvisionDeviceStatic.json index d924d298b..e455c60e7 100644 --- a/test/unit/examples/contextRequests/updateProvisionDeviceStatic.json +++ b/test/unit/examples/contextRequests/updateProvisionDeviceStatic.json @@ -8,7 +8,7 @@ { "name": "newAttribute", "type": "Integer", - "value": " " + "value": null }, { "name": "cellID", diff --git a/test/unit/examples/contextRequests/updateProvisionMinimumDevice.json b/test/unit/examples/contextRequests/updateProvisionMinimumDevice.json index dde579a2d..078c5849f 100644 --- a/test/unit/examples/contextRequests/updateProvisionMinimumDevice.json +++ b/test/unit/examples/contextRequests/updateProvisionMinimumDevice.json @@ -8,7 +8,7 @@ { "name": "newAttribute", "type": "Integer", - "value": " " + "value": null } ] } diff --git a/test/unit/examples/contextResponses/createBidirectionalDeviceSuccess.json b/test/unit/examples/contextResponses/createBidirectionalDeviceSuccess.json index 3b3f63b63..308978d0a 100644 --- a/test/unit/examples/contextResponses/createBidirectionalDeviceSuccess.json +++ b/test/unit/examples/contextResponses/createBidirectionalDeviceSuccess.json @@ -6,7 +6,7 @@ { "name": "location", "type": "geo:point", - "value": " " + "value": null } ], "id": "TheFirstLight", diff --git a/test/unit/examples/contextResponses/createTimeinstantSuccess.json b/test/unit/examples/contextResponses/createTimeinstantSuccess.json index cfe61d00d..e96978522 100644 --- a/test/unit/examples/contextResponses/createTimeinstantSuccess.json +++ b/test/unit/examples/contextResponses/createTimeinstantSuccess.json @@ -6,7 +6,7 @@ { "name": "TimeInstant", "type": "ISO8601", - "value": " " + "value": null } ], "id": "eii01201ttt", @@ -19,4 +19,4 @@ } } ] -} \ No newline at end of file +} diff --git a/test/unit/examples/contextResponses/updateProvisionCommands1Success.json b/test/unit/examples/contextResponses/updateProvisionCommands1Success.json index 1d5b5297c..a0b240b3b 100644 --- a/test/unit/examples/contextResponses/updateProvisionCommands1Success.json +++ b/test/unit/examples/contextResponses/updateProvisionCommands1Success.json @@ -6,7 +6,7 @@ { "name": "temperature", "type": "centigrades", - "value": " " + "value": null }, { "name": "move_status", diff --git a/test/unit/ngsi-ld/examples/contextRequests/createMinimumProvisionedDevice.json b/test/unit/ngsi-ld/examples/contextRequests/createMinimumProvisionedDevice.json index 376c3f0c7..34d51fd7d 100644 --- a/test/unit/ngsi-ld/examples/contextRequests/createMinimumProvisionedDevice.json +++ b/test/unit/ngsi-ld/examples/contextRequests/createMinimumProvisionedDevice.json @@ -3,7 +3,7 @@ "@context": "http://context.json-ld", "attr_name": { "type": "Property", - "value": " " + "value": null }, "id": "urn:ngsi-ld:MicroLights:FirstMicroLight", "type": "MicroLights" diff --git a/test/unit/ngsi-ld/examples/contextRequests/createProvisionedDevice.json b/test/unit/ngsi-ld/examples/contextRequests/createProvisionedDevice.json index 8f6dab919..61181f3ea 100644 --- a/test/unit/ngsi-ld/examples/contextRequests/createProvisionedDevice.json +++ b/test/unit/ngsi-ld/examples/contextRequests/createProvisionedDevice.json @@ -3,7 +3,7 @@ "@context": "http://context.json-ld", "attr_name": { "type": "Property", - "value": " " + "value": null }, "commandAttr_info": { "type": "Property", diff --git a/test/unit/ngsi-ld/examples/contextRequests/createProvisionedDeviceMultientity.json b/test/unit/ngsi-ld/examples/contextRequests/createProvisionedDeviceMultientity.json index 8f6dab919..61181f3ea 100644 --- a/test/unit/ngsi-ld/examples/contextRequests/createProvisionedDeviceMultientity.json +++ b/test/unit/ngsi-ld/examples/contextRequests/createProvisionedDeviceMultientity.json @@ -3,7 +3,7 @@ "@context": "http://context.json-ld", "attr_name": { "type": "Property", - "value": " " + "value": null }, "commandAttr_info": { "type": "Property", diff --git a/test/unit/ngsi-ld/examples/contextRequests/createProvisionedDeviceWithGroupAndStatic.json b/test/unit/ngsi-ld/examples/contextRequests/createProvisionedDeviceWithGroupAndStatic.json index dc380d561..52bb14d39 100644 --- a/test/unit/ngsi-ld/examples/contextRequests/createProvisionedDeviceWithGroupAndStatic.json +++ b/test/unit/ngsi-ld/examples/contextRequests/createProvisionedDeviceWithGroupAndStatic.json @@ -1,57 +1,57 @@ [ - { - "@context": "http://context.json-ld", - "attr_name": { - "type": "Property", - "value": " " - }, - "bootstrapServer": { - "type": "Property", - "value": { - "@type": "Address", - "@value": "127.0.0.1" - } - }, - "commandAttr_info": { - "type": "Property", - "value": { - "@type": "commandResult", - "@value": " " - } - }, - "commandAttr_status": { - "type": "Property", - "value": { - "@type": "commandStatus", - "@value": "UNKNOWN" - } - }, - "hardcodedAttr": { - "type": "Property", - "value": { - "@type": "hardcodedType", - "@value": "hardcodedValue" - } - }, - "id": "urn:ngsi-ld:TheLightType:TheFirstLight", - "status": { - "type": "Property", - "value": true - }, - "type": "TheLightType", - "wheel1_info": { - "type": "Property", - "value": { - "@type": "commandResult", - "@value": " " - } - }, - "wheel1_status": { - "type": "Property", - "value": { - "@type": "commandStatus", - "@value": "UNKNOWN" - } - } + { + "@context": "http://context.json-ld", + "id": "urn:ngsi-ld:TheLightType:TheFirstLight", + "type": "TheLightType", + "attr_name": { + "type": "Property", + "value": null + }, + "status": { + "type": "Property", + "value": false + }, + "hardcodedAttr": { + "type": "Property", + "value": { + "@type": "hardcodedType", + "@value": "hardcodedValue" + } + }, + "bootstrapServer": { + "type": "Property", + "value": { + "@type": "Address", + "@value": "127.0.0.1" + } + }, + "commandAttr_status": { + "type": "Property", + "value": { + "@type": "commandStatus", + "@value": "UNKNOWN" + } + }, + "commandAttr_info": { + "type": "Property", + "value": { + "@type": "commandResult", + "@value": " " + } + }, + "wheel1_status": { + "type": "Property", + "value": { + "@type": "commandStatus", + "@value": "UNKNOWN" + } + }, + "wheel1_info": { + "type": "Property", + "value": { + "@type": "commandResult", + "@value": " " + } } + } ] diff --git a/test/unit/ngsi-ld/examples/contextRequests/createProvisionedDeviceWithGroupAndStatic2.json b/test/unit/ngsi-ld/examples/contextRequests/createProvisionedDeviceWithGroupAndStatic2.json index 9ed0cf6ea..797f5e728 100644 --- a/test/unit/ngsi-ld/examples/contextRequests/createProvisionedDeviceWithGroupAndStatic2.json +++ b/test/unit/ngsi-ld/examples/contextRequests/createProvisionedDeviceWithGroupAndStatic2.json @@ -1,57 +1,57 @@ [ - { - "@context": "http://context.json-ld", - "attr_name": { - "type": "Property", - "value": " " - }, - "bootstrapServer": { - "type": "Property", - "value": { - "@type": "Address", - "@value": "127.0.0.1" - } - }, - "commandAttr_info": { - "type": "Property", - "value": { - "@type": "commandResult", - "@value": " " - } - }, - "commandAttr_status": { - "type": "Property", - "value": { - "@type": "commandStatus", - "@value": "UNKNOWN" - } - }, - "hardcodedAttr": { - "type": "Property", - "value": { - "@type": "hardcodedType", - "@value": "hardcodedValue" - } - }, - "id": "urn:ngsi-ld:SensorMachine:TheFirstLight", - "status": { - "type": "Property", - "value": true - }, - "type": "SensorMachine", - "wheel1_info": { - "type": "Property", - "value": { - "@type": "commandResult", - "@value": " " - } - }, - "wheel1_status": { - "type": "Property", - "value": { - "@type": "commandStatus", - "@value": "UNKNOWN" - } - } + { + "@context": "http://context.json-ld", + "id": "urn:ngsi-ld:SensorMachine:TheFirstLight", + "type": "SensorMachine", + "attr_name": { + "type": "Property", + "value": null + }, + "status": { + "type": "Property", + "value": false + }, + "hardcodedAttr": { + "type": "Property", + "value": { + "@type": "hardcodedType", + "@value": "hardcodedValue" + } + }, + "bootstrapServer": { + "type": "Property", + "value": { + "@type": "Address", + "@value": "127.0.0.1" + } + }, + "commandAttr_status": { + "type": "Property", + "value": { + "@type": "commandStatus", + "@value": "UNKNOWN" + } + }, + "commandAttr_info": { + "type": "Property", + "value": { + "@type": "commandResult", + "@value": " " + } + }, + "wheel1_status": { + "type": "Property", + "value": { + "@type": "commandStatus", + "@value": "UNKNOWN" + } + }, + "wheel1_info": { + "type": "Property", + "value": { + "@type": "commandResult", + "@value": " " + } } + } ] diff --git a/test/unit/ngsi-ld/examples/contextRequests/createProvisionedDeviceWithGroupAndStatic3.json b/test/unit/ngsi-ld/examples/contextRequests/createProvisionedDeviceWithGroupAndStatic3.json index 8e73199c8..c200aac5d 100644 --- a/test/unit/ngsi-ld/examples/contextRequests/createProvisionedDeviceWithGroupAndStatic3.json +++ b/test/unit/ngsi-ld/examples/contextRequests/createProvisionedDeviceWithGroupAndStatic3.json @@ -1,18 +1,18 @@ [ - { - "@context": "http://context.json-ld", - "dimming": { - "type": "Property", - "value": { - "@type": "Percentage", - "@value": " " - } - }, - "id": "urn:ngsi-ld:Light:light1", - "state": { - "type": "Property", - "value": true - }, - "type": "Light" + { + "@context": "http://context.json-ld", + "id": "urn:ngsi-ld:Light:light1", + "type": "Light", + "state": { + "type": "Property", + "value": false + }, + "dimming": { + "type": "Property", + "value": { + "@type": "Percentage", + "@value": null + } } + } ] diff --git a/test/unit/ngsi-ld/examples/contextRequests/createTimeInstantMinimumDevice.json b/test/unit/ngsi-ld/examples/contextRequests/createTimeInstantMinimumDevice.json index 376c3f0c7..34d51fd7d 100644 --- a/test/unit/ngsi-ld/examples/contextRequests/createTimeInstantMinimumDevice.json +++ b/test/unit/ngsi-ld/examples/contextRequests/createTimeInstantMinimumDevice.json @@ -3,7 +3,7 @@ "@context": "http://context.json-ld", "attr_name": { "type": "Property", - "value": " " + "value": null }, "id": "urn:ngsi-ld:MicroLights:FirstMicroLight", "type": "MicroLights" diff --git a/test/unit/ngsi-ld/examples/contextRequests/updateProvisionActiveAttributes1.json b/test/unit/ngsi-ld/examples/contextRequests/updateProvisionActiveAttributes1.json index 14d416828..3da7d7301 100644 --- a/test/unit/ngsi-ld/examples/contextRequests/updateProvisionActiveAttributes1.json +++ b/test/unit/ngsi-ld/examples/contextRequests/updateProvisionActiveAttributes1.json @@ -6,7 +6,7 @@ "type": "Property", "value": { "@type": "centigrades", - "@value": " " + "@value": null } }, "type": "Light" diff --git a/test/unit/ngsi-ld/examples/contextRequests/updateProvisionCommands1.json b/test/unit/ngsi-ld/examples/contextRequests/updateProvisionCommands1.json index 029eba449..301cc4847 100644 --- a/test/unit/ngsi-ld/examples/contextRequests/updateProvisionCommands1.json +++ b/test/unit/ngsi-ld/examples/contextRequests/updateProvisionCommands1.json @@ -20,7 +20,7 @@ "type": "Property", "value": { "@type": "centigrades", - "@value": " " + "@value": null } }, "type": "Light" diff --git a/test/unit/ngsiv2/examples/contextRequests/createAutoprovisionDevice.json b/test/unit/ngsiv2/examples/contextRequests/createAutoprovisionDevice.json index 49fc4f4ed..072b3dcbe 100644 --- a/test/unit/ngsiv2/examples/contextRequests/createAutoprovisionDevice.json +++ b/test/unit/ngsiv2/examples/contextRequests/createAutoprovisionDevice.json @@ -3,6 +3,6 @@ "type": "sensor", "TimeInstant": { "type": "ISO8601", - "value": " " + "value": null } } diff --git a/test/unit/ngsiv2/examples/contextRequests/createExplicitAttrsDevice.json b/test/unit/ngsiv2/examples/contextRequests/createExplicitAttrsDevice.json index 49fc4f4ed..072b3dcbe 100644 --- a/test/unit/ngsiv2/examples/contextRequests/createExplicitAttrsDevice.json +++ b/test/unit/ngsiv2/examples/contextRequests/createExplicitAttrsDevice.json @@ -3,6 +3,6 @@ "type": "sensor", "TimeInstant": { "type": "ISO8601", - "value": " " + "value": null } } diff --git a/test/unit/ngsiv2/examples/contextRequests/createMinimumProvisionedDevice.json b/test/unit/ngsiv2/examples/contextRequests/createMinimumProvisionedDevice.json index 2e85142d1..2307cdcfe 100644 --- a/test/unit/ngsiv2/examples/contextRequests/createMinimumProvisionedDevice.json +++ b/test/unit/ngsiv2/examples/contextRequests/createMinimumProvisionedDevice.json @@ -3,6 +3,6 @@ "type": "MicroLights", "attr_name": { "type": "string", - "value": " " + "value": null } -} \ No newline at end of file +} diff --git a/test/unit/ngsiv2/examples/contextRequests/createProvisionedDevice.json b/test/unit/ngsiv2/examples/contextRequests/createProvisionedDevice.json index c027d5f3e..c00dfd7df 100644 --- a/test/unit/ngsiv2/examples/contextRequests/createProvisionedDevice.json +++ b/test/unit/ngsiv2/examples/contextRequests/createProvisionedDevice.json @@ -3,7 +3,7 @@ "type": "TheLightType", "attr_name": { "type": "string", - "value": " " + "value": null }, "hardcodedAttr": { "type": "hardcodedType", @@ -17,4 +17,4 @@ "type": "commandResult", "value": " " } -} \ No newline at end of file +} diff --git a/test/unit/ngsiv2/examples/contextRequests/createProvisionedDeviceMultientity.json b/test/unit/ngsiv2/examples/contextRequests/createProvisionedDeviceMultientity.json index 1c9849dbf..03be61df8 100644 --- a/test/unit/ngsiv2/examples/contextRequests/createProvisionedDeviceMultientity.json +++ b/test/unit/ngsiv2/examples/contextRequests/createProvisionedDeviceMultientity.json @@ -3,7 +3,7 @@ "type":"TheLightType", "attr_name":{ "type": "string", - "value": " " + "value": null }, "hardcodedAttr": { "type": "hardcodedType", @@ -17,4 +17,4 @@ "type": "commandResult", "value": " " } -} \ No newline at end of file +} diff --git a/test/unit/ngsiv2/examples/contextRequests/createProvisionedDeviceWithGroupAndStatic.json b/test/unit/ngsiv2/examples/contextRequests/createProvisionedDeviceWithGroupAndStatic.json index 5cf84eb21..49dd1a6df 100644 --- a/test/unit/ngsiv2/examples/contextRequests/createProvisionedDeviceWithGroupAndStatic.json +++ b/test/unit/ngsiv2/examples/contextRequests/createProvisionedDeviceWithGroupAndStatic.json @@ -3,11 +3,11 @@ "type": "TheLightType", "attr_name": { "type": "string", - "value": " " + "value": null }, "status": { "type": "Boolean", - "value": " " + "value": null }, "hardcodedAttr": { "type": "hardcodedType", @@ -33,4 +33,4 @@ "type": "commandResult", "value": " " } -} \ No newline at end of file +} diff --git a/test/unit/ngsiv2/examples/contextRequests/createProvisionedDeviceWithGroupAndStatic2.json b/test/unit/ngsiv2/examples/contextRequests/createProvisionedDeviceWithGroupAndStatic2.json index 1b891f96f..a46cf9245 100644 --- a/test/unit/ngsiv2/examples/contextRequests/createProvisionedDeviceWithGroupAndStatic2.json +++ b/test/unit/ngsiv2/examples/contextRequests/createProvisionedDeviceWithGroupAndStatic2.json @@ -3,11 +3,11 @@ "type": "SensorMachine", "attr_name": { "type": "string", - "value": " " + "value": null }, "status": { "type": "Boolean", - "value": " " + "value": null }, "hardcodedAttr": { "type": "hardcodedType", @@ -33,4 +33,4 @@ "type": "commandResult", "value": " " } -} \ No newline at end of file +} diff --git a/test/unit/ngsiv2/examples/contextRequests/createProvisionedDeviceWithGroupAndStatic3.json b/test/unit/ngsiv2/examples/contextRequests/createProvisionedDeviceWithGroupAndStatic3.json index 228e2faeb..6d91e8e25 100644 --- a/test/unit/ngsiv2/examples/contextRequests/createProvisionedDeviceWithGroupAndStatic3.json +++ b/test/unit/ngsiv2/examples/contextRequests/createProvisionedDeviceWithGroupAndStatic3.json @@ -3,10 +3,10 @@ "type": "Light", "state": { "type": "Boolean", - "value": " " + "value": null }, "dimming": { "type": "Percentage", - "value": " " + "value": null } -} \ No newline at end of file +} diff --git a/test/unit/ngsiv2/examples/contextRequests/createStaticAttributesProvisionDevice.json b/test/unit/ngsiv2/examples/contextRequests/createStaticAttributesProvisionDevice.json index 24c216610..7f862e6b3 100644 --- a/test/unit/ngsiv2/examples/contextRequests/createStaticAttributesProvisionDevice.json +++ b/test/unit/ngsiv2/examples/contextRequests/createStaticAttributesProvisionDevice.json @@ -3,7 +3,7 @@ "type": "MicroLights", "attr_name": { "type": "string", - "value": " " + "value": null }, "bootstrapServer": { "type": "Address", diff --git a/test/unit/ngsiv2/examples/contextRequests/createStaticAttributesProvisionDevice2.json b/test/unit/ngsiv2/examples/contextRequests/createStaticAttributesProvisionDevice2.json index 27ca9795e..36ff489fd 100644 --- a/test/unit/ngsiv2/examples/contextRequests/createStaticAttributesProvisionDevice2.json +++ b/test/unit/ngsiv2/examples/contextRequests/createStaticAttributesProvisionDevice2.json @@ -3,7 +3,7 @@ "type": "MicroLights", "attr_name": { "type": "string", - "value": " " + "value": null }, "hardcodedAttr": { "type": "hardcodedType", diff --git a/test/unit/ngsiv2/examples/contextRequests/createStaticAttributesProvisionDevice3.json b/test/unit/ngsiv2/examples/contextRequests/createStaticAttributesProvisionDevice3.json index 98f978653..dfa658ca6 100644 --- a/test/unit/ngsiv2/examples/contextRequests/createStaticAttributesProvisionDevice3.json +++ b/test/unit/ngsiv2/examples/contextRequests/createStaticAttributesProvisionDevice3.json @@ -3,7 +3,7 @@ "type": "MicroLights", "attr_name": { "type": "string", - "value": " " + "value": null }, "bootstrapServer": { "type": "Address", diff --git a/test/unit/ngsiv2/examples/contextRequests/createTimeInstantMinimumDevice.json b/test/unit/ngsiv2/examples/contextRequests/createTimeInstantMinimumDevice.json index 2e85142d1..2307cdcfe 100644 --- a/test/unit/ngsiv2/examples/contextRequests/createTimeInstantMinimumDevice.json +++ b/test/unit/ngsiv2/examples/contextRequests/createTimeInstantMinimumDevice.json @@ -3,6 +3,6 @@ "type": "MicroLights", "attr_name": { "type": "string", - "value": " " + "value": null } -} \ No newline at end of file +} diff --git a/test/unit/ngsiv2/examples/contextRequests/createTimeinstantDevice.json b/test/unit/ngsiv2/examples/contextRequests/createTimeinstantDevice.json index a472b0980..fcb50354d 100644 --- a/test/unit/ngsiv2/examples/contextRequests/createTimeinstantDevice.json +++ b/test/unit/ngsiv2/examples/contextRequests/createTimeinstantDevice.json @@ -3,6 +3,6 @@ "type": "sensor", "TimeInstant": { "type": "ISO8601", - "value": " " + "value": null } } diff --git a/test/unit/ngsiv2/examples/contextRequests/updateProvisionActiveAttributes1.json b/test/unit/ngsiv2/examples/contextRequests/updateProvisionActiveAttributes1.json index ff38069ec..77df45b5c 100644 --- a/test/unit/ngsiv2/examples/contextRequests/updateProvisionActiveAttributes1.json +++ b/test/unit/ngsiv2/examples/contextRequests/updateProvisionActiveAttributes1.json @@ -1,6 +1,6 @@ { "temperature": { "type": "centigrades", - "value": " " + "value": null } -} \ No newline at end of file +} diff --git a/test/unit/ngsiv2/examples/contextRequests/updateProvisionCommands1.json b/test/unit/ngsiv2/examples/contextRequests/updateProvisionCommands1.json index 477b86a20..107676f02 100644 --- a/test/unit/ngsiv2/examples/contextRequests/updateProvisionCommands1.json +++ b/test/unit/ngsiv2/examples/contextRequests/updateProvisionCommands1.json @@ -1,7 +1,7 @@ { "temperature": { "type": "centigrades", - "value": " " + "value": null }, "move_status": { "type": "commandStatus", @@ -11,4 +11,4 @@ "type": "commandResult", "value": " " } -} \ No newline at end of file +} diff --git a/test/unit/ngsiv2/examples/contextRequests/updateProvisionDeviceStatic.json b/test/unit/ngsiv2/examples/contextRequests/updateProvisionDeviceStatic.json index 1ad1738f5..d20ecdca9 100644 --- a/test/unit/ngsiv2/examples/contextRequests/updateProvisionDeviceStatic.json +++ b/test/unit/ngsiv2/examples/contextRequests/updateProvisionDeviceStatic.json @@ -1,7 +1,7 @@ { "newAttribute": { "type": "Integer", - "value": " " + "value": null }, "cellID": { "type": "Integer", @@ -21,4 +21,4 @@ ] } } -} \ No newline at end of file +} diff --git a/test/unit/ngsiv2/examples/contextRequests/updateProvisionMinimumDevice.json b/test/unit/ngsiv2/examples/contextRequests/updateProvisionMinimumDevice.json index 5c76ba612..9b3c6f9f1 100644 --- a/test/unit/ngsiv2/examples/contextRequests/updateProvisionMinimumDevice.json +++ b/test/unit/ngsiv2/examples/contextRequests/updateProvisionMinimumDevice.json @@ -1,6 +1,6 @@ { "newAttribute": { "type": "Integer", - "value": " " + "value": null } -} \ No newline at end of file +} diff --git a/test/unit/ngsiv2/lazyAndCommands/polling-commands-test.js b/test/unit/ngsiv2/lazyAndCommands/polling-commands-test.js index de3c128b0..6ac99a194 100644 --- a/test/unit/ngsiv2/lazyAndCommands/polling-commands-test.js +++ b/test/unit/ngsiv2/lazyAndCommands/polling-commands-test.js @@ -342,7 +342,7 @@ describe('NGSI-v2 - Polling commands', function () { .post( '/v2/entities/Robot:r2d2/attrs?type=Robot', utils.readExampleFile( - './test/unit//ngsiv2/examples/contextRequests/updateContextCommandExpired.json' + './test/unit/ngsiv2/examples/contextRequests/updateContextCommandExpired.json' ) ) .reply(204);