Newer
Older
Documentation A Notification shall be sent (as mandated by each concrete binding and including any optional endpoint.info defined by clause 5.2.22) to the endpoint specified by the endpoint.uri member of the notification structure defined by clause 5.2.14
lopezaguilar
committed
Resource ${EXECDIR}/resources/ApiUtils/ContextInformationSubscription.resource
Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource
Resource ${EXECDIR}/resources/AssertionUtils.resource
Resource ${EXECDIR}/resources/JsonUtils.resource
Resource ${EXECDIR}/resources/NotificationUtils.resource
Suite Setup Before Test
Suite Teardown After Test
lopezaguilar
committed
${subscription_id_prefix} urn:ngsi-ld:Subscription:
${subscription_payload_file_path} subscriptions/subscription-building-entities-active-endpoint-info.jsonld
${building_id_prefix} urn:ngsi-ld:Building:
${entity_building_filepath} building-simple-attributes-sample.jsonld
${fragment_filename} airQualityLevel-fragment.jsonld
${notification_server_send_url} http://${notification_server_host}:${notification_server_port}/notify
*** Test Cases ***
lopezaguilar
committed
046_09_01 Check that a notification is sent to the endpoint
[Documentation] A Notification shall be sent (as mandated by each concrete binding and including any optional endpoint.info defined by clause 5.2.22) to the endpoint specified by the endpoint.uri member of the notification structure defined by clause 5.2.1
lopezaguilar
committed
[Tags] sub-notification 5_8_6 046_09
Add Initial Entity
Sleep 1s
Setup Initial Subscriptions
Update Entity Attributes ${entity_id} ${fragment_filename} ${CONTENT_TYPE_LD_JSON}
lopezaguilar
committed
${notification} ${headers}= Wait for notification timeout=${10}
Dictionary Should Contain Key ${headers} X-Additional-Key
${subscription_id}= Generate Random Entity Id ${subscription_id_prefix}
${subscription_payload}= Load Subscription Sample With Reachable Endpoint
... ${subscription_payload_file_path}
... ${subscription_id}
... ${notification_server_send_url}
${subscription_payload}= Set Entity Id In Subscription ${subscription_payload} ${entity_id}
Create Subscription From Subscription Payload ${subscription_payload} ${CONTENT_TYPE_LD_JSON}
Delete Initial Subscriptions
Delete Subscription ${subscription_id}
Start Local Server ${notification_server_host} ${notification_server_port}
After Test
Delete Initial Subscriptions
Delete Initial Entity
${entity_id}= Generate Random Entity Id ${building_id_prefix}