From dc8ed8215de2d8dd69f39ee1c94660c36c13278b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ferm=C3=ADn=20Gal=C3=A1n=20M=C3=A1rquez?= Date: Wed, 26 Feb 2025 15:00:51 +0100 Subject: [PATCH] FIX address FIXME PR marks --- ...data-not-included-if-no-actual-update.test | 27 +++---------------- ...-in-custom-notifications-ngsi-payload.test | 12 +-------- ...-in-custom-notifications-ngsi-payload.test | 12 +-------- ...-in-simplifiedkeyvalues-notifications.test | 12 +-------- 4 files changed, 7 insertions(+), 56 deletions(-) diff --git a/test/functionalTest/cases/4643_previousvalue-metadata-not-included-if-no-actual-update/previousvalue-metadata-not-included-if-no-actual-update.test b/test/functionalTest/cases/4643_previousvalue-metadata-not-included-if-no-actual-update/previousvalue-metadata-not-included-if-no-actual-update.test index e1e2860097..7cf25c2119 100644 --- a/test/functionalTest/cases/4643_previousvalue-metadata-not-included-if-no-actual-update/previousvalue-metadata-not-included-if-no-actual-update.test +++ b/test/functionalTest/cases/4643_previousvalue-metadata-not-included-if-no-actual-update/previousvalue-metadata-not-included-if-no-actual-update.test @@ -30,9 +30,6 @@ accumulatorStart --pretty-print --SHELL-- -# FIXME PR: previousValue field in subs is probably irrelevant. Remove it at the end. -# FIXME PR: alterationType can be simplified to just entityUpdate - # # 01. Create testing entity # 02. Create sub @@ -76,9 +73,7 @@ payload='{ "TimeInstant" ], "alterationTypes": [ - "entityCreate", - "entityUpdate", - "entityDelete" + "entityUpdate" ], "notifyOnMetadataChange": true } @@ -106,10 +101,6 @@ payload='{ } } }, - "metadata": [ - "previousValue", - "*" - ], "covered": false } }' @@ -172,7 +163,7 @@ Fiware-Correlator: REGEX([0-9a-f\-]{36}) ==================== POST http://127.0.0.1:REGEX(\d+)/notify Fiware-Servicepath: / -Content-Length: 442 +Content-Length: 328 User-Agent: orion/REGEX(\d+\.\d+\.\d+.*) Ngsiv2-Attrsformat: normalized Host: 127.0.0.1:REGEX(\d+) @@ -184,12 +175,7 @@ Fiware-Correlator: REGEX([0-9a-f\-]{36}); cbnotif=1 "data": [ { "TimeInstant": { - "metadata": { - "previousValue": { - "type": "DateTime", - "value": "2025-02-10T16:41:00.000Z" - } - }, + "metadata": {}, "type": "DateTime", "value": "2025-02-10T16:41:00.000Z" }, @@ -206,12 +192,7 @@ Fiware-Correlator: REGEX([0-9a-f\-]{36}); cbnotif=1 "value": 0 }, "waterConsumption": { - "metadata": { - "previousValue": { - "type": "Number", - "value": 20 - } - }, + "metadata": {}, "type": "Number", "value": 20 } diff --git a/test/functionalTest/cases/4644_keyvalue-and-value-notification-format-not-working-in-custom-notifications-ngsi-payload/keyvalue-notification-format-not-working-in-custom-notifications-ngsi-payload.test b/test/functionalTest/cases/4644_keyvalue-and-value-notification-format-not-working-in-custom-notifications-ngsi-payload/keyvalue-notification-format-not-working-in-custom-notifications-ngsi-payload.test index db06fa2191..798990c9ba 100644 --- a/test/functionalTest/cases/4644_keyvalue-and-value-notification-format-not-working-in-custom-notifications-ngsi-payload/keyvalue-notification-format-not-working-in-custom-notifications-ngsi-payload.test +++ b/test/functionalTest/cases/4644_keyvalue-and-value-notification-format-not-working-in-custom-notifications-ngsi-payload/keyvalue-notification-format-not-working-in-custom-notifications-ngsi-payload.test @@ -30,10 +30,6 @@ accumulatorStart --pretty-print --SHELL-- -# FIXME PR: this test is aligned with the wrong behaviour. It would "break" when we fix the issue -# FIXME PR: previousValue field in subs is probably irrelevant. Remove it at the end. -# FIXME PR: alterationType can be simplified to just entityUpdate - # # 01. Create testing entity # 02. Create sub @@ -77,9 +73,7 @@ payload='{ "TimeInstant" ], "alterationTypes": [ - "entityCreate", - "entityUpdate", - "entityDelete" + "entityUpdate" ], "notifyOnMetadataChange": true } @@ -107,10 +101,6 @@ payload='{ } } }, - "metadata": [ - "previousValue", - "*" - ], "covered": false } }' diff --git a/test/functionalTest/cases/4644_keyvalue-and-value-notification-format-not-working-in-custom-notifications-ngsi-payload/values-notification-format-not-working-in-custom-notifications-ngsi-payload.test b/test/functionalTest/cases/4644_keyvalue-and-value-notification-format-not-working-in-custom-notifications-ngsi-payload/values-notification-format-not-working-in-custom-notifications-ngsi-payload.test index b6de0e4505..5b56a23982 100644 --- a/test/functionalTest/cases/4644_keyvalue-and-value-notification-format-not-working-in-custom-notifications-ngsi-payload/values-notification-format-not-working-in-custom-notifications-ngsi-payload.test +++ b/test/functionalTest/cases/4644_keyvalue-and-value-notification-format-not-working-in-custom-notifications-ngsi-payload/values-notification-format-not-working-in-custom-notifications-ngsi-payload.test @@ -30,10 +30,6 @@ accumulatorStart --pretty-print --SHELL-- -# FIXME PR: this test is aligned with the wrong behaviour. It would "break" when we fix the issue -# FIXME PR: previousValue field in subs is probably irrelevant. Remove it at the end. -# FIXME PR: alterationType can be simplified to just entityUpdate - # # 01. Create testing entity # 02. Create sub @@ -77,9 +73,7 @@ payload='{ "TimeInstant" ], "alterationTypes": [ - "entityCreate", - "entityUpdate", - "entityDelete" + "entityUpdate" ], "notifyOnMetadataChange": true } @@ -107,10 +101,6 @@ payload='{ } } }, - "metadata": [ - "previousValue", - "*" - ], "covered": false } }' diff --git a/test/functionalTest/cases/4645_jexl-expressions-not-working-in-simplifiedkeyvalues-notifications/jexl-expressions-not-working-in-simplifiedkeyvalues-notifications.test b/test/functionalTest/cases/4645_jexl-expressions-not-working-in-simplifiedkeyvalues-notifications/jexl-expressions-not-working-in-simplifiedkeyvalues-notifications.test index 6a185ffda8..e4149dd748 100644 --- a/test/functionalTest/cases/4645_jexl-expressions-not-working-in-simplifiedkeyvalues-notifications/jexl-expressions-not-working-in-simplifiedkeyvalues-notifications.test +++ b/test/functionalTest/cases/4645_jexl-expressions-not-working-in-simplifiedkeyvalues-notifications/jexl-expressions-not-working-in-simplifiedkeyvalues-notifications.test @@ -30,10 +30,6 @@ accumulatorStart --pretty-print --SHELL-- -# FIXME PR: this test is aligned with the wrong behaviour. It would "break" when we fix the issue -# FIXME PR: previousValue field in subs is probably irrelevant. Remove it at the end. -# FIXME PR: alterationType can be simplified to just entityUpdate - # # 01. Create testing entity # 02. Create sub @@ -77,9 +73,7 @@ payload='{ "TimeInstant" ], "alterationTypes": [ - "entityCreate", - "entityUpdate", - "entityDelete" + "entityUpdate" ], "notifyOnMetadataChange": true } @@ -107,10 +101,6 @@ payload='{ } } }, - "metadata": [ - "previousValue", - "*" - ], "covered": false } }'