NotificationUtils.Start Local Server${notification_server_host}${notification_server_port}
After Test
Delete Initial Subscriptions
Delete Initial Entity
Stop Local Server
*** Test Case ***
Check that a notification is send with all entities
Check that a notification is sent with all entities
[Documentation]The notification message shall include all the subscribed Entities that changed and that match (as mandated by clauses 4.9 and4.10) the query and geoquery conditions
[Tags]sub-notification5_11_7
${subscription_id}=Generate Random Entity Id${subscription_id_prefix}
${subscription_payload}=Load Subscription Sample With Reachable Endpoint${subscription_payload_file_path}${subscription_id}
${entity_id}=Generate Random Entity Id${building_id_prefix}
Should be Equal${subscription_id}${notification}[subscriptionId]
Dictionary Should Contain Key${notification}data
Should Not Be Empty${notification}[data]Notification data should not be empty
Should be Equal${entity_id}${notification}[data][0][id]
Should be True'${notification}[data][0][https://ngsi-ld-test-suite/context#airQualityLevel][value]'=='4.0' or '${notification}[data][0][https://ngsi-ld-test-suite/context#airQualityLevel][value]'=='4'
Should be EqualBuilding1${notification}[data][0][name][value]
${subscription_payload}=Load Subscription Sample With Reachable Endpoint${subscription_payload_file_path}${subscription_id}${notification_server_send_url}
Create Subscription From Subscription Payload${subscription_payload}${CONTENT_TYPE_LD_JSON}
Set Suite Variable${subscription_id}
Delete Initial Subscriptions
Delete Subscription${subscription_id}
*** Test Case ***
Check that a notification is send with all entities
[Documentation]The notification message shall include all the subscribed Entities that changed and that match (as mandated by clauses 4.9 and4.10) the query and geoquery conditions
[Tags]sub-notification5_11_7
${subscription_id}=Generate Random Entity Id${subscription_id_prefix}
${subscription_payload}=Load Subscription Sample With Reachable Endpoint${subscription_payload_file_path}${subscription_id}
Add Initial Entity
${entity_id}=Generate Random Entity Id${building_id_prefix}
NotificationUtils.Start Local Server${notification_server_host}${notification_server_port}
After Test
Delete Initial Subscriptions
Delete Initial Entity
Stop Local Server
*** Test Case ***
Check that a notification is sent with all entities
[Documentation]The notification message shall include all the subscribed Entities that changed and that match (as mandated by clauses 4.9 and4.10) the query and geoquery conditions
Should be Equal${subscription_id}${notification}[subscriptionId]
Dictionary Should Contain Key${notification}data
Should Not Be Empty${notification}[data]Notification data should not be empty
Should be Equal${entity_id}${notification}[data][0][id]
Should be True'${notification}[data][0][https://ngsi-ld-test-suite/context#airQualityLevel][value]'=='4.0' or '${notification}[data][0][https://ngsi-ld-test-suite/context#airQualityLevel][value]'=='4'
Should be EqualBuilding1${notification}[data][0][name][value]