diff --git a/TP/NGSI-LD/CommonBehaviours/CommonResponses/VerifyGETWithoutAccept/045_01.robot b/TP/NGSI-LD/CommonBehaviours/CommonResponses/VerifyGETWithoutAccept/045_01.robot index 8dfdfcc56ce6fd6644747b13bac85ad0ec848c17..3c2e157870f818a2550232cb4dcccbd530c18be2 100644 --- a/TP/NGSI-LD/CommonBehaviours/CommonResponses/VerifyGETWithoutAccept/045_01.robot +++ b/TP/NGSI-LD/CommonBehaviours/CommonResponses/VerifyGETWithoutAccept/045_01.robot @@ -1,26 +1,23 @@ *** Settings *** Documentation Verify that on a GET HTTP request if nothing is specified on the Accept header, "application/json" is assumed -Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationConsumption.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationSubscription.resource -Resource ${EXECDIR}/resources/ApiUtils/ContextSourceRegistration.resource Resource ${EXECDIR}/resources/ApiUtils/ContextSourceDiscovery.resource -Resource ${EXECDIR}/resources/ApiUtils/TemporalContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextSourceRegistration.resource Resource ${EXECDIR}/resources/ApiUtils/TemporalContextInformationConsumption.resource +Resource ${EXECDIR}/resources/ApiUtils/TemporalContextInformationProvision.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource *** Variables *** -${building_id_prefix}= urn:ngsi-ld:Building: ${building_filename}= building-simple-attributes.jsonld -${subscription_id_prefix}= urn:ngsi-ld:Subscription: ${subscription_filename}= subscriptions/subscription.jsonld -${registration_id_prefix}= urn:ngsi-ld:Registration: ${registration_filename}= csourceRegistrations/context-source-registration-with-expiration.jsonld ${registration_type}= Vehicle -${tea_id_prefix}= urn:ngsi-ld:Vehicle: ${tea_filename}= vehicle-temporal-representation.jsonld ${teatype}= Vehicle ${content_type}= application/json @@ -30,7 +27,7 @@ ${content_type}= application/json 045_01_01 Endpoint /entities/{entityId} [Documentation] Verify that on a GET HTTP request if nothing is specified on the Accept header, "application/json" is assumed (/entities/{entityId}) [Tags] e-query cb-get 6_3_4 - ${id}= Generate Random Entity Id ${building_id_prefix} + ${id}= Generate Random Building Entity Id ${response}= Create Entity Selecting Content Type ... ${building_filename} ... ${id} @@ -48,7 +45,7 @@ ${content_type}= application/json 045_01_02 Endpoint /subscriptions/{subscriptionId} [Documentation] Verify that on a GET HTTP request if nothing is specified on the Accept header, "application/json" is assumed (/subscriptions/{subscriptionId}) [Tags] sub-retrieve cb-get 6_3_4 - ${id}= Generate Random Entity Id ${subscription_id_prefix} + ${id}= Generate Random Subscription Id ${response}= Create Subscription ${id} ${subscription_filename} ${CONTENT_TYPE_LD_JSON} Check Response Status Code 201 ${response.status_code} ${response}= Retrieve Subscription @@ -62,7 +59,7 @@ ${content_type}= application/json 045_01_03 Endpoint /csourceRegistrations/ [Documentation] Verify that on a GET HTTP request if nothing is specified on the Accept header, "application/json" is assumed (/csourceRegistrations/) [Tags] csr-query cb-get 6_3_4 - ${registration_id}= Generate Random Entity Id ${registration_id_prefix} + ${registration_id}= Generate Random CSR Id ${payload}= Load JSON From File ${EXECDIR}/data/${registration_filename} ${updated_payload}= Update Value To JSON ${payload} $..id ${registration_id} ${response}= Create Context Source Registration With Return ${updated_payload} @@ -80,7 +77,7 @@ ${content_type}= application/json 045_01_04 Endpoint /temporal/entities [Documentation] Verify that on a GET HTTP request if nothing is specified on the Accept header, "application/json" is assumed (/temporal/entities) [Tags] te-query cb-get 6_3_4 - ${temporal_entity_representation_id}= Generate Random Entity Id ${tea_id_prefix} + ${temporal_entity_representation_id}= Generate Random Vehicle Entity Id ${response}= Create Or Update Temporal Representation Of Entity Selecting Content Type ... temporal_entity_representation_id=${temporal_entity_representation_id} ... filename=${tea_filename} diff --git a/TP/NGSI-LD/CommonBehaviours/CommonResponses/VerifyLdContextNotAvailable/043_01.robot b/TP/NGSI-LD/CommonBehaviours/CommonResponses/VerifyLdContextNotAvailable/043_01.robot index c31238d5d9c150fdd532d4ede6dad9cd87ebd9af..86ee791f75ff8c115c8e9d548ad4885879999da9 100644 --- a/TP/NGSI-LD/CommonBehaviours/CommonResponses/VerifyLdContextNotAvailable/043_01.robot +++ b/TP/NGSI-LD/CommonBehaviours/CommonResponses/VerifyLdContextNotAvailable/043_01.robot @@ -1,6 +1,7 @@ *** Settings *** Documentation Verify receiving 503 – LdContextNotAvailable error if remote JSON-LD @context cannot be retrieved +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationSubscription.resource Resource ${EXECDIR}/resources/ApiUtils/ContextSourceRegistration.resource @@ -11,13 +12,9 @@ Resource ${EXECDIR}/resources/JsonUtils.resource *** Variables *** ${expected_status_code}= 503 -${building_id_prefix}= urn:ngsi-ld:Building: ${building_filename}= building-unretrievable-context.jsonld -${subscription_id_prefix}= urn:ngsi-ld:Subscription: ${subscription_filename}= subscriptions/subscription-unretrievable-context.jsonld -${tea_id_prefix}= urn:ngsi-ld:Vehicle: ${tea_filename}= bus-temporal-representation-unretrievable-context.jsonld -${registration_id_prefix}= urn:ngsi-ld:Registration: ${registration_filename}= csourceRegistrations/context-source-registration-unretrievable-context.jsonld @@ -25,7 +22,7 @@ ${registration_filename}= csourceRegistrations/context-source-registration 043_01_01 Create entity [Documentation] Verify receiving 503 – LdContextNotAvailable error if remote JSON-LD @context cannot be retrieved (Create entity) [Tags] e-create cb-ldcontext 5_2_2 - ${entity_id}= Generate Random Entity Id ${building_id_prefix} + ${entity_id}= Generate Random Building Entity Id ${response}= Create Entity Selecting Content Type ... ${building_filename} ... ${entity_id} @@ -40,7 +37,7 @@ ${registration_filename}= csourceRegistrations/context-source-registration 043_01_02 Create subscription [Documentation] Verify receiving 503 – LdContextNotAvailable error if remote JSON-LD @context cannot be retrieved (Create subscription) [Tags] sub-create cb-ldcontext 5_2_2 - ${subscription_id}= Generate Random Entity Id ${subscription_id_prefix} + ${subscription_id}= Generate Random Subscription Id ${response}= Create Subscription ${subscription_id} ${subscription_filename} ${CONTENT_TYPE_LD_JSON} Check Response Status Code ${expected_status_code} ${response.status_code} Check Response Body Containing ProblemDetails Element Containing Type Element set to @@ -52,7 +49,7 @@ ${registration_filename}= csourceRegistrations/context-source-registration 043_01_03 Create Temporal Representation of Entities [Documentation] Verify receiving 503 – LdContextNotAvailable error if remote JSON-LD @context cannot be retrieved (Create Temporal Representation of Entities) [Tags] te-create cb-ldcontext 5_2_2 - ${temporal_entity_representation_id}= Generate Random Entity Id ${tea_id_prefix} + ${temporal_entity_representation_id}= Generate Random Vehicle Entity Id ${response}= Create Or Update Temporal Representation Of Entity Selecting Content Type ... temporal_entity_representation_id=${temporal_entity_representation_id} ... filename=${tea_filename} @@ -67,8 +64,8 @@ ${registration_filename}= csourceRegistrations/context-source-registration 043_01_04 Batch entity create [Documentation] Verify receiving 503 – LdContextNotAvailable error if remote JSON-LD @context cannot be retrieved (Batch entity create) [Tags] be-create cb-ldcontext 5_2_2 - ${first_entity_id}= Generate Random Entity Id ${building_id_prefix} - ${second_entity_id}= Generate Random Entity Id ${building_id_prefix} + ${first_entity_id}= Generate Random Building Entity Id + ${second_entity_id}= Generate Random Building Entity Id ${first_entity}= Load Entity ${building_filename} ${first_entity_id} ${second_entity}= Load Entity ${building_filename} ${second_entity_id} @{entities_to_be_created}= Create List ${first_entity} ${second_entity} @@ -90,7 +87,7 @@ ${registration_filename}= csourceRegistrations/context-source-registration 043_01_05 Create context source registration [Documentation] Verify receiving 503 – LdContextNotAvailable error if remote JSON-LD @context cannot be retrieved (Create context source registration) [Tags] csr-create cb-ldcontext 5_2_2 - ${registration_id}= Generate Random Entity Id ${registration_id_prefix} + ${registration_id}= Generate Random CSR Id ${payload}= Load JSON From File ${EXECDIR}/data/${registration_filename} ${updated_payload}= Update Value To JSON ${payload} $..id ${registration_id} ${response}= Create Context Source Registration With Return ${updated_payload} diff --git a/TP/NGSI-LD/CommonBehaviours/CommonResponses/VerifyMergePatchJson/044_01.robot b/TP/NGSI-LD/CommonBehaviours/CommonResponses/VerifyMergePatchJson/044_01.robot index d7b50946e950870235c22f4e588bcac939dd0a28..2b521b2b8e225d194fed9021ceced75a3e013c66 100644 --- a/TP/NGSI-LD/CommonBehaviours/CommonResponses/VerifyMergePatchJson/044_01.robot +++ b/TP/NGSI-LD/CommonBehaviours/CommonResponses/VerifyMergePatchJson/044_01.robot @@ -1,6 +1,7 @@ *** Settings *** Documentation Verify that PATCH HTTP requests can be done with "application/merge-patch+json" as Content-Type +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -10,10 +11,9 @@ Test Teardown Delete Initial Entity *** Variables *** -${vehicle_id_prefix}= urn:ngsi-ld:Vehicle: -${vehicle_filename}= vehicle-simple-attributes.jsonld -${vehicle_fragment}= vehicle-brandname-fragment.json -${attribute_id}= brandName +${vehicle_filename}= vehicle-simple-attributes.jsonld +${vehicle_fragment}= vehicle-brandname-fragment.json +${attribute_id}= brandName *** Test Cases *** @@ -31,7 +31,7 @@ ${attribute_id}= brandName *** Keywords *** Create Initial Entity - ${entity_id}= Generate Random Entity Id ${vehicle_id_prefix} + ${entity_id}= Generate Random Vehicle Entity Id ${response}= Create Entity Selecting Content Type ... ${vehicle_filename} ... ${entity_id} diff --git a/TP/NGSI-LD/CommonBehaviours/CommonResponses/VerifyMergePatchJson/044_02.robot b/TP/NGSI-LD/CommonBehaviours/CommonResponses/VerifyMergePatchJson/044_02.robot index 70853e4b66f09e1a35ea12a0d85f1e813e21ebe7..455b2a76494498bbf1d345b519b9ae8fe1f9febe 100644 --- a/TP/NGSI-LD/CommonBehaviours/CommonResponses/VerifyMergePatchJson/044_02.robot +++ b/TP/NGSI-LD/CommonBehaviours/CommonResponses/VerifyMergePatchJson/044_02.robot @@ -1,6 +1,7 @@ *** Settings *** Documentation Verify that PATCH HTTP requests can be done with "application/merge-patch+json" as Content-Type +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationSubscription.resource Resource ${EXECDIR}/resources/AssertionUtils.resource @@ -11,7 +12,6 @@ Test Teardown Delete Initial Subscription *** Variables *** -${subscription_id_prefix}= urn:ngsi-ld:Subscription: ${subscription_filename}= subscriptions/subscription.jsonld ${subscription_fragment}= subscriptions/fragments/subscription-update.json @@ -30,7 +30,7 @@ ${subscription_fragment}= subscriptions/fragments/subscription-update.json *** Keywords *** Create Initial Subscription - ${subscription_id}= Generate Random Entity Id ${subscription_id_prefix} + ${subscription_id}= Generate Random Subscription Id ${response}= Create Subscription ${subscription_id} ${subscription_filename} ${CONTENT_TYPE_LD_JSON} Check Response Status Code 201 ${response.status_code} Set Test Variable ${subscription_id} diff --git a/TP/NGSI-LD/CommonBehaviours/CommonResponses/VerifyNotAcceptableMediaType/049_01.robot b/TP/NGSI-LD/CommonBehaviours/CommonResponses/VerifyNotAcceptableMediaType/049_01.robot index b835ad1c5209de29d663a3bb376efed9f34d228b..ae9ba566bb6dfdd2edb542cf9bf88cd8eaf2e01e 100644 --- a/TP/NGSI-LD/CommonBehaviours/CommonResponses/VerifyNotAcceptableMediaType/049_01.robot +++ b/TP/NGSI-LD/CommonBehaviours/CommonResponses/VerifyNotAcceptableMediaType/049_01.robot @@ -1,28 +1,27 @@ *** Settings *** Documentation Verify throwing 406 HTTP status code (Not Acceptable Media Type) if the "Accept" header does not imply "application/json" nor "application/ld+json" -Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationConsumption.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationSubscription.resource -Resource ${EXECDIR}/resources/ApiUtils/ContextSourceRegistrationSubscription.resource Resource ${EXECDIR}/resources/ApiUtils/ContextSourceDiscovery.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextSourceRegistrationSubscription.resource Resource ${EXECDIR}/resources/ApiUtils/TemporalContextInformationConsumption.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource *** Variables *** -${accept}= application/xml -${status_code}= 406 -${building_id_prefix}= urn:ngsi-ld:Building: -${subscription_id_prefix}= urn:ngsi-ld:Subscription: +${accept}= application/xml +${status_code}= 406 *** Test Cases *** 049_01_01 Endpoint get /entities/{entityId} [Documentation] Verify throwing 406 HTTP status code (Not Acceptable Media Type) if the "Accept" header does not imply "application/json" nor "application/ld+json" (get /entities/{entityId}) [Tags] e-query cb-noacceptable-medtype 6_3_4 - ${entity_id}= Generate Random Entity Id ${building_id_prefix} + ${entity_id}= Generate Random Building Entity Id ${response}= Query Entity ... id=${entity_id} ... accept=${accept} @@ -32,7 +31,7 @@ ${subscription_id_prefix}= urn:ngsi-ld:Subscription: 049_01_02 Endpoint get /subscriptions/{subscriptionId} [Documentation] Verify throwing 406 HTTP status code (Not Acceptable Media Type) if the "Accept" header does not imply "application/json" nor "application/ld+json" (get /subscriptions/{subscriptionId}) [Tags] sub-retrieve cb-noacceptable-medtype 6_3_4 - ${id}= Generate Random Entity Id ${subscription_id_prefix} + ${id}= Generate Random Subscription Id ${response}= Retrieve Subscription ... id=${id} ... accept=${accept} diff --git a/TP/NGSI-LD/CommonBehaviours/CommonResponses/VerifyNotAcceptableMediaType/049_02.robot b/TP/NGSI-LD/CommonBehaviours/CommonResponses/VerifyNotAcceptableMediaType/049_02.robot index 75a726425014499e2e60454d298ab9f02029f2e7..728ce974363cbc408f2511cb08f2faed652b6741 100644 --- a/TP/NGSI-LD/CommonBehaviours/CommonResponses/VerifyNotAcceptableMediaType/049_02.robot +++ b/TP/NGSI-LD/CommonBehaviours/CommonResponses/VerifyNotAcceptableMediaType/049_02.robot @@ -1,24 +1,24 @@ *** Settings *** Documentation Verify throwing 406 HTTP status code (Not Acceptable Media Type) if the "Accept" header is "application/geo+json" for operations different than "Retrieve Entity" and "Query Entity" +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationSubscription.resource -Resource ${EXECDIR}/resources/ApiUtils/TemporalContextInformationConsumption.resource Resource ${EXECDIR}/resources/ApiUtils/ContextSourceDiscovery.resource +Resource ${EXECDIR}/resources/ApiUtils/TemporalContextInformationConsumption.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource *** Variables *** -${accept}= application/geo+json -${status_code}= 406 -${subscription_id_prefix}= urn:ngsi-ld:Subscription: +${accept}= application/geo+json +${status_code}= 406 *** Test Cases *** 049_02_01 Retrieve subscription by id [Documentation] Verify throwing 406 HTTP status code (Not Acceptable Media Type) if the "Accept" header is "application/geo+json" for operations different than "Retrieve Entity" and "Query Entity" (get /subscriptions/{subscriptionId}) [Tags] sub-retrieve cb-noacceptable-medtype 6_3_4 - ${id}= Generate Random Entity Id ${subscription_id_prefix} + ${id}= Generate Random Subscription Id ${response}= Retrieve Subscription ... id=${id} ... accept=${accept} diff --git a/TP/NGSI-LD/CommonBehaviours/CommonResponses/VerifyUnsupportedMediaType/048_01.robot b/TP/NGSI-LD/CommonBehaviours/CommonResponses/VerifyUnsupportedMediaType/048_01.robot index b87bbb642c5061ba591dc7c2d2f9b7506b9b4290..41fdf24243db6ba957cf70f5087360f920e8c2cb 100644 --- a/TP/NGSI-LD/CommonBehaviours/CommonResponses/VerifyUnsupportedMediaType/048_01.robot +++ b/TP/NGSI-LD/CommonBehaviours/CommonResponses/VerifyUnsupportedMediaType/048_01.robot @@ -1,6 +1,7 @@ *** Settings *** Documentation Verify throwing 415 HTTP status code (Unsupported Media Type) if "Content-Type" header is not "application/json" or "application/ld+json" +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationSubscription.resource Resource ${EXECDIR}/resources/ApiUtils/TemporalContextInformationProvision.resource @@ -9,16 +10,12 @@ Resource ${EXECDIR}/resources/JsonUtils.resource *** Variables *** -${vehicle_id_prefix}= urn:ngsi-ld:Vehicle: ${vehicle_filename}= vehicle-simple-attributes.jsonld ${vehicle_attribute}= speed ${vehicle_fragment}= vehicle-brandname-fragment.jsonld -${subscription_id_prefix}= urn:ngsi-ld:Subscription: ${subscription_filename}= csourceSubscriptions/subscription.jsonld ${subscription_fragment}= csourceSubscriptions/fragments/subscription-update.jsonld -${tea_id_prefix}= urn:ngsi-ld:Vehicle: ${tea_filename}= vehicle-temporal-representation.jsonld -${building_id_prefix}= urn:ngsi-ld:Building: ${building_filename}= building-simple-attributes.jsonld ${content_type}= application/xml @@ -27,7 +24,7 @@ ${content_type}= application/xml 048_01_01 Endpoint patch /entities/{entityId}/attrs/{attrId} [Documentation] Verify throwing 415 HTTP status code (Unsupported Media Type) if "Content-Type" header is not "application/json" or "application/ld+json" (patch /entities/{entityId}/attrs/{attrId}) [Tags] ea-partial-update cb-unsupport-medtype 6_3_4 - ${entity_id}= Generate Random Entity Id ${vehicle_id_prefix} + ${entity_id}= Generate Random Vehicle Entity Id ${response}= Partial Update Entity Attributes ... entityId=${entity_id} ... attributeId=${vehicle_attribute} @@ -39,7 +36,7 @@ ${content_type}= application/xml 048_01_02 Endpoint patch /subscriptions/{subscriptionId} [Documentation] Verify throwing 415 HTTP status code (Unsupported Media Type) if "Content-Type" header is not "application/json" or "application/ld+json" (patch /subscriptions/{subscriptionId}) [Tags] sub-update cb-unsupport-medtype 6_3_4 - ${id}= Generate Random Entity Id ${subscription_id_prefix} + ${id}= Generate Random Subscription Id ${response}= Update Subscription ${id} ${subscription_fragment} ${content_type} Check Response Status Code 415 ${response.status_code} [Teardown] Delete Subscription ${id} @@ -47,7 +44,7 @@ ${content_type}= application/xml 048_01_03 Endpoint post /entities/ [Documentation] Verify throwing 415 HTTP status code (Unsupported Media Type) if "Content-Type" header is not "application/json" or "application/ld+json" (post /entities/) [Tags] e-create cb-unsupport-medtype 6_3_4 - ${entity_id}= Generate Random Entity Id ${building_id_prefix} + ${entity_id}= Generate Random Building Entity Id ${response}= Create Entity Selecting Content Type ... ${building_filename} ... ${entity_id} @@ -58,7 +55,7 @@ ${content_type}= application/xml 048_01_04 Endpoint post /subscriptions/ [Documentation] Verify throwing 415 HTTP status code (Unsupported Media Type) if "Content-Type" header is not "application/json" or "application/ld+json" (post /subscriptions/) [Tags] sub-create cb-unsupport-medtype 6_3_4 - ${subscriptions_id}= Generate Random Entity Id ${subscription_id_prefix} + ${subscriptions_id}= Generate Random Subscription Id ${response}= Create Subscription ${subscriptions_id} ${subscription_filename} ${content_type} Check Response Status Code 415 ${response.status_code} [Teardown] Delete Subscription ${subscriptions_id} @@ -66,8 +63,8 @@ ${content_type}= application/xml 048_01_05 Endpoint post /entityOperations/create [Documentation] Verify throwing 415 HTTP status code (Unsupported Media Type) if "Content-Type" header is not "application/json" or "application/ld+json" (post /entityOperations/create) [Tags] be-create cb-unsupport-medtype 6_3_4 - ${first_entity_id}= Generate Random Entity Id ${building_id_prefix} - ${second_entity_id}= Generate Random Entity Id ${building_id_prefix} + ${first_entity_id}= Generate Random Building Entity Id + ${second_entity_id}= Generate Random Building Entity Id ${first_entity}= Load Entity ${building_filename} ${first_entity_id} ${second_entity}= Load Entity ${building_filename} ${second_entity_id} @{entities_to_be_created}= Create List ${first_entity} ${second_entity} @@ -79,7 +76,7 @@ ${content_type}= application/xml 048_01_06 Endpoint post /temporal/entities/ [Documentation] Verify throwing 415 HTTP status code (Unsupported Media Type) if "Content-Type" header is not "application/json" or "application/ld+json" (post /temporal/entities/) [Tags] te-create cb-unsupport-medtype 6_3_4 - ${temporal_entity_representation_id}= Generate Random Entity Id ${tea_id_prefix} + ${temporal_entity_representation_id}= Generate Random Vehicle Entity Id ${response}= Create Or Update Temporal Representation Of Entity Selecting Content Type ... temporal_entity_representation_id=${temporal_entity_representation_id} ... filename=${tea_filename} diff --git a/TP/NGSI-LD/ContextInformation/Consumption/Discovery/RetrieveAvailableAttributeInformation/027_01.robot b/TP/NGSI-LD/ContextInformation/Consumption/Discovery/RetrieveAvailableAttributeInformation/027_01.robot index 73d9c42c82bea4e116c1c6db057363316b774c2a..edad46fda774bc6f69f4778e567960d07a31486a 100644 --- a/TP/NGSI-LD/ContextInformation/Consumption/Discovery/RetrieveAvailableAttributeInformation/027_01.robot +++ b/TP/NGSI-LD/ContextInformation/Consumption/Discovery/RetrieveAvailableAttributeInformation/027_01.robot @@ -1,6 +1,7 @@ *** Settings *** Documentation Check that one cannot retrieve a detailed representation of an unknown NGSI-LD attribute +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationConsumption.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource Resource ${EXECDIR}/resources/AssertionUtils.resource @@ -11,8 +12,7 @@ Suite Teardown Delete Initial Entity *** Variables *** -${building_id_prefix}= urn:ngsi-ld:Building: -${filename}= building-simple-attributes.json +${filename}= building-simple-attributes.json *** Test Cases *** @@ -29,7 +29,7 @@ ${filename}= building-simple-attributes.json *** Keywords *** Setup Initial Entity - ${entity_id}= Generate Random Entity Id ${building_id_prefix} + ${entity_id}= Generate Random Building Entity Id ${create_response}= Create Entity Selecting Content Type ... ${filename} ... ${entity_id} diff --git a/TP/NGSI-LD/ContextInformation/Consumption/Discovery/RetrieveAvailableAttributeInformation/027_02.robot b/TP/NGSI-LD/ContextInformation/Consumption/Discovery/RetrieveAvailableAttributeInformation/027_02.robot index 6ee800390f0e1cc22374caa4f84052f0688771d2..fa4f1164d5cb1de031ea08a38152773e48ee988c 100644 --- a/TP/NGSI-LD/ContextInformation/Consumption/Discovery/RetrieveAvailableAttributeInformation/027_02.robot +++ b/TP/NGSI-LD/ContextInformation/Consumption/Discovery/RetrieveAvailableAttributeInformation/027_02.robot @@ -1,6 +1,7 @@ *** Settings *** Documentation Check that one can retrieve a list with a detailed representation of NGSI-LD attributes +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationConsumption.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource Resource ${EXECDIR}/resources/AssertionUtils.resource @@ -12,9 +13,8 @@ Test Template Retrieve Detailed Representation Of Available Attribute *** Variables *** -${building_id_prefix}= urn:ngsi-ld:Building: -${filename}= building-simple-attributes.json -${expectation_file}= types/expectations/attribute-027-01.json +${filename}= building-simple-attributes.json +${expectation_file}= types/expectations/attribute-027-01.json *** Test Cases *** ATTR_NAME @@ -35,7 +35,7 @@ Retrieve Detailed Representation Of Available Attribute Check Response Body Containing Attribute element ${expectation_file} ${response.json()} Setup Initial Entity - ${entity_id}= Generate Random Entity Id ${building_id_prefix} + ${entity_id}= Generate Random Building Entity Id ${create_response}= Create Entity Selecting Content Type ... ${filename} ... ${entity_id} diff --git a/TP/NGSI-LD/ContextInformation/Consumption/Discovery/RetrieveAvailableAttributes/025_01.robot b/TP/NGSI-LD/ContextInformation/Consumption/Discovery/RetrieveAvailableAttributes/025_01.robot index 207eedc68862a7d0598054527c464fcd5730d1dd..248053bfa94357ad6395ae76032af0e970024d8e 100644 --- a/TP/NGSI-LD/ContextInformation/Consumption/Discovery/RetrieveAvailableAttributes/025_01.robot +++ b/TP/NGSI-LD/ContextInformation/Consumption/Discovery/RetrieveAvailableAttributes/025_01.robot @@ -1,6 +1,7 @@ *** Settings *** Documentation Check that one can retrieve a list of NGSI-LD attributes +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationConsumption.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource Resource ${EXECDIR}/resources/AssertionUtils.resource @@ -12,8 +13,7 @@ Test Template Retrieve Available Attributes *** Variables *** -${building_id_prefix}= urn:ngsi-ld:Building: -${filename}= building-simple-attributes.json +${filename}= building-simple-attributes.json *** Test Cases *** CONTEXT EXPECTATION_FILE @@ -35,7 +35,7 @@ Retrieve Available Attributes Check Response Body Containing AttributeList element ${expectation_file} ${response.json()} Setup Initial Entity - ${entity_id}= Generate Random Entity Id ${building_id_prefix} + ${entity_id}= Generate Random Building Entity Id ${create_response}= Create Entity Selecting Content Type ... ${filename} ... ${entity_id} diff --git a/TP/NGSI-LD/ContextInformation/Consumption/Discovery/RetrieveAvailableEntityTypeInformation/024_01.robot b/TP/NGSI-LD/ContextInformation/Consumption/Discovery/RetrieveAvailableEntityTypeInformation/024_01.robot index 8bb90236f7b738692e77252b5a154f0358ca4da9..86dbcacdce3a344c5585f8df7cf9885c3f1ec888 100644 --- a/TP/NGSI-LD/ContextInformation/Consumption/Discovery/RetrieveAvailableEntityTypeInformation/024_01.robot +++ b/TP/NGSI-LD/ContextInformation/Consumption/Discovery/RetrieveAvailableEntityTypeInformation/024_01.robot @@ -1,6 +1,7 @@ *** Settings *** Documentation Check that one cannot retrieve a detailed representation of an unknown NGSI-LD entity type +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationConsumption.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource Resource ${EXECDIR}/resources/AssertionUtils.resource @@ -11,8 +12,7 @@ Suite Teardown Delete Initial Entities *** Variables *** -${building_id_prefix}= urn:ngsi-ld:Building: -${filename}= building-simple-attributes.json +${filename}= building-simple-attributes.json *** Test Cases *** @@ -29,8 +29,8 @@ ${filename}= building-simple-attributes.json *** Keywords *** Setup Initial Entities - ${first_entity_id}= Generate Random Entity Id ${building_id_prefix} - ${second_entity_id}= Generate Random Entity Id ${building_id_prefix} + ${first_entity_id}= Generate Random Building Entity Id + ${second_entity_id}= Generate Random Building Entity Id ${create_response1}= Create Entity Selecting Content Type ... ${filename} ... ${first_entity_id} diff --git a/TP/NGSI-LD/ContextInformation/Consumption/Discovery/RetrieveAvailableEntityTypeInformation/024_02.robot b/TP/NGSI-LD/ContextInformation/Consumption/Discovery/RetrieveAvailableEntityTypeInformation/024_02.robot index 1a6ba8fb90efbd58a419a6131a62ecb223d56cd6..e0ecf6912aaf13bc2506703cbcdf29a855964a1e 100644 --- a/TP/NGSI-LD/ContextInformation/Consumption/Discovery/RetrieveAvailableEntityTypeInformation/024_02.robot +++ b/TP/NGSI-LD/ContextInformation/Consumption/Discovery/RetrieveAvailableEntityTypeInformation/024_02.robot @@ -1,6 +1,7 @@ *** Settings *** Documentation Check that one can retrieve a detailed representation of a specified NGSI-LD entity type +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationConsumption.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource Resource ${EXECDIR}/resources/AssertionUtils.resource @@ -12,9 +13,8 @@ Test Template Retrieve Detailed Representation Of Available Entity Type *** Variables *** -${building_id_prefix}= urn:ngsi-ld:Building: -${filename}= building-simple-attributes.json -${expectation_file}= types/expectations/entity-type-info-024-01.json +${filename}= building-simple-attributes.json +${expectation_file}= types/expectations/entity-type-info-024-01.json *** Test Cases *** TYPE @@ -35,8 +35,8 @@ Retrieve Detailed Representation Of Available Entity Type Check Response Body Containing EntityTypeInfo element ${expectation_file} ${response.json()} Setup Initial Entities - ${first_entity_id}= Generate Random Entity Id ${building_id_prefix} - ${second_entity_id}= Generate Random Entity Id ${building_id_prefix} + ${first_entity_id}= Generate Random Building Entity Id + ${second_entity_id}= Generate Random Building Entity Id ${create_response1}= Create Entity Selecting Content Type ... ${filename} ... ${first_entity_id} diff --git a/TP/NGSI-LD/ContextInformation/Consumption/Discovery/RetrieveAvailableEntityTypes/022_01.robot b/TP/NGSI-LD/ContextInformation/Consumption/Discovery/RetrieveAvailableEntityTypes/022_01.robot index 4ed1a88487b39094c80bb1a6afa05609f13e16da..018065cbaa2d078723add947e2f340b8cb42781d 100644 --- a/TP/NGSI-LD/ContextInformation/Consumption/Discovery/RetrieveAvailableEntityTypes/022_01.robot +++ b/TP/NGSI-LD/ContextInformation/Consumption/Discovery/RetrieveAvailableEntityTypes/022_01.robot @@ -1,6 +1,7 @@ *** Settings *** Documentation Check that one can retrieve a list of NGSI-LD entity types +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationConsumption.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource Resource ${EXECDIR}/resources/AssertionUtils.resource @@ -12,10 +13,8 @@ Test Template Retrieve Available Entity Types *** Variables *** -${building_id_prefix}= urn:ngsi-ld:Building: -${vehicle_id_prefix}= urn:ngsi-ld:Vehicle: -${first_filename}= building-simple-attributes.json -${second_filename}= vehicle-simple-attributes.json +${first_filename}= building-simple-attributes.json +${second_filename}= vehicle-simple-attributes.json *** Test Cases *** CONTEXT EXPECTATION_FILE @@ -37,8 +36,8 @@ Retrieve Available Entity Types Check Response Body Containing EntityTypeList element ${expectation_file} ${response.json()} Setup Initial Entities - ${first_entity_id}= Generate Random Entity Id ${building_id_prefix} - ${second_entity_id}= Generate Random Entity Id ${vehicle_id_prefix} + ${first_entity_id}= Generate Random Building Entity Id + ${second_entity_id}= Generate Random Vehicle Entity Id ${create_response1}= Create Entity Selecting Content Type ... ${first_filename} ... ${first_entity_id} diff --git a/TP/NGSI-LD/ContextInformation/Consumption/Discovery/RetrieveDetailsOfAvailableAttributes/026_01.robot b/TP/NGSI-LD/ContextInformation/Consumption/Discovery/RetrieveDetailsOfAvailableAttributes/026_01.robot index 4a60d16ef933648504c9e48832c78f54dadafef8..8c761e770ebfad43845c0dc2e11189b0d0d24240 100644 --- a/TP/NGSI-LD/ContextInformation/Consumption/Discovery/RetrieveDetailsOfAvailableAttributes/026_01.robot +++ b/TP/NGSI-LD/ContextInformation/Consumption/Discovery/RetrieveDetailsOfAvailableAttributes/026_01.robot @@ -1,6 +1,7 @@ *** Settings *** Documentation Check that one can retrieve a list with a detailed representation of NGSI-LD attributes +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationConsumption.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource Resource ${EXECDIR}/resources/AssertionUtils.resource @@ -12,8 +13,7 @@ Test Template Retrieve Details Of Available Attributes *** Variables *** -${building_id_prefix}= urn:ngsi-ld:Building: -${filename}= building-simple-attributes.json +${filename}= building-simple-attributes.json *** Test Cases *** CONTEXT EXPECTATION_FILE @@ -36,7 +36,7 @@ Retrieve Details Of Available Attributes Check Response Body Containing Attribute element ${expectation_file} ${response.json()} Setup Initial Entity - ${entity_id}= Generate Random Entity Id ${building_id_prefix} + ${entity_id}= Generate Random Building Entity Id ${create_response}= Create Entity Selecting Content Type ... ${filename} ... ${entity_id} diff --git a/TP/NGSI-LD/ContextInformation/Consumption/Discovery/RetrieveDetailsOfAvailableEntityTypes/023_01.robot b/TP/NGSI-LD/ContextInformation/Consumption/Discovery/RetrieveDetailsOfAvailableEntityTypes/023_01.robot index e5916c4f20ce511c24f3fd8d2516c1c6217528f2..fd244c7a78d22f5f964eaa992879b1f076a51b58 100644 --- a/TP/NGSI-LD/ContextInformation/Consumption/Discovery/RetrieveDetailsOfAvailableEntityTypes/023_01.robot +++ b/TP/NGSI-LD/ContextInformation/Consumption/Discovery/RetrieveDetailsOfAvailableEntityTypes/023_01.robot @@ -1,6 +1,7 @@ *** Settings *** Documentation Check that one can retrieve a list with a detailed representation of NGSI-LD entity types +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationConsumption.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource Resource ${EXECDIR}/resources/AssertionUtils.resource @@ -12,10 +13,8 @@ Test Template Retrieve Details Of Available Entity Types *** Variables *** -${building_id_prefix}= urn:ngsi-ld:Building: -${vehicle_id_prefix}= urn:ngsi-ld:Vehicle: -${first_filename}= building-simple-attributes.json -${second_filename}= vehicle-simple-attributes.json +${first_filename}= building-simple-attributes.json +${second_filename}= vehicle-simple-attributes.json *** Test Cases *** CONTEXT EXPECTATION_FILE @@ -38,8 +37,8 @@ Retrieve Details Of Available Entity Types Check Response Body Containing EntityType element ${expectation_file} ${response.json()} Setup Initial Entities - ${first_entity_id}= Generate Random Entity Id ${building_id_prefix} - ${second_entity_id}= Generate Random Entity Id ${vehicle_id_prefix} + ${first_entity_id}= Generate Random Building Entity Id + ${second_entity_id}= Generate Random Vehicle Entity Id ${create_response1}= Create Entity Selecting Content Type ... ${first_filename} ... ${first_entity_id} diff --git a/TP/NGSI-LD/ContextInformation/Consumption/Entity/QueryEntities/019_01_01.robot b/TP/NGSI-LD/ContextInformation/Consumption/Entity/QueryEntities/019_01_01.robot index 1e0a7bebaf56cbfec6645774fba9e3e01f91c7b3..ef3de1232b9511612fc87b5e6834fd77cf75de6c 100644 --- a/TP/NGSI-LD/ContextInformation/Consumption/Entity/QueryEntities/019_01_01.robot +++ b/TP/NGSI-LD/ContextInformation/Consumption/Entity/QueryEntities/019_01_01.robot @@ -1,8 +1,9 @@ *** Settings *** Documentation Check that one can query several entities based on ids -Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationConsumption.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -11,7 +12,6 @@ Suite Teardown Delete Entities *** Variables *** -${building_id_prefix}= urn:ngsi-ld:Building: ${filename}= building-minimal.jsonld ${expectation_filename}= building-minimal.json ${entity_type}= https://ngsi-ld-test-suite/context#Building @@ -38,21 +38,21 @@ ${entity_type}= https://ngsi-ld-test-suite/context#Building *** Keywords *** Setup Initial Entities - ${first_entity_id}= Generate Random Entity Id ${building_id_prefix} + ${first_entity_id}= Generate Random Building Entity Id Set Suite Variable ${first_entity_id} ${create_response1}= Create Entity Selecting Content Type ... ${filename} ... ${first_entity_id} ... ${CONTENT_TYPE_LD_JSON} Check Response Status Code 201 ${create_response1.status_code} - ${second_entity_id}= Generate Random Entity Id ${building_id_prefix} + ${second_entity_id}= Generate Random Building Entity Id Set Suite Variable ${second_entity_id} ${create_response2}= Create Entity Selecting Content Type ... ${filename} ... ${second_entity_id} ... ${CONTENT_TYPE_LD_JSON} Check Response Status Code 201 ${create_response2.status_code} - ${third_entity_id}= Generate Random Entity Id ${building_id_prefix} + ${third_entity_id}= Generate Random Building Entity Id Set Suite Variable ${third_entity_id} ${create_response3}= Create Entity Selecting Content Type ... ${filename} diff --git a/TP/NGSI-LD/ContextInformation/Consumption/Entity/QueryEntities/019_01_02.robot b/TP/NGSI-LD/ContextInformation/Consumption/Entity/QueryEntities/019_01_02.robot index 009e7e3dc69e82cbc15b067f71635f5b2a0facb5..a5014450c070ab551c5573a5d88c575282537f99 100644 --- a/TP/NGSI-LD/ContextInformation/Consumption/Entity/QueryEntities/019_01_02.robot +++ b/TP/NGSI-LD/ContextInformation/Consumption/Entity/QueryEntities/019_01_02.robot @@ -1,8 +1,9 @@ *** Settings *** Documentation Check that one can query several entities based on the entities types -Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationConsumption.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -11,9 +12,6 @@ Suite Teardown Delete Entities *** Variables *** -${building_id_prefix}= urn:ngsi-ld:Building: -${vehicle_id_prefix}= urn:ngsi-ld:Vehicle: -${parking_id_prefix}= urn:ngsi-ld:OffStreetParking: ${building_filename}= building-minimal.jsonld ${vehicle_filename}= vehicle-simple-attributes.jsonld ${parking_filename}= parking-simple-attributes.jsonld @@ -42,21 +40,21 @@ ${parking_entity_type}= https://ngsi-ld-test-suite/context#OffStreetParking *** Keywords *** Setup Initial Entities - ${building_entity_id}= Generate Random Entity Id ${building_id_prefix} + ${building_entity_id}= Generate Random Building Entity Id Set Suite Variable ${building_entity_id} ${create_response1}= Create Entity Selecting Content Type ... ${building_filename} ... ${building_entity_id} ... ${CONTENT_TYPE_LD_JSON} Check Response Status Code 201 ${create_response1.status_code} - ${vehicle_entity_id}= Generate Random Entity Id ${vehicle_id_prefix} + ${vehicle_entity_id}= Generate Random Vehicle Entity Id Set Suite Variable ${vehicle_entity_id} ${create_response2}= Create Entity Selecting Content Type ... ${vehicle_filename} ... ${vehicle_entity_id} ... ${CONTENT_TYPE_LD_JSON} Check Response Status Code 201 ${create_response2.status_code} - ${parking_entity_id}= Generate Random Entity Id ${parking_id_prefix} + ${parking_entity_id}= Generate Random Parking Entity Id Set Suite Variable ${parking_entity_id} ${create_response3}= Create Entity Selecting Content Type ... ${parking_filename} diff --git a/TP/NGSI-LD/ContextInformation/Consumption/Entity/QueryEntities/019_01_03.robot b/TP/NGSI-LD/ContextInformation/Consumption/Entity/QueryEntities/019_01_03.robot index 8a4a3a5abc5dc3f6e20710c7d13cb7a441261097..e61c33589d8901cf5df25e376dd11b239041284c 100644 --- a/TP/NGSI-LD/ContextInformation/Consumption/Entity/QueryEntities/019_01_03.robot +++ b/TP/NGSI-LD/ContextInformation/Consumption/Entity/QueryEntities/019_01_03.robot @@ -1,8 +1,9 @@ *** Settings *** Documentation Check that one can query several entities based on the given id pattern -Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationConsumption.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -11,7 +12,6 @@ Suite Teardown Delete Entities *** Variables *** -${building_id_prefix}= urn:ngsi-ld:Building: ${filename}= building-minimal.jsonld ${expectation_filename}= building-minimal.json ${entity_type}= https://ngsi-ld-test-suite/context#Building @@ -38,14 +38,14 @@ ${entity_id_pattern}= urn:ngsi-ld:Building:.* *** Keywords *** Setup Initial Entities - ${first_entity_id}= Generate Random Entity Id ${building_id_prefix} + ${first_entity_id}= Generate Random Building Entity Id Set Suite Variable ${first_entity_id} ${create_response1}= Create Entity Selecting Content Type ... ${filename} ... ${first_entity_id} ... ${CONTENT_TYPE_LD_JSON} Check Response Status Code 201 ${create_response1.status_code} - ${second_entity_id}= Generate Random Entity Id ${building_id_prefix} + ${second_entity_id}= Generate Random Building Entity Id Set Suite Variable ${second_entity_id} ${create_response2}= Create Entity Selecting Content Type ... ${filename} diff --git a/TP/NGSI-LD/ContextInformation/Consumption/Entity/QueryEntities/019_01_04.robot b/TP/NGSI-LD/ContextInformation/Consumption/Entity/QueryEntities/019_01_04.robot index 4c71f701795fc6ae6d14feb82b35dad34ea450bd..6f78753aa8e0bc141911664246a8d6c9fc34b97d 100644 --- a/TP/NGSI-LD/ContextInformation/Consumption/Entity/QueryEntities/019_01_04.robot +++ b/TP/NGSI-LD/ContextInformation/Consumption/Entity/QueryEntities/019_01_04.robot @@ -1,8 +1,9 @@ *** Settings *** Documentation Check that one can query several entities based on attribute names -Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationConsumption.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -11,7 +12,6 @@ Suite Teardown Delete Entities *** Variables *** -${building_id_prefix}= urn:ngsi-ld:Building: ${filename}= building-simple-attributes.jsonld ${filename2}= building-minimal.jsonld ${expectation_filename}= building-attributes-query.json @@ -41,14 +41,14 @@ ${attribute_subcategory}= https://ngsi-ld-test-suite/context#subCatego *** Keywords *** Setup Initial Entities - ${first_entity_id}= Generate Random Entity Id ${building_id_prefix} + ${first_entity_id}= Generate Random Building Entity Id Set Suite Variable ${first_entity_id} ${create_response1}= Create Entity Selecting Content Type ... ${filename} ... ${first_entity_id} ... ${CONTENT_TYPE_LD_JSON} Check Response Status Code 201 ${create_response1.status_code} - ${second_entity_id}= Generate Random Entity Id ${building_id_prefix} + ${second_entity_id}= Generate Random Building Entity Id Set Suite Variable ${second_entity_id} ${create_response2}= Create Entity Selecting Content Type ... ${filename2} diff --git a/TP/NGSI-LD/ContextInformation/Consumption/Entity/QueryEntities/019_01_05.robot b/TP/NGSI-LD/ContextInformation/Consumption/Entity/QueryEntities/019_01_05.robot index c1467f99a4a6e7c5e4e0740aab249762e7eec445..a542ac9dd4a95adf7d4ade75fe3bdcef57ac841a 100644 --- a/TP/NGSI-LD/ContextInformation/Consumption/Entity/QueryEntities/019_01_05.robot +++ b/TP/NGSI-LD/ContextInformation/Consumption/Entity/QueryEntities/019_01_05.robot @@ -1,8 +1,9 @@ *** Settings *** Documentation Check that one can query entities based on a geoquery -Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationConsumption.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -11,7 +12,6 @@ Suite Teardown Delete Entities *** Variables *** -${building_id_prefix}= urn:ngsi-ld:Building: ${filename}= building-location-attribute.jsonld ${expectation_filename}= building-geoproperty-query.jsonld ${entity_type}= https://ngsi-ld-test-suite/context#Building @@ -44,14 +44,14 @@ ${coordinates}= [13.3986, 52.5547] *** Keywords *** Setup Initial Entities - ${first_entity_id}= Generate Random Entity Id ${building_id_prefix} + ${first_entity_id}= Generate Random Building Entity Id Set Suite Variable ${first_entity_id} ${create_response1}= Create Entity Selecting Content Type ... ${filename} ... ${first_entity_id} ... ${CONTENT_TYPE_LD_JSON} Check Response Status Code 201 ${create_response1.status_code} - ${second_entity_id}= Generate Random Entity Id ${building_id_prefix} + ${second_entity_id}= Generate Random Building Entity Id Set Suite Variable ${second_entity_id} ${create_response2}= Create Entity Selecting Content Type ... ${filename} diff --git a/TP/NGSI-LD/ContextInformation/Consumption/Entity/QueryEntities/019_01_06.robot b/TP/NGSI-LD/ContextInformation/Consumption/Entity/QueryEntities/019_01_06.robot index ead347f546721e9c385d452aaaef4aa753ab6838..87ef141f55423b29e3fa213a2a23a9d5bba1ed75 100644 --- a/TP/NGSI-LD/ContextInformation/Consumption/Entity/QueryEntities/019_01_06.robot +++ b/TP/NGSI-LD/ContextInformation/Consumption/Entity/QueryEntities/019_01_06.robot @@ -1,8 +1,9 @@ *** Settings *** Documentation Check that one can query several entities based on scopes -Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationConsumption.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -12,7 +13,6 @@ Test Template Query several entities based on scopes *** Variables *** -${building_id_prefix}= urn:ngsi-ld:Building: ${entity_one_scope}= building-minimal-with-one-scope.json ${entity_many_scopes}= building-minimal-with-many-scopes.json ${entity_type}= https://ngsi-ld-test-suite/context#Building @@ -50,7 +50,7 @@ Query several entities based on scopes Check Response Body Containing Number Of Entities ${entity_type} ${expected_count} ${response.json()} Setup Initial Entities - ${entity_one_scope_id}= Generate Random Entity Id ${building_id_prefix} + ${entity_one_scope_id}= Generate Random Building Entity Id Set Suite Variable ${entity_one_scope_id} ${create_response1}= Create Entity Selecting Content Type ... ${entity_one_scope} @@ -58,7 +58,7 @@ Setup Initial Entities ... ${CONTENT_TYPE_JSON} ... ${ngsild_test_suite_context} Check Response Status Code 201 ${create_response1.status_code} - ${entity_many_scopes_id}= Generate Random Entity Id ${building_id_prefix} + ${entity_many_scopes_id}= Generate Random Building Entity Id Set Suite Variable ${entity_many_scopes_id} ${create_response2}= Create Entity Selecting Content Type ... ${entity_many_scopes} diff --git a/TP/NGSI-LD/ContextInformation/Consumption/Entity/QueryEntities/019_02_01.robot b/TP/NGSI-LD/ContextInformation/Consumption/Entity/QueryEntities/019_02_01.robot index b71cfdd81fdb533513e3d556412806b501732a6d..638f17c5c51070183268600f0239234e33ef2a9c 100644 --- a/TP/NGSI-LD/ContextInformation/Consumption/Entity/QueryEntities/019_02_01.robot +++ b/TP/NGSI-LD/ContextInformation/Consumption/Entity/QueryEntities/019_02_01.robot @@ -1,8 +1,9 @@ *** Settings *** Documentation Check that one can query one entity via POST Interaction based on id -Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationConsumption.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -11,7 +12,6 @@ Suite Teardown Delete Entities *** Variables *** -${building_id_prefix}= urn:ngsi-ld:Building: ${filename}= building-minimal.jsonld ${expectation_filename}= building-minimal.json ${entity_type}= https://ngsi-ld-test-suite/context#Building @@ -35,21 +35,21 @@ ${entity_type}= https://ngsi-ld-test-suite/context#Building *** Keywords *** Create Entities - ${first_entity_id}= Generate Random Entity Id ${building_id_prefix} + ${first_entity_id}= Generate Random Building Entity Id Set Suite Variable ${first_entity_id} ${response}= Create Entity Selecting Content Type ... ${filename} ... ${first_entity_id} ... ${CONTENT_TYPE_LD_JSON} Check Response Status Code 201 ${response.status_code} - ${second_entity_id}= Generate Random Entity Id ${building_id_prefix} + ${second_entity_id}= Generate Random Building Entity Id Set Suite Variable ${second_entity_id} ${response}= Create Entity Selecting Content Type ... ${filename} ... ${second_entity_id} ... ${CONTENT_TYPE_LD_JSON} Check Response Status Code 201 ${response.status_code} - ${third_entity_id}= Generate Random Entity Id ${building_id_prefix} + ${third_entity_id}= Generate Random Building Entity Id Set Suite Variable ${third_entity_id} ${response}= Create Entity Selecting Content Type ... ${filename} diff --git a/TP/NGSI-LD/ContextInformation/Consumption/Entity/QueryEntities/019_02_02.robot b/TP/NGSI-LD/ContextInformation/Consumption/Entity/QueryEntities/019_02_02.robot index 49bfe69c2279506698df27ce99818a5579d601df..88727250bdfef80382e43294acc255b0ac7ddbe9 100644 --- a/TP/NGSI-LD/ContextInformation/Consumption/Entity/QueryEntities/019_02_02.robot +++ b/TP/NGSI-LD/ContextInformation/Consumption/Entity/QueryEntities/019_02_02.robot @@ -1,8 +1,9 @@ *** Settings *** Documentation Check that one can query several entities via POST Interaction based on the entity type -Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationConsumption.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -11,8 +12,6 @@ Suite Teardown Delete Entities *** Variables *** -${building_id_prefix}= urn:ngsi-ld:Building: -${vehicle_id_prefix}= urn:ngsi-ld:Vehicle: ${building_filename}= building-minimal.jsonld ${vehicle_filename}= vehicle-simple-attributes.jsonld ${expectation_filename}= two-vehicles.jsonld @@ -40,21 +39,21 @@ ${vehicle_entity_type}= https://ngsi-ld-test-suite/context#Vehicle *** Keywords *** Create Entities - ${building_entity_id}= Generate Random Entity Id ${building_id_prefix} + ${building_entity_id}= Generate Random Building Entity Id Set Suite Variable ${building_entity_id} ${response}= Create Entity Selecting Content Type ... ${building_filename} ... ${building_entity_id} ... ${CONTENT_TYPE_LD_JSON} Check Response Status Code 201 ${response.status_code} - ${first_vehicle_entity_id}= Generate Random Entity Id ${vehicle_id_prefix} + ${first_vehicle_entity_id}= Generate Random Vehicle Entity Id Set Suite Variable ${first_vehicle_entity_id} ${response}= Create Entity Selecting Content Type ... ${vehicle_filename} ... ${first_vehicle_entity_id} ... ${CONTENT_TYPE_LD_JSON} Check Response Status Code 201 ${response.status_code} - ${second_vehicle_entity_id}= Generate Random Entity Id ${vehicle_id_prefix} + ${second_vehicle_entity_id}= Generate Random Vehicle Entity Id Set Suite Variable ${second_vehicle_entity_id} ${response}= Create Entity Selecting Content Type ... ${vehicle_filename} diff --git a/TP/NGSI-LD/ContextInformation/Consumption/Entity/QueryEntities/019_02_03.robot b/TP/NGSI-LD/ContextInformation/Consumption/Entity/QueryEntities/019_02_03.robot index 56d9f014274a2f6607ae6311dfcc8c1569c2eb75..e9f4a532cb6b19aafba6688c829792c10c4fb966 100644 --- a/TP/NGSI-LD/ContextInformation/Consumption/Entity/QueryEntities/019_02_03.robot +++ b/TP/NGSI-LD/ContextInformation/Consumption/Entity/QueryEntities/019_02_03.robot @@ -1,8 +1,9 @@ *** Settings *** Documentation Check that one can query several entities via POST Interaction based on the given id pattern -Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationConsumption.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -11,7 +12,6 @@ Suite Teardown Delete Entities *** Variables *** -${building_id_prefix}= urn:ngsi-ld:Building: ${filename}= building-minimal.jsonld ${expectation_filename}= building-minimal.json ${entity_type}= https://ngsi-ld-test-suite/context#Building @@ -36,14 +36,14 @@ ${entity_id_pattern}= urn:ngsi-ld:Building:.* *** Keywords *** Create Entities - ${first_entity_id}= Generate Random Entity Id ${building_id_prefix} + ${first_entity_id}= Generate Random Building Entity Id Set Suite Variable ${first_entity_id} ${response}= Create Entity Selecting Content Type ... ${filename} ... ${first_entity_id} ... ${CONTENT_TYPE_LD_JSON} Check Response Status Code 201 ${response.status_code} - ${second_entity_id}= Generate Random Entity Id ${building_id_prefix} + ${second_entity_id}= Generate Random Building Entity Id Set Suite Variable ${second_entity_id} ${response}= Create Entity Selecting Content Type ... ${filename} diff --git a/TP/NGSI-LD/ContextInformation/Consumption/Entity/QueryEntities/019_02_04.robot b/TP/NGSI-LD/ContextInformation/Consumption/Entity/QueryEntities/019_02_04.robot index e9e38a6ea232f513452d3388a49caef0093e6d77..869c00a35a3b9034c62fe347c0ddb25dc4fbf6f0 100644 --- a/TP/NGSI-LD/ContextInformation/Consumption/Entity/QueryEntities/019_02_04.robot +++ b/TP/NGSI-LD/ContextInformation/Consumption/Entity/QueryEntities/019_02_04.robot @@ -1,8 +1,9 @@ *** Settings *** Documentation Check that one can query several entities via POST Interaction based on attribute names -Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationConsumption.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -11,8 +12,6 @@ Suite Teardown Delete Entities *** Variables *** -${building_id_prefix}= urn:ngsi-ld:Building: -${vehicle_id_prefix}= urn:ngsi-ld:Vehicle: ${building_filename}= building-minimal.jsonld ${vehicle_filename}= vehicle-simple-attributes.jsonld ${expectation_filename}= vehicle-simple-attributes-core-context.json @@ -36,14 +35,14 @@ ${attribute_isparked}= https://uri.etsi.org/ngsi-ld/default-context/isParke *** Keywords *** Create Entities - ${building_entity_id}= Generate Random Entity Id ${building_id_prefix} + ${building_entity_id}= Generate Random Building Entity Id Set Suite Variable ${building_entity_id} ${response}= Create Entity Selecting Content Type ... ${building_filename} ... ${building_entity_id} ... ${CONTENT_TYPE_LD_JSON} Check Response Status Code 201 ${response.status_code} - ${vehicle_entity_id}= Generate Random Entity Id ${vehicle_id_prefix} + ${vehicle_entity_id}= Generate Random Vehicle Entity Id Set Suite Variable ${vehicle_entity_id} ${response}= Create Entity Selecting Content Type ... ${vehicle_filename} diff --git a/TP/NGSI-LD/ContextInformation/Consumption/Entity/QueryEntities/019_02_05.robot b/TP/NGSI-LD/ContextInformation/Consumption/Entity/QueryEntities/019_02_05.robot index 15295a0b3b77323abf8cc02705b79b8498f1ded6..f05ee6765de5ff47a9264b015a904b8982aee59a 100644 --- a/TP/NGSI-LD/ContextInformation/Consumption/Entity/QueryEntities/019_02_05.robot +++ b/TP/NGSI-LD/ContextInformation/Consumption/Entity/QueryEntities/019_02_05.robot @@ -1,8 +1,8 @@ *** Settings *** Documentation Check that one can query entitites via POST Interaction asking for a GeoJSON representation -Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationConsumption.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -11,8 +11,6 @@ Suite Teardown Delete Entities *** Variables *** -${vehicle_id_prefix}= urn:ngsi-ld:Vehicle: -${parking_id_prefix}= urn:ngsi-ld:OffStreetParking: ${vehicle_filename}= vehicle-simple-attributes.jsonld ${parking_filename}= parking-simple-attributes.jsonld ${expectation_filename_alt2}= vehicle-parking-019-02-05.alternative2.geojson diff --git a/TP/NGSI-LD/ContextInformation/Consumption/Entity/QueryEntities/019_02_06.robot b/TP/NGSI-LD/ContextInformation/Consumption/Entity/QueryEntities/019_02_06.robot index 0f02f838d1695f33d4498ba5ac96441a1546c3c1..a91f6c19d215a9330ed1d919bf2246a96a53ab23 100644 --- a/TP/NGSI-LD/ContextInformation/Consumption/Entity/QueryEntities/019_02_06.robot +++ b/TP/NGSI-LD/ContextInformation/Consumption/Entity/QueryEntities/019_02_06.robot @@ -1,8 +1,9 @@ *** Settings *** Documentation Check that one can query two entities via POST Interaction based on ids -Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationConsumption.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -11,7 +12,6 @@ Suite Teardown Delete Entities *** Variables *** -${building_id_prefix}= urn:ngsi-ld:Building: ${filename}= building-minimal.jsonld ${expectation_filename}= building-minimal.json ${entity_type}= https://ngsi-ld-test-suite/context#Building @@ -36,21 +36,21 @@ ${entity_type}= https://ngsi-ld-test-suite/context#Building *** Keywords *** Create Entities - ${first_entity_id}= Generate Random Entity Id ${building_id_prefix} + ${first_entity_id}= Generate Random Building Entity Id Set Suite Variable ${first_entity_id} ${response}= Create Entity Selecting Content Type ... ${filename} ... ${first_entity_id} ... ${CONTENT_TYPE_LD_JSON} Check Response Status Code 201 ${response.status_code} - ${second_entity_id}= Generate Random Entity Id ${building_id_prefix} + ${second_entity_id}= Generate Random Building Entity Id Set Suite Variable ${second_entity_id} ${response}= Create Entity Selecting Content Type ... ${filename} ... ${second_entity_id} ... ${CONTENT_TYPE_LD_JSON} Check Response Status Code 201 ${response.status_code} - ${third_entity_id}= Generate Random Entity Id ${building_id_prefix} + ${third_entity_id}= Generate Random Building Entity Id Set Suite Variable ${third_entity_id} ${response}= Create Entity Selecting Content Type ... ${filename} diff --git a/TP/NGSI-LD/ContextInformation/Consumption/Entity/QueryEntities/019_03_01.robot b/TP/NGSI-LD/ContextInformation/Consumption/Entity/QueryEntities/019_03_01.robot index 44a8dd8ffe47d656953a6d11c0bdcc3a3901cc44..78e04223ba17568d7890042c1d4b89f64673cc09 100644 --- a/TP/NGSI-LD/ContextInformation/Consumption/Entity/QueryEntities/019_03_01.robot +++ b/TP/NGSI-LD/ContextInformation/Consumption/Entity/QueryEntities/019_03_01.robot @@ -1,8 +1,9 @@ *** Settings *** Documentation Check that one cannot query entities if the requested ids are incorrect -Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationConsumption.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -11,7 +12,6 @@ Suite Teardown Delete Entities *** Variables *** -${building_id_prefix}= urn:ngsi-ld:Building: ${filename}= building-minimal.jsonld ${entity_type}= https://ngsi-ld-test-suite/context#Building ${entity_invalid_id_one}= thisisaninvaliduri1 @@ -38,14 +38,14 @@ ${entity_invalid_id_two}= thisisaninvaliduri2 *** Keywords *** Create Entities - ${first_entity_id}= Generate Random Entity Id ${building_id_prefix} + ${first_entity_id}= Generate Random Building Entity Id Set Suite Variable ${first_entity_id} ${create_response1}= Create Entity Selecting Content Type ... ${filename} ... ${first_entity_id} ... ${CONTENT_TYPE_LD_JSON} Check Response Status Code 201 ${create_response1.status_code} - ${second_entity_id}= Generate Random Entity Id ${building_id_prefix} + ${second_entity_id}= Generate Random Building Entity Id Set Suite Variable ${second_entity_id} ${create_response2}= Create Entity Selecting Content Type ... ${filename} diff --git a/TP/NGSI-LD/ContextInformation/Consumption/Entity/QueryEntities/019_03_02.robot b/TP/NGSI-LD/ContextInformation/Consumption/Entity/QueryEntities/019_03_02.robot index 2eeffcf169830151cc0e970091e73e908f5e5b8c..bbf48311c4327ccb14899d5da3dc7397113551ae 100644 --- a/TP/NGSI-LD/ContextInformation/Consumption/Entity/QueryEntities/019_03_02.robot +++ b/TP/NGSI-LD/ContextInformation/Consumption/Entity/QueryEntities/019_03_02.robot @@ -1,8 +1,9 @@ *** Settings *** Documentation Check that one cannot query entities if the requested entity types are incorrect -Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationConsumption.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -11,8 +12,6 @@ Suite Teardown Delete Entities *** Variables *** -${building_id_prefix}= urn:ngsi-ld:Building: -${vehicle_id_prefix}= urn:ngsi-ld:Vehicle: ${building_filename}= building-minimal.jsonld ${vehicle_filename}= vehicle-simple-attributes.jsonld ${invalid_entity_type_one}= type @@ -39,14 +38,14 @@ ${invalid_entity_type_two}= invalid_entity_type_two *** Keywords *** Create Entities - ${building_entity_id}= Generate Random Entity Id ${building_id_prefix} + ${building_entity_id}= Generate Random Building Entity Id Set Suite Variable ${building_entity_id} ${create_response1}= Create Entity Selecting Content Type ... ${building_filename} ... ${building_entity_id} ... ${CONTENT_TYPE_LD_JSON} Check Response Status Code 201 ${create_response1.status_code} - ${vehicle_entity_id}= Generate Random Entity Id ${vehicle_id_prefix} + ${vehicle_entity_id}= Generate Random Vehicle Entity Id Set Suite Variable ${vehicle_entity_id} ${create_response2}= Create Entity Selecting Content Type ... ${vehicle_filename} diff --git a/TP/NGSI-LD/ContextInformation/Consumption/Entity/QueryEntities/019_03_03.robot b/TP/NGSI-LD/ContextInformation/Consumption/Entity/QueryEntities/019_03_03.robot index 35c350376ffb956ec503a92f4d10b584ba3ba7c2..6dc83085ad31bbd93d7fa7c25bbf35110da918c0 100644 --- a/TP/NGSI-LD/ContextInformation/Consumption/Entity/QueryEntities/019_03_03.robot +++ b/TP/NGSI-LD/ContextInformation/Consumption/Entity/QueryEntities/019_03_03.robot @@ -1,8 +1,9 @@ *** Settings *** Documentation Check that one cannot query entities if the requested id pattern is incorrect -Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationConsumption.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -11,7 +12,6 @@ Suite Teardown Delete Entities *** Variables *** -${building_id_prefix}= urn:ngsi-ld:Building: ${filename}= building-minimal.jsonld ${entity_type}= https://ngsi-ld-test-suite/context#Building ${invalid_entity_id_pattern}= invalid_entity_id_pattern** @@ -36,14 +36,14 @@ ${invalid_entity_id_pattern}= invalid_entity_id_pattern** *** Keywords *** Create Entities - ${first_entity_id}= Generate Random Entity Id ${building_id_prefix} + ${first_entity_id}= Generate Random Building Entity Id Set Suite Variable ${first_entity_id} ${create_response1}= Create Entity Selecting Content Type ... ${filename} ... ${first_entity_id} ... ${CONTENT_TYPE_LD_JSON} Check Response Status Code 201 ${create_response1.status_code} - ${second_entity_id}= Generate Random Entity Id ${building_id_prefix} + ${second_entity_id}= Generate Random Building Entity Id Set Suite Variable ${second_entity_id} ${create_response2}= Create Entity Selecting Content Type ... ${filename} diff --git a/TP/NGSI-LD/ContextInformation/Consumption/Entity/QueryEntities/019_03_04.robot b/TP/NGSI-LD/ContextInformation/Consumption/Entity/QueryEntities/019_03_04.robot index 07451987da9003762d84cd34e7acc60a82527f1b..1b13c2343b460d5e2cd4ff8075ddbed4ae4fbcfe 100644 --- a/TP/NGSI-LD/ContextInformation/Consumption/Entity/QueryEntities/019_03_04.robot +++ b/TP/NGSI-LD/ContextInformation/Consumption/Entity/QueryEntities/019_03_04.robot @@ -1,8 +1,9 @@ *** Settings *** Documentation Check that one cannot query entities if the requested attribute names are incorrect -Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationConsumption.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -11,7 +12,6 @@ Suite Teardown Delete Entities *** Variables *** -${building_id_prefix}= urn:ngsi-ld:Building: ${filename}= building-minimal.jsonld ${entity_type}= https://ngsi-ld-test-suite/context#Building ${invalid_attribute_one}= id @@ -35,14 +35,14 @@ ${invalid_attribute_two}= type *** Keywords *** Create Entities - ${first_entity_id}= Generate Random Entity Id ${building_id_prefix} + ${first_entity_id}= Generate Random Building Entity Id Set Suite Variable ${first_entity_id} ${create_response1}= Create Entity Selecting Content Type ... ${filename} ... ${first_entity_id} ... ${CONTENT_TYPE_LD_JSON} Check Response Status Code 201 ${create_response1.status_code} - ${second_entity_id}= Generate Random Entity Id ${building_id_prefix} + ${second_entity_id}= Generate Random Building Entity Id Set Suite Variable ${second_entity_id} ${create_response2}= Create Entity Selecting Content Type ... ${filename} diff --git a/TP/NGSI-LD/ContextInformation/Consumption/Entity/QueryEntities/019_03_05.robot b/TP/NGSI-LD/ContextInformation/Consumption/Entity/QueryEntities/019_03_05.robot index f671b75780108ff9e5b93b1a5f9416f1669f70cd..25eef745fb3b5ae9e1c74c5b820fd2bdebc53afe 100644 --- a/TP/NGSI-LD/ContextInformation/Consumption/Entity/QueryEntities/019_03_05.robot +++ b/TP/NGSI-LD/ContextInformation/Consumption/Entity/QueryEntities/019_03_05.robot @@ -1,8 +1,9 @@ *** Settings *** Documentation Check that one cannot query entities if the request has a wrong geometryProperty -Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationConsumption.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -11,13 +12,12 @@ Suite Teardown Delete Entities *** Variables *** -${building_id_prefix}= urn:ngsi-ld:Building: -${filename}= building-location-attribute.jsonld -${entity_type}= Building -${georel}= invalid -${geometry}= Point -${coordinates}= [-8.503,41.202] -${geoproperty}= location +${filename}= building-location-attribute.jsonld +${entity_type}= Building +${georel}= invalid +${geometry}= Point +${coordinates}= [-8.503,41.202] +${geoproperty}= location *** Test Cases *** @@ -43,14 +43,14 @@ ${geoproperty}= location *** Keywords *** Create Entities - ${first_entity_id}= Generate Random Entity Id ${building_id_prefix} + ${first_entity_id}= Generate Random Building Entity Id Set Suite Variable ${first_entity_id} ${create_response1}= Create Entity Selecting Content Type ... ${filename} ... ${first_entity_id} ... ${CONTENT_TYPE_LD_JSON} Check Response Status Code 201 ${create_response1.status_code} - ${second_entity_id}= Generate Random Entity Id ${building_id_prefix} + ${second_entity_id}= Generate Random Building Entity Id Set Suite Variable ${second_entity_id} ${create_response2}= Create Entity Selecting Content Type ... ${filename} diff --git a/TP/NGSI-LD/ContextInformation/Consumption/Entity/QueryEntities/019_04.robot b/TP/NGSI-LD/ContextInformation/Consumption/Entity/QueryEntities/019_04.robot index 6165d6a626fc8143a5d19ea76d47eb2cd8bc7015..4aaeda0345639fcef66bfdf9109afaa753e239ea 100644 --- a/TP/NGSI-LD/ContextInformation/Consumption/Entity/QueryEntities/019_04.robot +++ b/TP/NGSI-LD/ContextInformation/Consumption/Entity/QueryEntities/019_04.robot @@ -1,8 +1,9 @@ *** Settings *** Documentation Check that the queried entities by Id can be returned in a simplified representation -Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationConsumption.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -11,7 +12,6 @@ Suite Teardown Delete Entities *** Variables *** -${building_id_prefix}= urn:ngsi-ld:Building: ${filename}= building-simple-attributes.jsonld ${expectation_filename}= building-simple-attributes-simplified.json ${options_parameter}= keyValues @@ -40,21 +40,21 @@ ${entity_type}= https://ngsi-ld-test-suite/context#Building *** Keywords *** Create Entities - ${first_entity_id}= Generate Random Entity Id ${building_id_prefix} + ${first_entity_id}= Generate Random Building Entity Id Set Suite Variable ${first_entity_id} ${create_response1}= Create Entity Selecting Content Type ... ${filename} ... ${first_entity_id} ... ${CONTENT_TYPE_LD_JSON} Check Response Status Code 201 ${create_response1.status_code} - ${second_entity_id}= Generate Random Entity Id ${building_id_prefix} + ${second_entity_id}= Generate Random Building Entity Id Set Suite Variable ${second_entity_id} ${create_response2}= Create Entity Selecting Content Type ... ${filename} ... ${second_entity_id} ... ${CONTENT_TYPE_LD_JSON} Check Response Status Code 201 ${create_response2.status_code} - ${third_entity_id}= Generate Random Entity Id ${building_id_prefix} + ${third_entity_id}= Generate Random Building Entity Id Set Suite Variable ${third_entity_id} ${create_response3}= Create Entity Selecting Content Type ... ${filename} diff --git a/TP/NGSI-LD/ContextInformation/Consumption/Entity/QueryEntities/019_05.robot b/TP/NGSI-LD/ContextInformation/Consumption/Entity/QueryEntities/019_05.robot index 03bcf9d1c362e17651f37c018d450ae04635c390..c9b3fa1e9e0df4cd265d2cc1a63db1f061d64dae 100644 --- a/TP/NGSI-LD/ContextInformation/Consumption/Entity/QueryEntities/019_05.robot +++ b/TP/NGSI-LD/ContextInformation/Consumption/Entity/QueryEntities/019_05.robot @@ -1,8 +1,8 @@ *** Settings *** Documentation Check that the queried entities by id can be returned in GeoJSON format -Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationConsumption.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -11,7 +11,6 @@ Suite Teardown Delete Entities *** Variables *** -${building_id_prefix}= urn:ngsi-ld:Building: ${filename}= building-location-attribute.jsonld ${expectation_filename}= two-buildings-location-attribute-normalized-019-05.geojson ${expectation_filename_alt1}= two-buildings-location-attribute-normalized-019-05.alternative.geojson diff --git a/TP/NGSI-LD/ContextInformation/Consumption/Entity/QueryEntities/019_06.robot b/TP/NGSI-LD/ContextInformation/Consumption/Entity/QueryEntities/019_06.robot index 6c6e3a148ae2e4c037843dc7c315ea393313639e..7946eac59ae4fe7e0a37298cec65f5ce36990bab 100644 --- a/TP/NGSI-LD/ContextInformation/Consumption/Entity/QueryEntities/019_06.robot +++ b/TP/NGSI-LD/ContextInformation/Consumption/Entity/QueryEntities/019_06.robot @@ -1,8 +1,9 @@ *** Settings *** Documentation Check that one can query entities specifying a maximum number of results -Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationConsumption.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -11,10 +12,9 @@ Suite Teardown Delete Entities *** Variables *** -${building_id_prefix}= urn:ngsi-ld:Building: -${filename}= building-minimal.jsonld -${entity_type}= https://ngsi-ld-test-suite/context#Building -${limit}= 2 +${filename}= building-minimal.jsonld +${entity_type}= https://ngsi-ld-test-suite/context#Building +${limit}= 2 *** Test Cases *** @@ -40,21 +40,21 @@ ${limit}= 2 *** Keywords *** Create Entities - ${first_entity_id}= Generate Random Entity Id ${building_id_prefix} + ${first_entity_id}= Generate Random Building Entity Id Set Suite Variable ${first_entity_id} ${create_response1}= Create Entity Selecting Content Type ... ${filename} ... ${first_entity_id} ... ${CONTENT_TYPE_LD_JSON} Check Response Status Code 201 ${create_response1.status_code} - ${second_entity_id}= Generate Random Entity Id ${building_id_prefix} + ${second_entity_id}= Generate Random Building Entity Id Set Suite Variable ${second_entity_id} ${create_response2}= Create Entity Selecting Content Type ... ${filename} ... ${second_entity_id} ... ${CONTENT_TYPE_LD_JSON} Check Response Status Code 201 ${create_response2.status_code} - ${third_entity_id}= Generate Random Entity Id ${building_id_prefix} + ${third_entity_id}= Generate Random Building Entity Id Set Suite Variable ${third_entity_id} ${create_response3}= Create Entity Selecting Content Type ... ${filename} diff --git a/TP/NGSI-LD/ContextInformation/Consumption/Entity/QueryEntities/019_07.robot b/TP/NGSI-LD/ContextInformation/Consumption/Entity/QueryEntities/019_07.robot index 60a53e038e6ce090f7f5aa4428dc7d6eac09b793..4ed72f2b9c01c6c9ad2616d715f4dd12f9380af0 100644 --- a/TP/NGSI-LD/ContextInformation/Consumption/Entity/QueryEntities/019_07.robot +++ b/TP/NGSI-LD/ContextInformation/Consumption/Entity/QueryEntities/019_07.robot @@ -1,8 +1,9 @@ *** Settings *** Documentation If the count parameter is set to true the special HTTP header NGSILD-Results-Count is set in the response and it must contain the total number of matching results. -Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationConsumption.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -12,7 +13,6 @@ Test Template Query Entities With Count *** Variables *** -${building_id_prefix}= urn:ngsi-ld:Building: ${first_entity_filename}= building-simple-attributes.jsonld ${second_entity_filename}= building-simple-attributes-second.jsonld ${entity_type}= Building @@ -42,14 +42,14 @@ Query Entities With Count Check Response Headers Containing NGSILD-Results-Count Equals To ${expected_count} ${response.headers} Setup Initial Entities - ${first_entity_id}= Generate Random Entity Id ${building_id_prefix} + ${first_entity_id}= Generate Random Building Entity Id Set Suite Variable ${first_entity_id} ${create_response1}= Create Entity Selecting Content Type ... ${first_entity_filename} ... ${first_entity_id} ... ${CONTENT_TYPE_LD_JSON} Check Response Status Code 201 ${create_response1.status_code} - ${second_entity_id}= Generate Random Entity Id ${building_id_prefix} + ${second_entity_id}= Generate Random Building Entity Id Set Suite Variable ${second_entity_id} ${create_response2}= Create Entity Selecting Content Type ... ${second_entity_filename} diff --git a/TP/NGSI-LD/ContextInformation/Consumption/Entity/QueryEntities/019_08.robot b/TP/NGSI-LD/ContextInformation/Consumption/Entity/QueryEntities/019_08.robot index 81365192e87aa1e1b927f08625dfe1297b14aba3..008cd7c8fbb30569329e431d2575ebdb416bc08c 100644 --- a/TP/NGSI-LD/ContextInformation/Consumption/Entity/QueryEntities/019_08.robot +++ b/TP/NGSI-LD/ContextInformation/Consumption/Entity/QueryEntities/019_08.robot @@ -1,8 +1,9 @@ *** Settings *** Documentation Query entities with Entity Type Selection Language. -Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationConsumption.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -47,21 +48,21 @@ Query entities using Entity Type Selection Language ... ${response.json()} Setup Initial Entities - ${first_entity_id}= Generate Random Entity Id ${entity_id_prefix} + ${first_entity_id}= Generate Random Id ${entity_id_prefix} Set Suite Variable ${first_entity_id} ${create_response1}= Create Entity Selecting Content Type ... ${first_entity_filename} ... ${first_entity_id} ... ${CONTENT_TYPE_LD_JSON} Check Response Status Code 201 ${create_response1.status_code} - ${second_entity_id}= Generate Random Entity Id ${entity_id_prefix} + ${second_entity_id}= Generate Random Id ${entity_id_prefix} Set Suite Variable ${second_entity_id} ${create_response2}= Create Entity Selecting Content Type ... ${second_entity_filename} ... ${second_entity_id} ... ${CONTENT_TYPE_LD_JSON} Check Response Status Code 201 ${create_response2.status_code} - ${third_entity_id}= Generate Random Entity Id ${entity_id_prefix} + ${third_entity_id}= Generate Random Id ${entity_id_prefix} Set Suite Variable ${third_entity_id} ${create_response3}= Create Entity Selecting Content Type ... ${third_entity_filename} diff --git a/TP/NGSI-LD/ContextInformation/Consumption/Entity/QueryEntities/019_09.robot b/TP/NGSI-LD/ContextInformation/Consumption/Entity/QueryEntities/019_09.robot index 163251d3cffd99046ba475ecb30ebe4f5fc56ad9..81079c49c34f85c08cb74f0f12d3fea7937d46f6 100644 --- a/TP/NGSI-LD/ContextInformation/Consumption/Entity/QueryEntities/019_09.robot +++ b/TP/NGSI-LD/ContextInformation/Consumption/Entity/QueryEntities/019_09.robot @@ -1,8 +1,9 @@ *** Settings *** Documentation Check that one can query several entities based on q -Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationConsumption.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -12,8 +13,7 @@ Test Template Query several entities based on q *** Variables *** -${building_id_prefix}= urn:ngsi-ld:Building: -${entity_type}= https://ngsi-ld-test-suite/context#Building +${entity_type}= https://ngsi-ld-test-suite/context#Building *** Test Cases *** Q EXPECTED_COUNT @@ -63,7 +63,7 @@ Query several entities based on q Check Response Headers Containing NGSILD-Results-Count Equals To ${expected_count} ${response.headers} Setup Initial Entities - ${first_entity_id}= Generate Random Entity Id ${building_id_prefix} + ${first_entity_id}= Generate Random Building Entity Id Set Suite Variable ${first_entity_id} ${create_response1}= Create Entity Selecting Content Type ... building-simple-attributes.jsonld @@ -71,7 +71,7 @@ Setup Initial Entities ... ${CONTENT_TYPE_LD_JSON} Check Response Status Code 201 ${create_response1.status_code} - ${second_entity_id}= Generate Random Entity Id ${building_id_prefix} + ${second_entity_id}= Generate Random Building Entity Id Set Suite Variable ${second_entity_id} ${create_response2}= Create Entity Selecting Content Type ... building-simple-attributes-second.jsonld @@ -79,7 +79,7 @@ Setup Initial Entities ... ${CONTENT_TYPE_LD_JSON} Check Response Status Code 201 ${create_response2.status_code} - ${third_entity_id}= Generate Random Entity Id ${building_id_prefix} + ${third_entity_id}= Generate Random Building Entity Id Set Suite Variable ${third_entity_id} ${create_response3}= Create Entity Selecting Content Type ... building-simple-attributes-third.jsonld diff --git a/TP/NGSI-LD/ContextInformation/Consumption/Entity/QueryEntities/019_10.robot b/TP/NGSI-LD/ContextInformation/Consumption/Entity/QueryEntities/019_10.robot index 87ca2a2fb49e40df2f122d88d6ac289d3efded28..faef128d510d04d3c9a22019613e5fdb33101203 100644 --- a/TP/NGSI-LD/ContextInformation/Consumption/Entity/QueryEntities/019_10.robot +++ b/TP/NGSI-LD/ContextInformation/Consumption/Entity/QueryEntities/019_10.robot @@ -1,8 +1,9 @@ *** Settings *** Documentation Check that one can query several entities based on complex geoqueries with Point target geometries -Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationConsumption.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -11,10 +12,6 @@ Suite Teardown Delete Entities Test Template Query several entities based on complex geoqueries -*** Variables *** -${building_id_prefix}= urn:ngsi-ld:Building: - - *** Test Cases *** GEOREL GEOMETRY COORDINATES EXPECTED_COUNT 019_10_01 QueryOnEqualsPoint [Documentation] Check that one can query with an exact point @@ -67,7 +64,7 @@ Query several entities based on complex geoqueries Check Response Headers Containing NGSILD-Results-Count Equals To ${expected_count} ${response.headers} Setup Initial Entities - ${first_entity_id}= Generate Random Entity Id ${building_id_prefix} + ${first_entity_id}= Generate Random Building Entity Id Set Suite Variable ${first_entity_id} ${create_response1}= Create Entity Selecting Content Type ... building-location-attribute.jsonld @@ -75,7 +72,7 @@ Setup Initial Entities ... ${CONTENT_TYPE_LD_JSON} Check Response Status Code 201 ${create_response1.status_code} - ${second_entity_id}= Generate Random Entity Id ${building_id_prefix} + ${second_entity_id}= Generate Random Building Entity Id Set Suite Variable ${second_entity_id} ${create_response2}= Create Entity Selecting Content Type ... building-location-attribute-second.jsonld @@ -83,7 +80,7 @@ Setup Initial Entities ... ${CONTENT_TYPE_LD_JSON} Check Response Status Code 201 ${create_response2.status_code} - ${third_entity_id}= Generate Random Entity Id ${building_id_prefix} + ${third_entity_id}= Generate Random Building Entity Id Set Suite Variable ${third_entity_id} ${create_response3}= Create Entity Selecting Content Type ... building-location-attribute-third.jsonld diff --git a/TP/NGSI-LD/ContextInformation/Consumption/Entity/QueryEntities/019_11.robot b/TP/NGSI-LD/ContextInformation/Consumption/Entity/QueryEntities/019_11.robot index 72f9d9f2ee8ffc10875d0aad198eb8927778cfab..807406dc0ef5b9b9dfe4947713fd452379245d0a 100644 --- a/TP/NGSI-LD/ContextInformation/Consumption/Entity/QueryEntities/019_11.robot +++ b/TP/NGSI-LD/ContextInformation/Consumption/Entity/QueryEntities/019_11.robot @@ -1,8 +1,9 @@ *** Settings *** Documentation Check that one can query several entities based on complex geoqueries with Polygon target geometries -Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationConsumption.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -11,10 +12,6 @@ Suite Teardown Delete Entities Test Template Query several entities based on complex geoqueries -*** Variables *** -${building_id_prefix}= urn:ngsi-ld:Building: - - *** Test Cases *** GEOREL GEOMETRY COORDINATES EXPECTED_COUNT 019_11_01 QueryOnEqualsPolygon [Documentation] Check that one can query with an exact polygon @@ -67,7 +64,7 @@ Query several entities based on complex geoqueries Check Response Headers Containing NGSILD-Results-Count Equals To ${expected_count} ${response.headers} Setup Initial Entities - ${first_entity_id}= Generate Random Entity Id ${building_id_prefix} + ${first_entity_id}= Generate Random Building Entity Id Set Suite Variable ${first_entity_id} ${create_response1}= Create Entity Selecting Content Type ... building-location-polygon.jsonld @@ -75,7 +72,7 @@ Setup Initial Entities ... ${CONTENT_TYPE_LD_JSON} Check Response Status Code 201 ${create_response1.status_code} - ${second_entity_id}= Generate Random Entity Id ${building_id_prefix} + ${second_entity_id}= Generate Random Building Entity Id Set Suite Variable ${second_entity_id} ${create_response2}= Create Entity Selecting Content Type ... building-location-polygon-second.jsonld diff --git a/TP/NGSI-LD/ContextInformation/Consumption/Entity/RetrieveEntity/018_01_01.robot b/TP/NGSI-LD/ContextInformation/Consumption/Entity/RetrieveEntity/018_01_01.robot index 811a68876570297810cf3ab320594ec8515e851c..29172e3a7f18598343acb6f46ac2e70cebe93279 100644 --- a/TP/NGSI-LD/ContextInformation/Consumption/Entity/RetrieveEntity/018_01_01.robot +++ b/TP/NGSI-LD/ContextInformation/Consumption/Entity/RetrieveEntity/018_01_01.robot @@ -1,8 +1,9 @@ *** Settings *** Documentation Check that one can get an entity by id -Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationConsumption.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -11,7 +12,6 @@ Suite Teardown Delete Created Entity *** Variables *** -${building_id_prefix}= urn:ngsi-ld:Building: ${filename}= building-simple-attributes.jsonld ${expectation_filename}= building-simple-attributes.jsonld @@ -34,7 +34,7 @@ ${expectation_filename}= building-simple-attributes.jsonld *** Keywords *** Create Entity - ${entity_id}= Generate Random Entity Id ${building_id_prefix} + ${entity_id}= Generate Random Building Entity Id Set Suite Variable ${entity_id} ${create_response}= Create Entity Selecting Content Type ... ${filename} diff --git a/TP/NGSI-LD/ContextInformation/Consumption/Entity/RetrieveEntity/018_01_02.robot b/TP/NGSI-LD/ContextInformation/Consumption/Entity/RetrieveEntity/018_01_02.robot index 1f16bb8bddc2480dcead5346dbc9a8114069e491..6a061c2259e085cc2776e626d6db35dc55f02b8a 100644 --- a/TP/NGSI-LD/ContextInformation/Consumption/Entity/RetrieveEntity/018_01_02.robot +++ b/TP/NGSI-LD/ContextInformation/Consumption/Entity/RetrieveEntity/018_01_02.robot @@ -1,8 +1,9 @@ *** Settings *** Documentation Check that one can query some attributes from an entity -Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationConsumption.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -11,7 +12,6 @@ Suite Teardown Delete Created Entity *** Variables *** -${building_id_prefix}= urn:ngsi-ld:Building: ${filename}= building-simple-attributes.jsonld ${expectation_filename}= building-simple-attributes-query.jsonld ${attribute_airqualitylevel}= https://ngsi-ld-test-suite/context#airQualityLevel @@ -42,7 +42,7 @@ ${attribute_subcategory}= https://ngsi-ld-test-suite/context#subCatego *** Keywords *** Create Entity - ${entity_id}= Generate Random Entity Id ${building_id_prefix} + ${entity_id}= Generate Random Building Entity Id Set Suite Variable ${entity_id} ${create_response}= Create Entity Selecting Content Type ... ${filename} diff --git a/TP/NGSI-LD/ContextInformation/Consumption/Entity/RetrieveEntity/018_03_01.robot b/TP/NGSI-LD/ContextInformation/Consumption/Entity/RetrieveEntity/018_03_01.robot index 6e2cac12cc93968b1f1923ba88a13d88022d9bef..bccd230d03aa5398bb6e46d0b778f9363a4f39ec 100644 --- a/TP/NGSI-LD/ContextInformation/Consumption/Entity/RetrieveEntity/018_03_01.robot +++ b/TP/NGSI-LD/ContextInformation/Consumption/Entity/RetrieveEntity/018_03_01.robot @@ -1,20 +1,17 @@ *** Settings *** Documentation Check that one cannot get an entity if the entity id is not known to the system +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationConsumption.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource -*** Variables *** -${building_id_prefix}= urn:ngsi-ld:Building: - - *** Test Cases *** 018_03_01 Get an entity if the Entity Id is not known to the system [Documentation] Check that one cannot get an entity if the entity id is not known to the system [Tags] e-retrieve 5_7_1 - ${entity_id}= Generate Random Entity Id ${building_id_prefix} + ${entity_id}= Generate Random Building Entity Id ${response}= Query Entity ... id=${entity_id} ... accept=${CONTENT_TYPE_LD_JSON} diff --git a/TP/NGSI-LD/ContextInformation/Consumption/Entity/RetrieveEntity/018_03_02.robot b/TP/NGSI-LD/ContextInformation/Consumption/Entity/RetrieveEntity/018_03_02.robot index a5724abb1dde30f313c25fb93c810d75b64ff670..40533d529d92452b9ba1f018d23e6623a87c89a6 100644 --- a/TP/NGSI-LD/ContextInformation/Consumption/Entity/RetrieveEntity/018_03_02.robot +++ b/TP/NGSI-LD/ContextInformation/Consumption/Entity/RetrieveEntity/018_03_02.robot @@ -1,8 +1,9 @@ *** Settings *** Documentation Check that one cannot get an entity if an attribute is not known to the system -Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationConsumption.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -11,7 +12,6 @@ Suite Teardown Delete Created Entity *** Variables *** -${building_id_prefix}= urn:ngsi-ld:Building: ${filename}= building-simple-attributes.jsonld ${attribute_not_known}= property_not_found @@ -36,7 +36,7 @@ ${attribute_not_known}= property_not_found *** Keywords *** Create Entity - ${entity_id}= Generate Random Entity Id ${building_id_prefix} + ${entity_id}= Generate Random Building Entity Id Set Suite Variable ${entity_id} ${create_response}= Create Entity Selecting Content Type ... ${filename} diff --git a/TP/NGSI-LD/ContextInformation/Consumption/Entity/RetrieveEntity/018_04.robot b/TP/NGSI-LD/ContextInformation/Consumption/Entity/RetrieveEntity/018_04.robot index 2d54419c2a1e86b5fa94a888a1cf6346e4194b7f..c10c7e8a3a4b8badde462dfd852dfad3b1a84880 100644 --- a/TP/NGSI-LD/ContextInformation/Consumption/Entity/RetrieveEntity/018_04.robot +++ b/TP/NGSI-LD/ContextInformation/Consumption/Entity/RetrieveEntity/018_04.robot @@ -1,8 +1,9 @@ *** Settings *** Documentation Check that the queried entity by Id can be returned in a simplified representation -Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationConsumption.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -11,7 +12,6 @@ Test Teardown Delete Created Entity *** Variables *** -${building_id_prefix}= urn:ngsi-ld:Building: ${filename}= building-simple-attributes.jsonld ${expectation_filename}= building-simple-attributes-simplified.jsonld ${options_parameter}= keyValues @@ -36,7 +36,7 @@ ${options_parameter}= keyValues *** Keywords *** Create Initial Entity - ${entity_id}= Generate Random Entity Id ${building_id_prefix} + ${entity_id}= Generate Random Building Entity Id Set Test Variable ${entity_id} ${create_response}= Create Entity Selecting Content Type ... ${filename} diff --git a/TP/NGSI-LD/ContextInformation/Consumption/Entity/RetrieveEntity/018_05.robot b/TP/NGSI-LD/ContextInformation/Consumption/Entity/RetrieveEntity/018_05.robot index 6d3a4ddb1114191fc8e6c669c01009ea6f853478..7ffa0a6137cf6f967b37bfa5dc849c2255620363 100644 --- a/TP/NGSI-LD/ContextInformation/Consumption/Entity/RetrieveEntity/018_05.robot +++ b/TP/NGSI-LD/ContextInformation/Consumption/Entity/RetrieveEntity/018_05.robot @@ -1,8 +1,9 @@ *** Settings *** Documentation Check that the queried entity by id can be returned in a GeoJSON format -Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationConsumption.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -12,8 +13,7 @@ Test Template Retrieve Entity In GeoJSON Representation *** Variables *** -${building_id_prefix}= urn:ngsi-ld:Building: -${filename}= building-two-geometry-attributes.jsonld +${filename}= building-two-geometry-attributes.jsonld *** Test Cases *** OPTIONS EXPECTATION_FILENAME @@ -48,7 +48,7 @@ Retrieve Entity In GeoJSON Representation ... response_body=${response.json()} Create Initial Entity - ${entity_id}= Generate Random Entity Id ${building_id_prefix} + ${entity_id}= Generate Random Building Entity Id Set Suite Variable ${entity_id} ${response}= Create Entity Selecting Content Type ... ${filename} diff --git a/TP/NGSI-LD/ContextInformation/Consumption/Entity/RetrieveEntity/018_06.robot b/TP/NGSI-LD/ContextInformation/Consumption/Entity/RetrieveEntity/018_06.robot index 81eeff7bad1756ab0b178029272d81c8cc0ef88c..4b6229a6c63bbf1cfead5890b3e0081f307a2733 100644 --- a/TP/NGSI-LD/ContextInformation/Consumption/Entity/RetrieveEntity/018_06.robot +++ b/TP/NGSI-LD/ContextInformation/Consumption/Entity/RetrieveEntity/018_06.robot @@ -1,8 +1,9 @@ *** Settings *** Documentation Check that the JSON-LD @context is obtained from a Link header if present and that the default JSON-LD @context is used if not present -Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationConsumption.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -12,7 +13,6 @@ Test Template Review JSON-LD Resolution When retrieving an entity *** Variables *** -${building_id_prefix}= urn:ngsi-ld:Building: ${filename}= building-simple-attributes.json ${empty_jsonld_expectation_filename}= building-simple-attributes-expanded.json ${creation_jsonld_expectation_filename}= building-simple-attributes-compacted.json @@ -39,7 +39,7 @@ Review JSON-LD Resolution When retrieving an entity Check Response Body Containing Entity element ${expected_payload} ${entity_id} ${response.json()} Setup Initial Entity - ${entity_id}= Generate Random Entity Id ${building_id_prefix} + ${entity_id}= Generate Random Building Entity Id ${create_response}= Create Entity Selecting Content Type ... ${filename} ... ${entity_id} diff --git a/TP/NGSI-LD/ContextInformation/Consumption/Entity/RetrieveEntity/018_07.robot b/TP/NGSI-LD/ContextInformation/Consumption/Entity/RetrieveEntity/018_07.robot index cf211b2ffbbd544cfecb94db0fb8da9e14884238..5fb5efa3011599494f2f51e473e15bfc48de7e13 100644 --- a/TP/NGSI-LD/ContextInformation/Consumption/Entity/RetrieveEntity/018_07.robot +++ b/TP/NGSI-LD/ContextInformation/Consumption/Entity/RetrieveEntity/018_07.robot @@ -1,8 +1,9 @@ *** Settings *** Documentation Check that one can retrieve an entity using Language Filter -Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationConsumption.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -12,8 +13,7 @@ Test Template Retrieve Entity With Language Filter *** Variables *** -${building_id_prefix}= urn:ngsi-ld:Building: -${filename}= building-language-property.jsonld +${filename}= building-language-property.jsonld *** Test Cases *** LANGUAGE_FILTER OPTIONS EXPECTATION_FILENAME @@ -54,7 +54,7 @@ Retrieve Entity With Language Filter ... ${response.json()} Create Initial Entity - ${entity_id}= Generate Random Entity Id ${building_id_prefix} + ${entity_id}= Generate Random Building Entity Id Set Suite Variable ${entity_id} ${response}= Create Entity Selecting Content Type ... ${filename} diff --git a/TP/NGSI-LD/ContextInformation/Consumption/Entity/RetrieveEntity/018_08.robot b/TP/NGSI-LD/ContextInformation/Consumption/Entity/RetrieveEntity/018_08.robot index 91b3ba086ddec7d338fbc40c3d883efe7ebb516b..bba14ed29925eb6e301cbcff74ddb3a1fac2b0e6 100644 --- a/TP/NGSI-LD/ContextInformation/Consumption/Entity/RetrieveEntity/018_08.robot +++ b/TP/NGSI-LD/ContextInformation/Consumption/Entity/RetrieveEntity/018_08.robot @@ -1,8 +1,9 @@ *** Settings *** Documentation Check that an entity with observationSpace geospatial Property can be retrieved -Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationConsumption.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -12,8 +13,7 @@ Test Template Retrieve Entity With observationSpace Geospatial Property *** Variables *** -${building_id_prefix}= urn:ngsi-ld:Building: -${filename}= building-observation-space-geoproperty.jsonld +${filename}= building-observation-space-geoproperty.jsonld *** Test Cases *** OPTIONS EXPECTATION_FILENAME @@ -37,7 +37,7 @@ Retrieve Entity With observationSpace Geospatial Property Check Response Body Containing Entity element ${expectation_filename} ${entity_id} ${response.json()} Create Initial Entity - ${entity_id}= Generate Random Entity Id ${building_id_prefix} + ${entity_id}= Generate Random Building Entity Id Set Suite Variable ${entity_id} ${response}= Create Entity Selecting Content Type ... ${filename} diff --git a/TP/NGSI-LD/ContextInformation/Consumption/Entity/RetrieveEntity/018_09.robot b/TP/NGSI-LD/ContextInformation/Consumption/Entity/RetrieveEntity/018_09.robot index 88fa76992621d5dbb4b3fb5cef2fc0d51f8472e6..bb6cdd021602067a9b938ea5dd38b239d6b32b25 100644 --- a/TP/NGSI-LD/ContextInformation/Consumption/Entity/RetrieveEntity/018_09.robot +++ b/TP/NGSI-LD/ContextInformation/Consumption/Entity/RetrieveEntity/018_09.robot @@ -1,8 +1,9 @@ *** Settings *** Documentation Check that an entity with operationSpace geospatial Property can be retrieved -Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationConsumption.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -12,8 +13,7 @@ Test Template Retrieve Entity With operationSpace Geospatial Property *** Variables *** -${building_id_prefix}= urn:ngsi-ld:Building: -${filename}= building-operation-space-geoproperty.jsonld +${filename}= building-operation-space-geoproperty.jsonld *** Test Cases *** OPTIONS EXPECTATION_FILENAME @@ -37,7 +37,7 @@ Retrieve Entity With operationSpace Geospatial Property Check Response Body Containing Entity element ${expectation_filename} ${entity_id} ${response.json()} Create Initial Entity - ${entity_id}= Generate Random Entity Id ${building_id_prefix} + ${entity_id}= Generate Random Building Entity Id Set Suite Variable ${entity_id} ${response}= Create Entity Selecting Content Type ... ${filename} diff --git a/TP/NGSI-LD/ContextInformation/Consumption/TemporalEntity/QueryTemporalEvolutionOfEntities/021_01.robot b/TP/NGSI-LD/ContextInformation/Consumption/TemporalEntity/QueryTemporalEvolutionOfEntities/021_01.robot index 943c1bda078dcb8030abb0c8c792f69e738462fd..903edd2622be42775a54683b98272fcbde4edce1 100644 --- a/TP/NGSI-LD/ContextInformation/Consumption/TemporalEntity/QueryTemporalEvolutionOfEntities/021_01.robot +++ b/TP/NGSI-LD/ContextInformation/Consumption/TemporalEntity/QueryTemporalEvolutionOfEntities/021_01.robot @@ -61,7 +61,7 @@ Setup Initial Entities ... ${second_temporal_entity_representation_id} Check Response Status Code 201 ${create_response2.status_code} Set Test Variable ${second_temporal_entity_representation_id} - ${third_temporal_entity_representation_id}= Catenate ${BUS_ID_PREFIX}021-13-A + ${third_temporal_entity_representation_id}= Generate Bus Entity Id 021-13-A ${create_response3}= Create Temporal Representation Of Entity ... ${bus_payload_file} ... ${third_temporal_entity_representation_id} diff --git a/TP/NGSI-LD/ContextInformation/Consumption/TemporalEntity/QueryTemporalEvolutionOfEntities/021_05.robot b/TP/NGSI-LD/ContextInformation/Consumption/TemporalEntity/QueryTemporalEvolutionOfEntities/021_05.robot index c36de8f73c81404404529c012911f6a163bc346c..d9dc1451f528adbe038dccb33cca55a86307cf14 100644 --- a/TP/NGSI-LD/ContextInformation/Consumption/TemporalEntity/QueryTemporalEvolutionOfEntities/021_05.robot +++ b/TP/NGSI-LD/ContextInformation/Consumption/TemporalEntity/QueryTemporalEvolutionOfEntities/021_05.robot @@ -43,7 +43,7 @@ Setup Initial Temporal Entities ... ${first_temporal_entity_representation_id} Check Response Status Code 201 ${create_response1.status_code} Set Suite Variable ${first_temporal_entity_representation_id} - ${second_temporal_entity_representation_id}= Catenate ${BUS_ID_PREFIX}021-05-A + ${second_temporal_entity_representation_id}= Generate Bus Entity Id 021-05-A ${create_response2}= Create Temporal Representation Of Entity ... ${bus_payload_file} ... ${second_temporal_entity_representation_id} diff --git a/TP/NGSI-LD/ContextInformation/Consumption/TemporalEntity/QueryTemporalEvolutionOfEntities/021_11.robot b/TP/NGSI-LD/ContextInformation/Consumption/TemporalEntity/QueryTemporalEvolutionOfEntities/021_11.robot index e4a855b03345a8eb1fb2a49e93927106e08564c4..d7acb604bde991438927287760172caaa009f395 100644 --- a/TP/NGSI-LD/ContextInformation/Consumption/TemporalEntity/QueryTemporalEvolutionOfEntities/021_11.robot +++ b/TP/NGSI-LD/ContextInformation/Consumption/TemporalEntity/QueryTemporalEvolutionOfEntities/021_11.robot @@ -1,6 +1,7 @@ *** Settings *** Documentation Check that one can query the temporal evolution of entities with a limit to the number of entities to be retrieved +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/TemporalContextInformationConsumption.resource Resource ${EXECDIR}/resources/ApiUtils/TemporalContextInformationProvision.resource Resource ${EXECDIR}/resources/AssertionUtils.resource @@ -12,7 +13,6 @@ Test Template Query the temporal evolution of entities with a limit to the *** Variables *** -${vehicle_id_prefix}= urn:ngsi-ld:Vehicle: ${first_vehicle_payload_file}= 2020-08-vehicle-temporal-representation.jsonld ${second_vehicle_payload_file}= 2020-09-vehicle-temporal-representation.jsonld @@ -41,19 +41,19 @@ Query the temporal evolution of entities with a limit to the number of entities Check Response Body Containing Number Of Entities Vehicle ${limit} ${response.json()} Setup Initial Temporal Entities - ${first_temporal_entity_representation_id}= Generate Random Entity Id ${vehicle_id_prefix} + ${first_temporal_entity_representation_id}= Generate Random Vehicle Entity Id ${create_response1}= Create Temporal Representation Of Entity ... ${first_vehicle_payload_file} ... ${first_temporal_entity_representation_id} Check Response Status Code 201 ${create_response1.status_code} Set Test Variable ${first_temporal_entity_representation_id} - ${second_temporal_entity_representation_id}= Generate Random Entity Id ${vehicle_id_prefix} + ${second_temporal_entity_representation_id}= Generate Random Vehicle Entity Id ${create_response2}= Create Temporal Representation Of Entity ... ${second_vehicle_payload_file} ... ${second_temporal_entity_representation_id} Check Response Status Code 201 ${create_response2.status_code} Set Test Variable ${second_temporal_entity_representation_id} - ${third_temporal_entity_representation_id}= Generate Random Entity Id ${vehicle_id_prefix} + ${third_temporal_entity_representation_id}= Generate Random Vehicle Entity Id ${create_response3}= Create Temporal Representation Of Entity ... ${second_vehicle_payload_file} ... ${third_temporal_entity_representation_id} diff --git a/TP/NGSI-LD/ContextInformation/Consumption/TemporalEntity/QueryTemporalEvolutionOfEntities/021_12.robot b/TP/NGSI-LD/ContextInformation/Consumption/TemporalEntity/QueryTemporalEvolutionOfEntities/021_12.robot index 34a21d36be07c16672572a2e2ab155a1f8b0aed2..187de2fbef54f02436721cb4c11a2c8e48607b66 100644 --- a/TP/NGSI-LD/ContextInformation/Consumption/TemporalEntity/QueryTemporalEvolutionOfEntities/021_12.robot +++ b/TP/NGSI-LD/ContextInformation/Consumption/TemporalEntity/QueryTemporalEvolutionOfEntities/021_12.robot @@ -1,6 +1,7 @@ *** Settings *** Documentation Check that one cannot query the temporal evolution of entities with an invalid request or invalid request content +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/TemporalContextInformationConsumption.resource Resource ${EXECDIR}/resources/ApiUtils/TemporalContextInformationProvision.resource Resource ${EXECDIR}/resources/AssertionUtils.resource @@ -11,7 +12,6 @@ Suite Teardown Delete Initial Temporal Entity *** Variables *** -${vehicle_id_prefix}= urn:ngsi-ld:Vehicle: ${vehicle_payload_file}= 2020-08-vehicle-temporal-representation.jsonld @@ -32,7 +32,7 @@ ${vehicle_payload_file}= 2020-08-vehicle-temporal-representation.jsonld *** Keywords *** Create Temporal Entity - ${temporal_entity_representation_id}= Generate Random Entity Id ${vehicle_id_prefix} + ${temporal_entity_representation_id}= Generate Random Vehicle Entity Id ${create_response}= Create Temporal Representation Of Entity ... ${vehicle_payload_file} ... ${temporal_entity_representation_id} diff --git a/TP/NGSI-LD/ContextInformation/Consumption/TemporalEntity/QueryTemporalEvolutionOfEntities/021_13.robot b/TP/NGSI-LD/ContextInformation/Consumption/TemporalEntity/QueryTemporalEvolutionOfEntities/021_13.robot index f1a6e5d14b028fa5426f74ddd482b388fb3d1c7a..4e5b52f11c425130d8b7ea432f0924f7d4679c56 100644 --- a/TP/NGSI-LD/ContextInformation/Consumption/TemporalEntity/QueryTemporalEvolutionOfEntities/021_13.robot +++ b/TP/NGSI-LD/ContextInformation/Consumption/TemporalEntity/QueryTemporalEvolutionOfEntities/021_13.robot @@ -58,7 +58,7 @@ Setup Initial Temporal Entities ... ${second_temporal_entity_representation_id} Check Response Status Code 201 ${create_response2.status_code} Set Test Variable ${second_temporal_entity_representation_id} - ${third_temporal_entity_representation_id}= Catenate ${BUS_ID_PREFIX}021-13-A + ${third_temporal_entity_representation_id}= Generate Bus Entity Id 021-13-A ${create_response3}= Create Temporal Representation Of Entity ... ${bus_payload_file} ... ${third_temporal_entity_representation_id} diff --git a/TP/NGSI-LD/ContextInformation/Consumption/TemporalEntity/QueryTemporalEvolutionOfEntities/021_14.robot b/TP/NGSI-LD/ContextInformation/Consumption/TemporalEntity/QueryTemporalEvolutionOfEntities/021_14.robot index 2143993e2eac63fcbdb51505a48cce993edf87e6..7a68800c91034e38e857066dea7b96621829154e 100644 --- a/TP/NGSI-LD/ContextInformation/Consumption/TemporalEntity/QueryTemporalEvolutionOfEntities/021_14.robot +++ b/TP/NGSI-LD/ContextInformation/Consumption/TemporalEntity/QueryTemporalEvolutionOfEntities/021_14.robot @@ -60,7 +60,7 @@ Setup Initial Entities ... ${second_temporal_entity_representation_id} Check Response Status Code 201 ${create_response2.status_code} Set Test Variable ${second_temporal_entity_representation_id} - ${third_temporal_entity_representation_id}= Catenate ${BUS_ID_PREFIX}021-14-A + ${third_temporal_entity_representation_id}= Generate Bus Entity Id 021-14-A ${create_response3}= Create Temporal Representation Of Entity ... ${bus_payload_file} ... ${third_temporal_entity_representation_id} diff --git a/TP/NGSI-LD/ContextInformation/Consumption/TemporalEntity/QueryTemporalEvolutionOfEntities/021_15.robot b/TP/NGSI-LD/ContextInformation/Consumption/TemporalEntity/QueryTemporalEvolutionOfEntities/021_15.robot index 0a4d9062a20f9ac533fe19bdc2724f36b4eb1593..b2a3b81bdb9a977cb099b3f596424db136ccc096 100644 --- a/TP/NGSI-LD/ContextInformation/Consumption/TemporalEntity/QueryTemporalEvolutionOfEntities/021_15.robot +++ b/TP/NGSI-LD/ContextInformation/Consumption/TemporalEntity/QueryTemporalEvolutionOfEntities/021_15.robot @@ -1,6 +1,7 @@ *** Settings *** Documentation Check temporal pagination is applied when querying the temporal evolution of entities +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/TemporalContextInformationConsumption.resource Resource ${EXECDIR}/resources/ApiUtils/TemporalContextInformationProvision.resource Resource ${EXECDIR}/resources/AssertionUtils.resource @@ -12,7 +13,6 @@ Test Template Retrieve Temporal Entities *** Variables *** -${vehicule_id_prefix}= urn:ngsi-ld:Vehicle: ${first_vehicle_payload_file}= pagination/2020-01-vehicule-temporal-representation-twenty-instances.jsonld ${second_vehicle_payload_file}= 2020-09-vehicle-temporal-representation.jsonld ${timeBefore}= 2019-01-01T01:01:00Z @@ -117,8 +117,8 @@ Retrieve Temporal Entities END Setup Initial Entities - ${first_temporal_entity_representation_id}= Generate Random Entity Id ${vehicule_id_prefix} - ${second_temporal_entity_representation_id}= Generate Random Entity Id ${vehicule_id_prefix} + ${first_temporal_entity_representation_id}= Generate Random Vehicle Entity Id + ${second_temporal_entity_representation_id}= Generate Random Vehicle Entity Id ${response}= Create Temporal Representation Of Entity ... ${first_vehicle_payload_file} ... ${first_temporal_entity_representation_id} diff --git a/TP/NGSI-LD/ContextInformation/Consumption/TemporalEntity/QueryTemporalEvolutionOfEntities/021_16.robot b/TP/NGSI-LD/ContextInformation/Consumption/TemporalEntity/QueryTemporalEvolutionOfEntities/021_16.robot index cbd467863db1159cceac532a09edfb9e8c1d277b..5aa9de130b8f62fb9f8deefc30d9dca634e98cab 100644 --- a/TP/NGSI-LD/ContextInformation/Consumption/TemporalEntity/QueryTemporalEvolutionOfEntities/021_16.robot +++ b/TP/NGSI-LD/ContextInformation/Consumption/TemporalEntity/QueryTemporalEvolutionOfEntities/021_16.robot @@ -1,6 +1,7 @@ *** Settings *** Documentation Check temporal pagination is applied when querying the temporal evolution of entities via POST +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/TemporalContextInformationConsumption.resource Resource ${EXECDIR}/resources/ApiUtils/TemporalContextInformationProvision.resource Resource ${EXECDIR}/resources/AssertionUtils.resource @@ -12,7 +13,6 @@ Test Template Retrieve Temporal Entities Via Post *** Variables *** -${vehicule_id_prefix}= urn:ngsi-ld:Vehicle: ${first_vehicle_payload_file}= pagination/2020-01-vehicule-temporal-representation-twenty-instances.jsonld ${second_vehicle_payload_file}= 2020-09-vehicle-temporal-representation.jsonld @@ -46,8 +46,8 @@ Retrieve Temporal Entities Via Post Check Content Range Part Equal ${unit} date-time Setup Initial Entities - ${first_temporal_entity_representation_id}= Generate Random Entity Id ${vehicule_id_prefix} - ${second_temporal_entity_representation_id}= Generate Random Entity Id ${vehicule_id_prefix} + ${first_temporal_entity_representation_id}= Generate Random Vehicle Entity Id + ${second_temporal_entity_representation_id}= Generate Random Vehicle Entity Id ${response}= Create Temporal Representation Of Entity ... ${first_vehicle_payload_file} ... ${first_temporal_entity_representation_id} diff --git a/TP/NGSI-LD/ContextInformation/Consumption/TemporalEntity/QueryTemporalEvolutionOfEntities/021_17.robot b/TP/NGSI-LD/ContextInformation/Consumption/TemporalEntity/QueryTemporalEvolutionOfEntities/021_17.robot index 0dab1467abfc0ca88f616f5c5448c8b294f1ef26..dec15ac875d985afb748d29829f17af8e633a3c3 100644 --- a/TP/NGSI-LD/ContextInformation/Consumption/TemporalEntity/QueryTemporalEvolutionOfEntities/021_17.robot +++ b/TP/NGSI-LD/ContextInformation/Consumption/TemporalEntity/QueryTemporalEvolutionOfEntities/021_17.robot @@ -1,6 +1,7 @@ *** Settings *** Documentation Check that one can retrieve the temporal evolution of entities with the aggregated temporal representation +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/TemporalContextInformationConsumption.resource Resource ${EXECDIR}/resources/ApiUtils/TemporalContextInformationProvision.resource Resource ${EXECDIR}/resources/AssertionUtils.resource @@ -12,7 +13,6 @@ Test Template Retrieve the temporal evolution of entities with the aggrega *** Variables *** -${vehicle_id_prefix}= urn:ngsi-ld:Vehicle: ${first_vehicle_payload_file}= 2020-08-vehicle-temporal-representation.jsonld ${second_vehicle_payload_file}= 2020-08-vehicle-temporal-representation.jsonld @@ -56,7 +56,7 @@ Retrieve the temporal evolution of entities with the aggregated temporal represe ... ${response.json()[0]} Setup Initial Entities - ${first_temporal_entity_representation_id}= Generate Random Entity Id ${vehicle_id_prefix} + ${first_temporal_entity_representation_id}= Generate Random Vehicle Entity Id ${response}= Create Temporal Representation Of Entity ... ${first_vehicle_payload_file} ... ${first_temporal_entity_representation_id} diff --git a/TP/NGSI-LD/ContextInformation/Consumption/TemporalEntity/RetrieveTemporalEvolutionOfEntity/020_01.robot b/TP/NGSI-LD/ContextInformation/Consumption/TemporalEntity/RetrieveTemporalEvolutionOfEntity/020_01.robot index 5df3b954ec7bceddd349f9eb4e19e191f4ab082c..2431f0fd2ee8f7cc93238ec8617a7a16646c79c2 100644 --- a/TP/NGSI-LD/ContextInformation/Consumption/TemporalEntity/RetrieveTemporalEvolutionOfEntity/020_01.robot +++ b/TP/NGSI-LD/ContextInformation/Consumption/TemporalEntity/RetrieveTemporalEvolutionOfEntity/020_01.robot @@ -1,6 +1,7 @@ *** Settings *** Documentation Check that one can retrieve the temporal evolution of an entity +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/TemporalContextInformationConsumption.resource Resource ${EXECDIR}/resources/ApiUtils/TemporalContextInformationProvision.resource Resource ${EXECDIR}/resources/AssertionUtils.resource @@ -11,7 +12,6 @@ Suite Teardown Delete Initial Temporal Entity *** Variables *** -${vehicle_id_prefix}= urn:ngsi-ld:Vehicle: ${vehicle_payload_file}= 2020-08-vehicle-temporal-representation.jsonld ${vehicle_expectation_file}= vehicle-temporal-representation-020-01.jsonld @@ -31,7 +31,7 @@ ${vehicle_expectation_file}= vehicle-temporal-representation-020-01.jsonld *** Keywords *** Create Temporal Entity - ${temporal_entity_representation_id}= Generate Random Entity Id ${vehicle_id_prefix} + ${temporal_entity_representation_id}= Generate Random Vehicle Entity Id ${create_response}= Create Temporal Representation Of Entity ... ${vehicle_payload_file} ... ${temporal_entity_representation_id} diff --git a/TP/NGSI-LD/ContextInformation/Consumption/TemporalEntity/RetrieveTemporalEvolutionOfEntity/020_02.robot b/TP/NGSI-LD/ContextInformation/Consumption/TemporalEntity/RetrieveTemporalEvolutionOfEntity/020_02.robot index 5dcdd8612485f3dd92bd878dbcb5eb4bc05b66f1..ce97fe166f2f5444d3202c5afd41f389961a56b0 100644 --- a/TP/NGSI-LD/ContextInformation/Consumption/TemporalEntity/RetrieveTemporalEvolutionOfEntity/020_02.robot +++ b/TP/NGSI-LD/ContextInformation/Consumption/TemporalEntity/RetrieveTemporalEvolutionOfEntity/020_02.robot @@ -1,6 +1,7 @@ *** Settings *** Documentation Check that one can retrieve the temporal evolution of an entity using a context +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/TemporalContextInformationConsumption.resource Resource ${EXECDIR}/resources/ApiUtils/TemporalContextInformationProvision.resource Resource ${EXECDIR}/resources/AssertionUtils.resource @@ -11,7 +12,6 @@ Suite Teardown Delete Initial Temporal Entity *** Variables *** -${vehicle_id_prefix}= urn:ngsi-ld:Vehicle: ${vehicle_payload_file}= 2020-08-vehicle-temporal-representation.jsonld ${vehicle_expectation_file}= vehicle-temporal-representation-020-02.jsonld @@ -32,7 +32,7 @@ ${vehicle_expectation_file}= vehicle-temporal-representation-020-02.jsonld *** Keywords *** Create Temporal Entity - ${temporal_entity_representation_id}= Generate Random Entity Id ${vehicle_id_prefix} + ${temporal_entity_representation_id}= Generate Random Vehicle Entity Id ${create_response}= Create Temporal Representation Of Entity ... ${vehicle_payload_file} ... ${temporal_entity_representation_id} diff --git a/TP/NGSI-LD/ContextInformation/Consumption/TemporalEntity/RetrieveTemporalEvolutionOfEntity/020_03.robot b/TP/NGSI-LD/ContextInformation/Consumption/TemporalEntity/RetrieveTemporalEvolutionOfEntity/020_03.robot index 495b3ae475ad48a3f74de585d34bff1734b5e01c..910f13e7f3998cea9f27aec4b9355a6dc58c8219 100644 --- a/TP/NGSI-LD/ContextInformation/Consumption/TemporalEntity/RetrieveTemporalEvolutionOfEntity/020_03.robot +++ b/TP/NGSI-LD/ContextInformation/Consumption/TemporalEntity/RetrieveTemporalEvolutionOfEntity/020_03.robot @@ -1,6 +1,7 @@ *** Settings *** Documentation Check that one can retrieve the temporal evolution of certain attributes of an entity +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/TemporalContextInformationConsumption.resource Resource ${EXECDIR}/resources/ApiUtils/TemporalContextInformationProvision.resource Resource ${EXECDIR}/resources/AssertionUtils.resource @@ -12,7 +13,6 @@ Test Template Retrieve the temporal evolution of certain attributes of an *** Variables *** -${vehicle_id_prefix}= urn:ngsi-ld:Vehicle: ${vehicle_payload_file}= 2020-08-vehicle-temporal-representation.jsonld ${vehicle_expectation_file}= vehicle-temporal-representation-020-03.jsonld @@ -41,7 +41,7 @@ Retrieve the temporal evolution of certain attributes of an entity ... ${response.json()} Create Temporal Entity - ${temporal_entity_representation_id}= Generate Random Entity Id ${vehicle_id_prefix} + ${temporal_entity_representation_id}= Generate Random Vehicle Entity Id ${create_response}= Create Temporal Representation Of Entity ... ${vehicle_payload_file} ... ${temporal_entity_representation_id} diff --git a/TP/NGSI-LD/ContextInformation/Consumption/TemporalEntity/RetrieveTemporalEvolutionOfEntity/020_04.robot b/TP/NGSI-LD/ContextInformation/Consumption/TemporalEntity/RetrieveTemporalEvolutionOfEntity/020_04.robot index 07928f9928a6d750a603a206d469f32974364f3c..30abc24ccf25342b148caaf74274791dfec17be0 100644 --- a/TP/NGSI-LD/ContextInformation/Consumption/TemporalEntity/RetrieveTemporalEvolutionOfEntity/020_04.robot +++ b/TP/NGSI-LD/ContextInformation/Consumption/TemporalEntity/RetrieveTemporalEvolutionOfEntity/020_04.robot @@ -1,6 +1,7 @@ *** Settings *** Documentation Check that one can retrieve the temporal evolution of an entity matching the given NGSI-LD temporal query +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/TemporalContextInformationConsumption.resource Resource ${EXECDIR}/resources/ApiUtils/TemporalContextInformationProvision.resource Resource ${EXECDIR}/resources/AssertionUtils.resource @@ -12,7 +13,6 @@ Test Template Retrieve the temporal evolution of an entity matching the gi *** Variables *** -${vehicle_id_prefix}= urn:ngsi-ld:Vehicle: ${vehicle_payload_file}= 2020-08-vehicle-temporal-representation.jsonld @@ -45,7 +45,7 @@ Retrieve the temporal evolution of an entity matching the given NGSI-LD temporal ... ${response.json()} Create Temporal Entity - ${temporal_entity_representation_id}= Generate Random Entity Id ${vehicle_id_prefix} + ${temporal_entity_representation_id}= Generate Random Vehicle Entity Id ${create_response}= Create Temporal Representation Of Entity ... ${vehicle_payload_file} ... ${temporal_entity_representation_id} diff --git a/TP/NGSI-LD/ContextInformation/Consumption/TemporalEntity/RetrieveTemporalEvolutionOfEntity/020_05.robot b/TP/NGSI-LD/ContextInformation/Consumption/TemporalEntity/RetrieveTemporalEvolutionOfEntity/020_05.robot index 516b78d53761a7f483240e6663cfb58c132e0d12..78946919a6ab88505ea3931e62d161625eb3a289 100644 --- a/TP/NGSI-LD/ContextInformation/Consumption/TemporalEntity/RetrieveTemporalEvolutionOfEntity/020_05.robot +++ b/TP/NGSI-LD/ContextInformation/Consumption/TemporalEntity/RetrieveTemporalEvolutionOfEntity/020_05.robot @@ -1,6 +1,7 @@ *** Settings *** Documentation Check that one can retrieve the temporal evolution of the last N instances of entity attributes +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/TemporalContextInformationConsumption.resource Resource ${EXECDIR}/resources/ApiUtils/TemporalContextInformationProvision.resource Resource ${EXECDIR}/resources/AssertionUtils.resource @@ -12,7 +13,6 @@ Test Template Retrieve the temporal evolution of the last N instances of e *** Variables *** -${vehicle_id_prefix}= urn:ngsi-ld:Vehicle: ${vehicle_payload_file}= 2020-08-vehicle-temporal-representation-multiple-instances.jsonld @@ -40,7 +40,7 @@ Retrieve the temporal evolution of the last N instances of entity attributes ... ${response.json()} Create Temporal Entity - ${temporal_entity_representation_id}= Generate Random Entity Id ${vehicle_id_prefix} + ${temporal_entity_representation_id}= Generate Random Vehicle Entity Id ${create_response}= Create Temporal Representation Of Entity ... ${vehicle_payload_file} ... ${temporal_entity_representation_id} diff --git a/TP/NGSI-LD/ContextInformation/Consumption/TemporalEntity/RetrieveTemporalEvolutionOfEntity/020_08.robot b/TP/NGSI-LD/ContextInformation/Consumption/TemporalEntity/RetrieveTemporalEvolutionOfEntity/020_08.robot index 2e2d81671f147fd65f9435a9f5abd8a6de4bdf2f..3490fd60a7a2d7e283282f13b2ab746eb39113bf 100644 --- a/TP/NGSI-LD/ContextInformation/Consumption/TemporalEntity/RetrieveTemporalEvolutionOfEntity/020_08.robot +++ b/TP/NGSI-LD/ContextInformation/Consumption/TemporalEntity/RetrieveTemporalEvolutionOfEntity/020_08.robot @@ -1,6 +1,7 @@ *** Settings *** Documentation Check that one cannot retrieve the temporal evolution of non-existing entity attributes +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/TemporalContextInformationConsumption.resource Resource ${EXECDIR}/resources/ApiUtils/TemporalContextInformationProvision.resource Resource ${EXECDIR}/resources/AssertionUtils.resource @@ -11,7 +12,6 @@ Suite Teardown Delete Initial Temporal Entity *** Variables *** -${vehicle_id_prefix}= urn:ngsi-ld:Vehicle: ${vehicle_payload_file}= 2020-08-vehicle-temporal-representation.jsonld @@ -33,7 +33,7 @@ ${vehicle_payload_file}= 2020-08-vehicle-temporal-representation.jsonld *** Keywords *** Create Temporal Entity - ${temporal_entity_representation_id}= Generate Random Entity Id ${vehicle_id_prefix} + ${temporal_entity_representation_id}= Generate Random Vehicle Entity Id ${create_response}= Create Temporal Representation Of Entity ... ${vehicle_payload_file} ... ${temporal_entity_representation_id} diff --git a/TP/NGSI-LD/ContextInformation/Consumption/TemporalEntity/RetrieveTemporalEvolutionOfEntity/020_09.robot b/TP/NGSI-LD/ContextInformation/Consumption/TemporalEntity/RetrieveTemporalEvolutionOfEntity/020_09.robot index 90911bba7e40ccfc4a73121fc492fa14b01288fc..649efe987234797fb3ccd072dac10c2d9748c29d 100644 --- a/TP/NGSI-LD/ContextInformation/Consumption/TemporalEntity/RetrieveTemporalEvolutionOfEntity/020_09.robot +++ b/TP/NGSI-LD/ContextInformation/Consumption/TemporalEntity/RetrieveTemporalEvolutionOfEntity/020_09.robot @@ -1,6 +1,7 @@ *** Settings *** Documentation Check that one cannot retrieve the temporal evolution of an entity with an invalid request content +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/TemporalContextInformationConsumption.resource Resource ${EXECDIR}/resources/ApiUtils/TemporalContextInformationProvision.resource Resource ${EXECDIR}/resources/AssertionUtils.resource @@ -12,7 +13,6 @@ Test Template Retrieve the temporal evolution of an entity with an invalid *** Variables *** -${vehicle_id_prefix}= urn:ngsi-ld:Vehicle: ${vehicle_payload_file}= 2020-08-vehicle-temporal-representation.jsonld @@ -44,7 +44,7 @@ Retrieve the temporal evolution of an entity with an invalid request content Check Response Body Containing ProblemDetails Element Containing Title Element ${response.json()} Create Temporal Entity - ${temporal_entity_representation_id}= Generate Random Entity Id ${vehicle_id_prefix} + ${temporal_entity_representation_id}= Generate Random Vehicle Entity Id ${create_response}= Create Temporal Representation Of Entity ... ${vehicle_payload_file} ... ${temporal_entity_representation_id} diff --git a/TP/NGSI-LD/ContextInformation/Consumption/TemporalEntity/RetrieveTemporalEvolutionOfEntity/020_10.robot b/TP/NGSI-LD/ContextInformation/Consumption/TemporalEntity/RetrieveTemporalEvolutionOfEntity/020_10.robot index 08859d960234e4b6a30da2dccf495ae90bbd75b5..072501dac0d662dd1745e6a5b51c2d0bcd8939c6 100644 --- a/TP/NGSI-LD/ContextInformation/Consumption/TemporalEntity/RetrieveTemporalEvolutionOfEntity/020_10.robot +++ b/TP/NGSI-LD/ContextInformation/Consumption/TemporalEntity/RetrieveTemporalEvolutionOfEntity/020_10.robot @@ -1,6 +1,7 @@ *** Settings *** Documentation Check that one can retrieve the temporal evolution of an entity with the simplified temporal representation +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/TemporalContextInformationConsumption.resource Resource ${EXECDIR}/resources/ApiUtils/TemporalContextInformationProvision.resource Resource ${EXECDIR}/resources/AssertionUtils.resource @@ -11,7 +12,6 @@ Suite Teardown Delete Initial Temporal Entity *** Variables *** -${vehicle_id_prefix}= urn:ngsi-ld:Vehicle: ${vehicle_payload_file}= 2020-08-vehicle-temporal-representation.jsonld ${vehicle_expectation_file}= vehicle-temporal-representation-020-10.jsonld @@ -34,7 +34,7 @@ ${vehicle_expectation_file}= vehicle-temporal-representation-020-10.jsonld *** Keywords *** Create Temporal Entity - ${temporal_entity_representation_id}= Generate Random Entity Id ${vehicle_id_prefix} + ${temporal_entity_representation_id}= Generate Random Vehicle Entity Id ${create_response}= Create Temporal Representation Of Entity ... ${vehicle_payload_file} ... ${temporal_entity_representation_id} diff --git a/TP/NGSI-LD/ContextInformation/Consumption/TemporalEntity/RetrieveTemporalEvolutionOfEntity/020_11.robot b/TP/NGSI-LD/ContextInformation/Consumption/TemporalEntity/RetrieveTemporalEvolutionOfEntity/020_11.robot index d8ef43b4e865c0c47eef48814c724189167d66af..b8d40404945778c2f3b8a8f43a47e1b1a041cd5c 100644 --- a/TP/NGSI-LD/ContextInformation/Consumption/TemporalEntity/RetrieveTemporalEvolutionOfEntity/020_11.robot +++ b/TP/NGSI-LD/ContextInformation/Consumption/TemporalEntity/RetrieveTemporalEvolutionOfEntity/020_11.robot @@ -1,6 +1,7 @@ *** Settings *** Documentation Check that one can retrieve the temporal evolution of an entity with the aggregated temporal representation +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/TemporalContextInformationConsumption.resource Resource ${EXECDIR}/resources/ApiUtils/TemporalContextInformationProvision.resource Resource ${EXECDIR}/resources/AssertionUtils.resource @@ -12,7 +13,6 @@ Test Template Retrieve the temporal evolution of an entity with the aggreg *** Variables *** -${vehicle_id_prefix}= urn:ngsi-ld:Vehicle: ${vehicle_payload_file}= 2020-08-vehicle-temporal-representation.jsonld @@ -50,7 +50,7 @@ Retrieve the temporal evolution of an entity with the aggregated temporal repres ... ${response.json()} Create Temporal Entity - ${temporal_entity_representation_id}= Generate Random Entity Id ${vehicle_id_prefix} + ${temporal_entity_representation_id}= Generate Random Vehicle Entity Id ${create_response}= Create Temporal Representation Of Entity ... ${vehicle_payload_file} ... ${temporal_entity_representation_id} diff --git a/TP/NGSI-LD/ContextInformation/Consumption/TemporalEntity/RetrieveTemporalEvolutionOfEntity/020_12.robot b/TP/NGSI-LD/ContextInformation/Consumption/TemporalEntity/RetrieveTemporalEvolutionOfEntity/020_12.robot index a01ba13b95fb0b376aafd41e8e39de83f64f07e0..c145bb5654b46ed102fda5545b44801e232ae7dc 100644 --- a/TP/NGSI-LD/ContextInformation/Consumption/TemporalEntity/RetrieveTemporalEvolutionOfEntity/020_12.robot +++ b/TP/NGSI-LD/ContextInformation/Consumption/TemporalEntity/RetrieveTemporalEvolutionOfEntity/020_12.robot @@ -1,6 +1,7 @@ *** Settings *** Documentation Check that one can retrieve the temporal evolution of an entity with a LanguageProperty property +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/TemporalContextInformationConsumption.resource Resource ${EXECDIR}/resources/ApiUtils/TemporalContextInformationProvision.resource Resource ${EXECDIR}/resources/AssertionUtils.resource @@ -12,7 +13,6 @@ Test Template Retrieve Temporal Entity *** Variables *** -${vehicle_id_prefix}= urn:ngsi-ld:Vehicle: ${vehicle_payload_file}= vehicle-language-property-temporal-representation.jsonld @@ -40,7 +40,7 @@ Retrieve Temporal Entity ... ${response.json()} Create Temporal Entity - ${temporal_entity_representation_id}= Generate Random Entity Id ${vehicle_id_prefix} + ${temporal_entity_representation_id}= Generate Random Vehicle Entity Id ${create_response}= Create Temporal Representation Of Entity ... ${vehicle_payload_file} ... ${temporal_entity_representation_id} diff --git a/TP/NGSI-LD/ContextInformation/Consumption/TemporalEntity/RetrieveTemporalEvolutionOfEntity/020_13.robot b/TP/NGSI-LD/ContextInformation/Consumption/TemporalEntity/RetrieveTemporalEvolutionOfEntity/020_13.robot index b2778c882f245f9f8083e5b9db44b7d03aab5701..88931a495197e55ec86b73cc2688dbe51070dd2f 100644 --- a/TP/NGSI-LD/ContextInformation/Consumption/TemporalEntity/RetrieveTemporalEvolutionOfEntity/020_13.robot +++ b/TP/NGSI-LD/ContextInformation/Consumption/TemporalEntity/RetrieveTemporalEvolutionOfEntity/020_13.robot @@ -1,6 +1,7 @@ *** Settings *** Documentation Check temporal pagination is applied when retrieving the temporal evolution of an entity +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/TemporalContextInformationConsumption.resource Resource ${EXECDIR}/resources/ApiUtils/TemporalContextInformationProvision.resource Resource ${EXECDIR}/resources/AssertionUtils.resource @@ -12,7 +13,6 @@ Test Template Retrieve Temporal Entity *** Variables *** -${vehicule_id_prefix}= urn:ngsi-ld:Vehicle: ${vehicle_payload_file}= pagination/2020-01-vehicule-temporal-representation-twenty-instances.jsonld ${timeBefore}= 2019-01-01T01:01:00Z ${timeAfter}= 2021-01-01T01:01:00Z @@ -120,7 +120,7 @@ Retrieve Temporal Entity END Create Temporal Entity - ${temporal_entity_representation_id}= Generate Random Entity Id ${vehicule_id_prefix} + ${temporal_entity_representation_id}= Generate Random Vehicle Entity Id ${response}= Create Temporal Representation Of Entity ... ${vehicle_payload_file} ... ${temporal_entity_representation_id} diff --git a/TP/NGSI-LD/ContextInformation/Consumption/TemporalEntity/RetrieveTemporalEvolutionOfEntity/020_14.robot b/TP/NGSI-LD/ContextInformation/Consumption/TemporalEntity/RetrieveTemporalEvolutionOfEntity/020_14.robot index 157e3479ea65286a0627cc148af190f2097f521b..5933f0af552cba09eefcb4726bb33cb1853fb77a 100644 --- a/TP/NGSI-LD/ContextInformation/Consumption/TemporalEntity/RetrieveTemporalEvolutionOfEntity/020_14.robot +++ b/TP/NGSI-LD/ContextInformation/Consumption/TemporalEntity/RetrieveTemporalEvolutionOfEntity/020_14.robot @@ -1,6 +1,7 @@ *** Settings *** Documentation Check that the time range cut before the second attribute to avoid missing data in content-range +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/TemporalContextInformationConsumption.resource Resource ${EXECDIR}/resources/ApiUtils/TemporalContextInformationProvision.resource Resource ${EXECDIR}/resources/AssertionUtils.resource @@ -12,7 +13,6 @@ Test Template Retrieve Temporal Entity *** Variables *** -${vehicule_id_prefix}= urn:ngsi-ld:Vehicle: ${vehicle_payload_file}= pagination/2020-01-vehicule-temporal-representation-sixty-instances.jsonld ${timeBefore}= 2019-01-01T01:01:00Z ${timeAfter}= 2021-01-01T01:01:00Z @@ -44,7 +44,7 @@ Retrieve Temporal Entity Check Data Is Empty ${response.json()}[${emptyAttr}] Create Temporal Entity - ${temporal_entity_representation_id}= Generate Random Entity Id ${vehicule_id_prefix} + ${temporal_entity_representation_id}= Generate Random Vehicle Entity Id ${response}= Create Temporal Representation Of Entity ... ${vehicle_payload_file} ... ${temporal_entity_representation_id} diff --git a/TP/NGSI-LD/ContextInformation/Consumption/TemporalEntity/RetrieveTemporalEvolutionOfEntity/020_17.robot b/TP/NGSI-LD/ContextInformation/Consumption/TemporalEntity/RetrieveTemporalEvolutionOfEntity/020_17.robot index cf3a12ae67dc8b5e1b533694c953c544278509fb..7846ed1ed28186e51eec1c71179a7f1acc38048f 100644 --- a/TP/NGSI-LD/ContextInformation/Consumption/TemporalEntity/RetrieveTemporalEvolutionOfEntity/020_17.robot +++ b/TP/NGSI-LD/ContextInformation/Consumption/TemporalEntity/RetrieveTemporalEvolutionOfEntity/020_17.robot @@ -1,9 +1,10 @@ *** Settings *** Documentation Check that one can retrieve the temporal evolution of an entity following the deletedAt temporal property +Resource ${EXECDIR}/resources/ApiUtils/Common.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource Resource ${EXECDIR}/resources/ApiUtils/TemporalContextInformationConsumption.resource Resource ${EXECDIR}/resources/ApiUtils/TemporalContextInformationProvision.resource -Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -13,7 +14,6 @@ Test Template Delete Temporal Attribute and Retrieve Temporal Evolution of *** Variables *** -${vehicle_id_prefix}= urn:ngsi-ld:Vehicle: ${vehicle_payload_file}= vehicle-temporal-representation-different-attributes-types.jsonld @@ -55,7 +55,7 @@ Delete Temporal Attribute and Retrieve Temporal Evolution of Attribute ... json_path=['${attr_name}']['deletedAt'] Create Temporal Entity - ${temporal_entity_representation_id}= Generate Random Entity Id ${vehicle_id_prefix} + ${temporal_entity_representation_id}= Generate Random Vehicle Entity Id ${create_response}= Create Temporal Representation Of Entity ... ${vehicle_payload_file} ... ${temporal_entity_representation_id} diff --git a/TP/NGSI-LD/ContextInformation/Consumption/TemporalEntity/RetrieveTemporalEvolutionOfEntity/020_18.robot b/TP/NGSI-LD/ContextInformation/Consumption/TemporalEntity/RetrieveTemporalEvolutionOfEntity/020_18.robot index 71ad4dc79a570c1e95aec4cd6c3e1ef706032445..c7e76c992af75d20fba8dfc7fd86c8567cf1c653 100644 --- a/TP/NGSI-LD/ContextInformation/Consumption/TemporalEntity/RetrieveTemporalEvolutionOfEntity/020_18.robot +++ b/TP/NGSI-LD/ContextInformation/Consumption/TemporalEntity/RetrieveTemporalEvolutionOfEntity/020_18.robot @@ -1,9 +1,10 @@ *** Settings *** Documentation Check that one can retrieve the temporal evolution of an entity following the deletedAt temporal property with temporal values +Resource ${EXECDIR}/resources/ApiUtils/Common.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource Resource ${EXECDIR}/resources/ApiUtils/TemporalContextInformationConsumption.resource Resource ${EXECDIR}/resources/ApiUtils/TemporalContextInformationProvision.resource -Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -13,7 +14,6 @@ Test Template Delete Temporal Attribute and Retrieve Temporal Evolution of *** Variables *** -${vehicle_id_prefix}= urn:ngsi-ld:Vehicle: ${vehicle_payload_file}= vehicle-temporal-representation-different-attributes-types.jsonld @@ -58,7 +58,7 @@ Delete Temporal Attribute and Retrieve Temporal Evolution of Attribute ... json_path=['${attr_name}']['${simplified_temporal_key}'][0][1] Create Temporal Entity - ${temporal_entity_representation_id}= Generate Random Entity Id ${vehicle_id_prefix} + ${temporal_entity_representation_id}= Generate Random Vehicle Entity Id ${create_response}= Create Temporal Representation Of Entity ... ${vehicle_payload_file} ... ${temporal_entity_representation_id} diff --git a/TP/NGSI-LD/ContextInformation/Consumption/TemporalEntity/RetrieveTemporalEvolutionOfEntity/020_19.robot b/TP/NGSI-LD/ContextInformation/Consumption/TemporalEntity/RetrieveTemporalEvolutionOfEntity/020_19.robot index ce06dcfc4e52c51e455a0a492e94c3512f46bbad..e46d0c9b49a2be9702a1a6f2698d934084efc5c3 100644 --- a/TP/NGSI-LD/ContextInformation/Consumption/TemporalEntity/RetrieveTemporalEvolutionOfEntity/020_19.robot +++ b/TP/NGSI-LD/ContextInformation/Consumption/TemporalEntity/RetrieveTemporalEvolutionOfEntity/020_19.robot @@ -1,9 +1,10 @@ *** Settings *** Documentation Check that one can retrieve the temporal evolution of a scope following the deletedAt temporal property +Resource ${EXECDIR}/resources/ApiUtils/Common.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource Resource ${EXECDIR}/resources/ApiUtils/TemporalContextInformationConsumption.resource Resource ${EXECDIR}/resources/ApiUtils/TemporalContextInformationProvision.resource -Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -13,7 +14,6 @@ Test Template Delete Temporal Attribute and Retrieve Temporal Evolution of *** Variables *** -${vehicle_id_prefix}= urn:ngsi-ld:Vehicle: ${vehicle_payload_file}= vehicle-temporal-representation-scope.jsonld @@ -49,7 +49,7 @@ Delete Temporal Attribute and Retrieve Temporal Evolution of Attribute ... json_path=['scope']['deletedAt'] Create Temporal Entity - ${temporal_entity_representation_id}= Generate Random Entity Id ${vehicle_id_prefix} + ${temporal_entity_representation_id}= Generate Random Vehicle Entity Id ${create_response}= Create Temporal Representation Of Entity ... ${vehicle_payload_file} ... ${temporal_entity_representation_id} diff --git a/TP/NGSI-LD/ContextInformation/Consumption/TemporalEntity/RetrieveTemporalEvolutionOfEntity/020_20.robot b/TP/NGSI-LD/ContextInformation/Consumption/TemporalEntity/RetrieveTemporalEvolutionOfEntity/020_20.robot index 5ecf2beb410e23cb187157276430363cf0b3c84f..584fa6775a8019a92fabdef79d07c0557d5af6f6 100644 --- a/TP/NGSI-LD/ContextInformation/Consumption/TemporalEntity/RetrieveTemporalEvolutionOfEntity/020_20.robot +++ b/TP/NGSI-LD/ContextInformation/Consumption/TemporalEntity/RetrieveTemporalEvolutionOfEntity/020_20.robot @@ -1,9 +1,10 @@ *** Settings *** Documentation Check that one can retrieve the temporal evolution of a scope following the deletedAt temporal property with temporal values +Resource ${EXECDIR}/resources/ApiUtils/Common.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource Resource ${EXECDIR}/resources/ApiUtils/TemporalContextInformationConsumption.resource Resource ${EXECDIR}/resources/ApiUtils/TemporalContextInformationProvision.resource -Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -13,7 +14,6 @@ Test Template Delete Temporal Attribute and Retrieve Temporal Evolution of *** Variables *** -${vehicle_id_prefix}= urn:ngsi-ld:Vehicle: ${vehicle_payload_file}= vehicle-temporal-representation-scope.jsonld @@ -50,7 +50,7 @@ Delete Temporal Attribute and Retrieve Temporal Evolution of Attribute ... json_path=['scope']['values'][0][1] Create Temporal Entity - ${temporal_entity_representation_id}= Generate Random Entity Id ${vehicle_id_prefix} + ${temporal_entity_representation_id}= Generate Random Vehicle Entity Id ${create_response}= Create Temporal Representation Of Entity ... ${vehicle_payload_file} ... ${temporal_entity_representation_id} diff --git a/TP/NGSI-LD/ContextInformation/Provision/BatchEntities/CreateBatchOfEntities/003_01.robot b/TP/NGSI-LD/ContextInformation/Provision/BatchEntities/CreateBatchOfEntities/003_01.robot index d722c601fc68126dc70347d1ba7c8326b9149b98..f5f6ec55848b6dd72dde7ea4bcde4c7f87000061 100644 --- a/TP/NGSI-LD/ContextInformation/Provision/BatchEntities/CreateBatchOfEntities/003_01.robot +++ b/TP/NGSI-LD/ContextInformation/Provision/BatchEntities/CreateBatchOfEntities/003_01.robot @@ -1,8 +1,9 @@ *** Settings *** Documentation Check that one can create a batch of entities -Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationConsumption.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -10,10 +11,6 @@ Test Teardown Delete Initial Entities Test Template Batch Create Entity Scenarios -*** Variables *** -${building_id_prefix}= urn:ngsi-ld:Building: - - *** Test Cases *** FILENAME 003_01_01 MinimalEntity [Tags] be-create 5_6_7 @@ -33,8 +30,8 @@ ${building_id_prefix}= urn:ngsi-ld:Building: Batch Create Entity Scenarios [Documentation] Check that one can create a batch of entities [Arguments] ${filename} - ${first_entity_id}= Generate Random Entity Id ${building_id_prefix} - ${second_entity_id}= Generate Random Entity Id ${building_id_prefix} + ${first_entity_id}= Generate Random Building Entity Id + ${second_entity_id}= Generate Random Building Entity Id ${first_entity}= Load Entity ${filename} ${first_entity_id} ${second_entity}= Load Entity ${filename} ${second_entity_id} @{entities_to_be_created}= Create List ${first_entity} ${second_entity} diff --git a/TP/NGSI-LD/ContextInformation/Provision/BatchEntities/CreateBatchOfEntities/003_02.robot b/TP/NGSI-LD/ContextInformation/Provision/BatchEntities/CreateBatchOfEntities/003_02.robot index 5c7af583a104df39917e47a17999492729df03f3..d3fdb20b8173711ddd8fb3ece654d83b21908d68 100644 --- a/TP/NGSI-LD/ContextInformation/Provision/BatchEntities/CreateBatchOfEntities/003_02.robot +++ b/TP/NGSI-LD/ContextInformation/Provision/BatchEntities/CreateBatchOfEntities/003_02.robot @@ -1,8 +1,9 @@ *** Settings *** Documentation Check that one can create a batch of entities where some will succeed and others will fail -Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationConsumption.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -10,17 +11,13 @@ Suite Setup Setup Initial Entity Suite Teardown Delete Initial Entities -*** Variables *** -${building_id_prefix}= urn:ngsi-ld:Building: - - *** Test Cases *** 003_02_01 Create a batch of two valid entities and one invalid entity [Documentation] Check that one can create a batch of two valid entities and one invalid entity [Tags] be-create 5_6_7 - ${first_entity_id}= Generate Random Entity Id ${building_id_prefix} + ${first_entity_id}= Generate Random Building Entity Id Set Suite Variable ${first_entity_id} - ${second_entity_id}= Generate Random Entity Id ${building_id_prefix} + ${second_entity_id}= Generate Random Building Entity Id Set Suite Variable ${second_entity_id} # TODO: Use Load Test Sample keyword instead ${first_entity}= Load Entity building-minimal.jsonld ${first_entity_id} @@ -50,7 +47,7 @@ ${building_id_prefix}= urn:ngsi-ld:Building: *** Keywords *** Setup Initial Entity - ${existing_entity_id}= Generate Random Entity Id ${building_id_prefix} + ${existing_entity_id}= Generate Random Building Entity Id ${create_response}= Create Entity building-minimal.jsonld ${existing_entity_id} Check Response Status Code 201 ${create_response.status_code} Set Suite Variable ${existing_entity_id} diff --git a/TP/NGSI-LD/ContextInformation/Provision/BatchEntities/CreateBatchOfEntities/003_04.robot b/TP/NGSI-LD/ContextInformation/Provision/BatchEntities/CreateBatchOfEntities/003_04.robot index f8a786ccff1025e89ed313a39b7ea839ad746f91..ddaca8e8280bf97911c53eb39d132a5ec3ccee52 100644 --- a/TP/NGSI-LD/ContextInformation/Provision/BatchEntities/CreateBatchOfEntities/003_04.robot +++ b/TP/NGSI-LD/ContextInformation/Provision/BatchEntities/CreateBatchOfEntities/003_04.robot @@ -1,24 +1,21 @@ *** Settings *** Documentation Check that the @context is obtained from a Link Header if the Content-Type header is "application/json" -Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationConsumption.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource Test Teardown Delete Initial Entities -*** Variables *** -${building_id_prefix}= urn:ngsi-ld:Building: - - *** Test Cases *** 003_04_01 Create a batch of one entity using a provided Link header with JSON content type and retrieve the entity with context detail [Documentation] Check that the @context is obtained from a Link Header if the Content-Type header is "application/json" [Tags] be-create 6_3_5 - ${entity_id}= Generate Random Entity Id ${building_id_prefix} + ${entity_id}= Generate Random Building Entity Id Set Test Variable ${entity_id} ${entity}= Load Entity building-simple-attributes.json ${entity_id} @{entities_to_be_created}= Create List ${entity} @@ -41,7 +38,7 @@ ${building_id_prefix}= urn:ngsi-ld:Building: [Documentation] Check that the @context is obtained from a Link Header if the Content-Type header is "application/json" [Tags] be-create 6_3_5 - ${entity_id}= Generate Random Entity Id ${building_id_prefix} + ${entity_id}= Generate Random Building Entity Id Set Test Variable ${entity_id} ${entity}= Load Entity building-simple-attributes.json ${entity_id} @{entities_to_be_created}= Create List ${entity} diff --git a/TP/NGSI-LD/ContextInformation/Provision/BatchEntities/CreateBatchOfEntities/003_05.robot b/TP/NGSI-LD/ContextInformation/Provision/BatchEntities/CreateBatchOfEntities/003_05.robot index d2b017bddf1e56fa8e500f9166e39b58e04407fc..890bbfc896726e00ea9b905e4a36ddd14c3ce743 100644 --- a/TP/NGSI-LD/ContextInformation/Provision/BatchEntities/CreateBatchOfEntities/003_05.robot +++ b/TP/NGSI-LD/ContextInformation/Provision/BatchEntities/CreateBatchOfEntities/003_05.robot @@ -1,24 +1,21 @@ *** Settings *** Documentation Check that the default @context is used if the Content-Type header is "application/json" and the Link header does not contain a JSON-LD @context -Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationConsumption.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource Test Teardown Delete Initial Entities -*** Variables *** -${building_id_prefix}= urn:ngsi-ld:Building: - - *** Test Cases *** 003_05_01 Create a batch of one entity using the default context with JSON content type [Documentation] Check that the default @context is used if the Content-Type header is "application/json" and the Link header does not contain a JSON-LD @context and retrieve the entity without context [Tags] be-create 6_3_5 - ${entity_id}= Generate Random Entity Id ${building_id_prefix} + ${entity_id}= Generate Random Building Entity Id Set Test Variable ${entity_id} ${entity}= Load Entity building-simple-attributes.json ${entity_id} @{entities_to_be_created}= Create List ${entity} @@ -36,7 +33,7 @@ ${building_id_prefix}= urn:ngsi-ld:Building: [Documentation] Check that the default @context is used if the Content-Type header is "application/json" and the Link header does not contain a JSON-LD @context and retrieve the entity with context [Tags] be-create 6_3_5 - ${entity_id}= Generate Random Entity Id ${building_id_prefix} + ${entity_id}= Generate Random Building Entity Id Set Test Variable ${entity_id} ${entity}= Load Entity building-simple-attributes.json ${entity_id} @{entities_to_be_created}= Create List ${entity} diff --git a/TP/NGSI-LD/ContextInformation/Provision/BatchEntities/CreateBatchOfEntities/003_06.robot b/TP/NGSI-LD/ContextInformation/Provision/BatchEntities/CreateBatchOfEntities/003_06.robot index 01f9b6b20501dbc348e8185f0eb08a5084861726..e39f3e325c66a0a346dc0a24e301083027e0f295 100644 --- a/TP/NGSI-LD/ContextInformation/Provision/BatchEntities/CreateBatchOfEntities/003_06.robot +++ b/TP/NGSI-LD/ContextInformation/Provision/BatchEntities/CreateBatchOfEntities/003_06.robot @@ -1,20 +1,17 @@ *** Settings *** Documentation Check that an HTTP error response of type BadRequestData is raised if the Content-Type header is "application/json" and the request payload body (as JSON) contains a "@context" term +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource -*** Variables *** -${building_id_prefix}= urn:ngsi-ld:Building: - - *** Test Cases *** 003_06_01 Create a batch of one entity containing a JSON-LD @context with a JSON content type [Documentation] Check that an HTTP error response of type BadRequestData is raised if the Content-Type header is "application/json" and the request payload body (as JSON) contains a "@context" term [Tags] be-create 6_3_5 - ${entity_id}= Generate Random Entity Id ${building_id_prefix} + ${entity_id}= Generate Random Building Entity Id ${entity}= Load Entity building-simple-attributes.jsonld ${entity_id} @{entities_to_be_created}= Create List ${entity} diff --git a/TP/NGSI-LD/ContextInformation/Provision/BatchEntities/CreateBatchOfEntities/003_07.robot b/TP/NGSI-LD/ContextInformation/Provision/BatchEntities/CreateBatchOfEntities/003_07.robot index 7b2ead68490b3d4475e4caebf96975bf8202cdf6..271c35c7eb99f3fc5d8363d89434638601c9aac2 100644 --- a/TP/NGSI-LD/ContextInformation/Provision/BatchEntities/CreateBatchOfEntities/003_07.robot +++ b/TP/NGSI-LD/ContextInformation/Provision/BatchEntities/CreateBatchOfEntities/003_07.robot @@ -1,23 +1,20 @@ *** Settings *** Documentation Check that the @context is obtained from the request payload body itself if the Content-Type header is "application/ld+json" -Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationConsumption.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource Test Teardown Delete Initial Entities -*** Variables *** -${building_id_prefix}= urn:ngsi-ld:Building: - - *** Test Cases *** 003_07_01 Create a batch of one entity using a JSON-LD @context obtained from the request payload [Documentation] Check that the @context is obtained from the request payload body itself if the Content-Type header is "application/ld+json" and the response attribute should be compacted as one used the same context as provided when creating the entity [Tags] be-create 6_3_5 - ${entity_id}= Generate Random Entity Id ${building_id_prefix} + ${entity_id}= Generate Random Building Entity Id Set Test Variable ${entity_id} ${entity}= Load Entity building-simple-attributes.jsonld ${entity_id} @{entities_to_be_created}= Create List ${entity} @@ -36,7 +33,7 @@ ${building_id_prefix}= urn:ngsi-ld:Building: 003_07_02 Create a batch of one entity using a JSON-LD @context obtained from the request payload [Documentation] Check that the @context is obtained from the request payload body itself if the Content-Type header is "application/ld+json" and response attribute should not be compacted as one did not provide a context containing this term [Tags] be-create 6_3_5 - ${entity_id}= Generate Random Entity Id ${building_id_prefix} + ${entity_id}= Generate Random Building Entity Id Set Test Variable ${entity_id} ${entity}= Load Entity building-simple-attributes.jsonld ${entity_id} @{entities_to_be_created}= Create List ${entity} diff --git a/TP/NGSI-LD/ContextInformation/Provision/BatchEntities/CreateBatchOfEntities/003_08.robot b/TP/NGSI-LD/ContextInformation/Provision/BatchEntities/CreateBatchOfEntities/003_08.robot index dd61c873392ca4202807f214feb3f61e440f98fa..d446685218349aad9f71b5819777457f1885e5f4 100644 --- a/TP/NGSI-LD/ContextInformation/Provision/BatchEntities/CreateBatchOfEntities/003_08.robot +++ b/TP/NGSI-LD/ContextInformation/Provision/BatchEntities/CreateBatchOfEntities/003_08.robot @@ -1,20 +1,17 @@ *** Settings *** Documentation Check that an HTTP error response of type BadRequestData is raised if the Content-Type header is "application/ld+json" and the request payload body does not contain a @context term +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource -*** Variables *** -${building_id_prefix}= urn:ngsi-ld:Building: - - *** Test Cases *** 003_08_01 Create a batch of one entity not containing a JSON-LD @context with a JSON-LD content type [Documentation] Check that an HTTP error response of type BadRequestData is raised if the Content-Type header is "application/ld+json" and the request payload body does not contain a @context term [Tags] be-create 6_3_5 - ${entity_id}= Generate Random Entity Id ${building_id_prefix} + ${entity_id}= Generate Random Building Entity Id ${entity}= Load Entity building-simple-attributes.json ${entity_id} @{entities_to_be_created}= Create List ${entity} diff --git a/TP/NGSI-LD/ContextInformation/Provision/BatchEntities/CreateBatchOfEntities/003_09.robot b/TP/NGSI-LD/ContextInformation/Provision/BatchEntities/CreateBatchOfEntities/003_09.robot index d5b90bee53f867d74c5d53d6679ee59efe08373a..367c912e02fca2ada0ad55af00876f9f3fcb2540 100644 --- a/TP/NGSI-LD/ContextInformation/Provision/BatchEntities/CreateBatchOfEntities/003_09.robot +++ b/TP/NGSI-LD/ContextInformation/Provision/BatchEntities/CreateBatchOfEntities/003_09.robot @@ -1,20 +1,17 @@ *** Settings *** Documentation Check that an HTTP error response of type BadRequestData is raised if the Content-Type header is "application/ld+json" and a JSON-LD Link header is present in the incoming HTTP request +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource -*** Variables *** -${building_id_prefix}= urn:ngsi-ld:Building: - - *** Test Cases *** 003_09_01 Create a batch of one entity with a Link header and a JSON-LD content type [Documentation] Check that an HTTP error response of type BadRequestData is raised if the Content-Type header is "application/ld+json" and a JSON-LD Link header is present in the incoming HTTP request [Tags] be-create 6_3_5 - ${entity_id}= Generate Random Entity Id ${building_id_prefix} + ${entity_id}= Generate Random Building Entity Id ${entity}= Load Entity building-simple-attributes.jsonld ${entity_id} @{entities_to_be_created}= Create List ${entity} diff --git a/TP/NGSI-LD/ContextInformation/Provision/BatchEntities/CreateBatchOfEntities/003_10.robot b/TP/NGSI-LD/ContextInformation/Provision/BatchEntities/CreateBatchOfEntities/003_10.robot index c89a23c5c1b4c0989cce3f62ae3db48c452a5c0d..73672e6b11f297136048267bd459cda09334a667 100644 --- a/TP/NGSI-LD/ContextInformation/Provision/BatchEntities/CreateBatchOfEntities/003_10.robot +++ b/TP/NGSI-LD/ContextInformation/Provision/BatchEntities/CreateBatchOfEntities/003_10.robot @@ -1,25 +1,22 @@ *** Settings *** Documentation Check that one can create a batch of entities where two have the same id -Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationConsumption.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource Test Teardown Delete Entities -*** Variables *** -${building_id_prefix}= urn:ngsi-ld:Building: - - *** Test Cases *** 003_10_01 Create a batch of three valid entities where two have the same id [Documentation] Check that one can create a batch of entities where two have the same id [Tags] be-create 5_6_7 5_5_11 since_v1.5.1 - ${first_entity_id}= Generate Random Entity Id ${building_id_prefix} + ${first_entity_id}= Generate Random Building Entity Id Set Suite Variable ${first_entity_id} - ${second_entity_id}= Generate Random Entity Id ${building_id_prefix} + ${second_entity_id}= Generate Random Building Entity Id Set Suite Variable ${second_entity_id} ${first_entity}= Load Entity building-minimal.jsonld ${first_entity_id} ${second_entity}= Load Entity building-minimal.jsonld ${second_entity_id} diff --git a/TP/NGSI-LD/ContextInformation/Provision/BatchEntities/DeleteBatchOfEntities/006_01.robot b/TP/NGSI-LD/ContextInformation/Provision/BatchEntities/DeleteBatchOfEntities/006_01.robot index c469c99f1039010259be9f4793df9879f0fa5571..888c551eaab4c0bcb829f8dd131681aee98bc8e8 100644 --- a/TP/NGSI-LD/ContextInformation/Provision/BatchEntities/DeleteBatchOfEntities/006_01.robot +++ b/TP/NGSI-LD/ContextInformation/Provision/BatchEntities/DeleteBatchOfEntities/006_01.robot @@ -1,18 +1,15 @@ *** Settings *** Documentation Check that one can delete a batch of entities -Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationConsumption.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource Test Setup Setup Initial Entities -*** Variables *** -${building_id_prefix}= urn:ngsi-ld:Building: - - *** Test Cases *** 006_01_01 Delete a batch of entities [Documentation] Check that one can delete a batch of entities @@ -30,10 +27,10 @@ ${building_id_prefix}= urn:ngsi-ld:Building: *** Keywords *** Setup Initial Entities - ${first_entity_id}= Generate Random Entity Id ${building_id_prefix} + ${first_entity_id}= Generate Random Building Entity Id ${create_response1}= Create Entity building-simple-attributes.jsonld ${first_entity_id} Check Response Status Code 201 ${create_response1.status_code} - ${second_entity_id}= Generate Random Entity Id ${building_id_prefix} + ${second_entity_id}= Generate Random Building Entity Id ${create_response2}= Create Entity building-simple-attributes.jsonld ${second_entity_id} Check Response Status Code 201 ${create_response2.status_code} @{entities_ids_to_be_deleted}= Create List ${first_entity_id} ${second_entity_id} diff --git a/TP/NGSI-LD/ContextInformation/Provision/BatchEntities/DeleteBatchOfEntities/006_02.robot b/TP/NGSI-LD/ContextInformation/Provision/BatchEntities/DeleteBatchOfEntities/006_02.robot index 0e6ebc0874fe39607bc76e0af84021af1f766263..4d44089eda586cc27b94e0ca3ae8b47583fdee1d 100644 --- a/TP/NGSI-LD/ContextInformation/Provision/BatchEntities/DeleteBatchOfEntities/006_02.robot +++ b/TP/NGSI-LD/ContextInformation/Provision/BatchEntities/DeleteBatchOfEntities/006_02.robot @@ -1,23 +1,20 @@ *** Settings *** Documentation Check that one can delete a batch of entities where some will succeed and others will fail -Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationConsumption.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource Test Setup Setup Initial Entity -*** Variables *** -${building_id_prefix}= urn:ngsi-ld:Building: - - *** Test Cases *** 006_02_01 Delete a batch of non-existing and existing entities [Documentation] Check that one can delete a batch of non-existing and existing entities [Tags] be-delete 5_6_10 - ${new_entity_id}= Generate Random Entity Id ${building_id_prefix} + ${new_entity_id}= Generate Random Building Entity Id @{entities_ids_to_be_deleted}= Create List ${existing_entity_id} ${new_entity_id} ${response}= Batch Delete Entities entities_ids_to_be_deleted=@{entities_ids_to_be_deleted} @@ -43,7 +40,7 @@ ${building_id_prefix}= urn:ngsi-ld:Building: *** Keywords *** Setup Initial Entity - ${existing_entity_id}= Generate Random Entity Id ${building_id_prefix} + ${existing_entity_id}= Generate Random Building Entity Id ${create_response}= Create Entity building-simple-attributes.jsonld ${existing_entity_id} Check Response Status Code 201 ${create_response.status_code} Set Test Variable ${existing_entity_id} diff --git a/TP/NGSI-LD/ContextInformation/Provision/BatchEntities/DeleteBatchOfEntities/006_04.robot b/TP/NGSI-LD/ContextInformation/Provision/BatchEntities/DeleteBatchOfEntities/006_04.robot index 84ccd589485621b36354b6ef932403770f59f57e..76077be6b89f18b87dfba1a3edab0116102ae672 100644 --- a/TP/NGSI-LD/ContextInformation/Provision/BatchEntities/DeleteBatchOfEntities/006_04.robot +++ b/TP/NGSI-LD/ContextInformation/Provision/BatchEntities/DeleteBatchOfEntities/006_04.robot @@ -1,23 +1,20 @@ *** Settings *** Documentation Check that one can delete a batch of entities with the same id -Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationConsumption.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource Test Setup Setup Initial Entity -*** Variables *** -${building_id_prefix}= urn:ngsi-ld:Building: - - *** Test Cases *** 006_04_01 Delete a batch of existing entities with the same id [Documentation] Check that one can delete a batch entities with the same id [Tags] be-delete 5_6_10 5_5_11 since_v1.5.1 - ${new_entity_id}= Generate Random Entity Id ${building_id_prefix} + ${new_entity_id}= Generate Random Building Entity Id @{entities_ids_to_be_deleted}= Create List ${entity_id} ${entity_id} ${response}= Batch Delete Entities entities_ids_to_be_deleted=@{entities_ids_to_be_deleted} @@ -33,7 +30,7 @@ ${building_id_prefix}= urn:ngsi-ld:Building: *** Keywords *** Setup Initial Entity - ${entity_id}= Generate Random Entity Id ${building_id_prefix} + ${entity_id}= Generate Random Building Entity Id ${create_response}= Create Entity building-simple-attributes.jsonld ${entity_id} Check Response Status Code 201 ${create_response.status_code} Set Test Variable ${entity_id} diff --git a/TP/NGSI-LD/ContextInformation/Provision/BatchEntities/MergeBatchOfEntities/057_01.robot b/TP/NGSI-LD/ContextInformation/Provision/BatchEntities/MergeBatchOfEntities/057_01.robot index 39acd703339d4ceed1ce161604168ef5142122eb..92c61496582cd2a2d86fa109159e3916d8000ecd 100644 --- a/TP/NGSI-LD/ContextInformation/Provision/BatchEntities/MergeBatchOfEntities/057_01.robot +++ b/TP/NGSI-LD/ContextInformation/Provision/BatchEntities/MergeBatchOfEntities/057_01.robot @@ -1,8 +1,9 @@ *** Settings *** Documentation Check that you can merge a batch of entities -Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationConsumption.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -12,7 +13,6 @@ Test Template Batch Merge Entity Scenarios *** Variables *** -${building_id_prefix}= urn:ngsi-ld:Building: ${entity_payload_filename}= merge/building-merge-data.jsonld @@ -55,8 +55,8 @@ Batch Merge Entity Scenarios ... ignore_core_context_version=${True} Setup Initial Entities - ${first_entity_id}= Generate Random Entity Id ${building_id_prefix} - ${second_entity_id}= Generate Random Entity Id ${building_id_prefix} + ${first_entity_id}= Generate Random Building Entity Id + ${second_entity_id}= Generate Random Building Entity Id Create Entity ${entity_payload_filename} ${first_entity_id} Create Entity ${entity_payload_filename} ${second_entity_id} Set Test Variable ${first_entity_id} diff --git a/TP/NGSI-LD/ContextInformation/Provision/BatchEntities/MergeBatchOfEntities/057_02.robot b/TP/NGSI-LD/ContextInformation/Provision/BatchEntities/MergeBatchOfEntities/057_02.robot index 8461c53942fda8807dc5ffb6f37895176b144430..2c6656eaea87371cf3149fbaf73ac72a81a06cd7 100644 --- a/TP/NGSI-LD/ContextInformation/Provision/BatchEntities/MergeBatchOfEntities/057_02.robot +++ b/TP/NGSI-LD/ContextInformation/Provision/BatchEntities/MergeBatchOfEntities/057_02.robot @@ -1,8 +1,9 @@ *** Settings *** Documentation Check that you can merge a batch of entities where some will succeed and others will fail -Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationConsumption.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -11,7 +12,6 @@ Suite Teardown Delete Initial Entities *** Variables *** -${building_id_prefix}= urn:ngsi-ld:Building: ${entity_payload_filename}= building-simple-attributes.jsonld ${merge_fragment_filename}= fragmentEntities/simple-attributes-relationship-of-property-fragment.json ${entity_filename}= building-relationship-of-property.jsonld @@ -27,7 +27,7 @@ ${entity_filename}= building-relationship-of-property.jsonld ${second_existing_entity}= Load Entity ... ${entity_filename} ... ${second_existing_entity_id} - ${new_entity_id}= Generate Random Entity Id ${building_id_prefix} + ${new_entity_id}= Generate Random Building Entity Id ${new_entity}= Load Entity ${entity_filename} ${new_entity_id} @{entities_to_be_merged}= Create List ${first_existing_entity} ${second_existing_entity} ${new_entity} @@ -61,8 +61,8 @@ ${entity_filename}= building-relationship-of-property.jsonld *** Keywords *** Setup Initial Entities - ${first_existing_entity_id}= Generate Random Entity Id ${building_id_prefix} - ${second_existing_entity_id}= Generate Random Entity Id ${building_id_prefix} + ${first_existing_entity_id}= Generate Random Building Entity Id + ${second_existing_entity_id}= Generate Random Building Entity Id Create Entity ${entity_payload_filename} ${first_existing_entity_id} Create Entity ${entity_payload_filename} ${second_existing_entity_id} Set Suite Variable ${first_existing_entity_id} diff --git a/TP/NGSI-LD/ContextInformation/Provision/BatchEntities/UpdateBatchOfEntities/005_01.robot b/TP/NGSI-LD/ContextInformation/Provision/BatchEntities/UpdateBatchOfEntities/005_01.robot index f02488a883458acf077566ef793935c688abedca..550d5405ae8a652560a33896017613900e2de5b5 100644 --- a/TP/NGSI-LD/ContextInformation/Provision/BatchEntities/UpdateBatchOfEntities/005_01.robot +++ b/TP/NGSI-LD/ContextInformation/Provision/BatchEntities/UpdateBatchOfEntities/005_01.robot @@ -1,8 +1,9 @@ *** Settings *** Documentation Check that one can update a batch of entities -Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationConsumption.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -12,7 +13,6 @@ Test Template Batch Update Entity Scenarios *** Variables *** -${building_id_prefix}= urn:ngsi-ld:Building: ${entity_payload_filename}= building-simple-attributes.jsonld @@ -55,11 +55,11 @@ Batch Update Entity Scenarios Check Updated Resources Set To ${updated_entities} ${response1.json()} Setup Initial Entities - ${first_entity_id}= Generate Random Entity Id ${building_id_prefix} + ${first_entity_id}= Generate Random Building Entity Id ${create_response1}= Create Entity ${entity_payload_filename} ${first_entity_id} Check Response Status Code 201 ${create_response1.status_code} Set Test Variable ${first_entity_id} - ${second_entity_id}= Generate Random Entity Id ${building_id_prefix} + ${second_entity_id}= Generate Random Building Entity Id ${create_response2}= Create Entity ${entity_payload_filename} ${second_entity_id} Check Response Status Code 201 ${create_response2.status_code} Set Test Variable ${second_entity_id} diff --git a/TP/NGSI-LD/ContextInformation/Provision/BatchEntities/UpdateBatchOfEntities/005_02.robot b/TP/NGSI-LD/ContextInformation/Provision/BatchEntities/UpdateBatchOfEntities/005_02.robot index c580c5c1e240855b0b2183f7816860651e9dbe2b..90861f5bc4e2ac99ea3349c2de8b9cc30f51cbc4 100644 --- a/TP/NGSI-LD/ContextInformation/Provision/BatchEntities/UpdateBatchOfEntities/005_02.robot +++ b/TP/NGSI-LD/ContextInformation/Provision/BatchEntities/UpdateBatchOfEntities/005_02.robot @@ -1,8 +1,9 @@ *** Settings *** Documentation Check that one can update a batch of entities with noOverwrite option -Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationConsumption.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -12,7 +13,6 @@ Test Template Batch Update Entity With NoOverwrite Option Scenarios *** Variables *** -${building_id_prefix}= urn:ngsi-ld:Building: ${entity_payload_filename}= building-simple-attributes.jsonld @@ -55,11 +55,11 @@ Batch Update Entity With NoOverwrite Option Scenarios Check Updated Resources Set To ${updated_entities} ${response1.json()} Setup Initial Entities - ${first_entity_id}= Generate Random Entity Id ${building_id_prefix} + ${first_entity_id}= Generate Random Building Entity Id ${create_response1}= Create Entity ${entity_payload_filename} ${first_entity_id} Check Response Status Code 201 ${create_response1.status_code} Set Test Variable ${first_entity_id} - ${second_entity_id}= Generate Random Entity Id ${building_id_prefix} + ${second_entity_id}= Generate Random Building Entity Id ${create_response2}= Create Entity ${entity_payload_filename} ${second_entity_id} Check Response Status Code 201 ${create_response2.status_code} Set Test Variable ${second_entity_id} diff --git a/TP/NGSI-LD/ContextInformation/Provision/BatchEntities/UpdateBatchOfEntities/005_03.robot b/TP/NGSI-LD/ContextInformation/Provision/BatchEntities/UpdateBatchOfEntities/005_03.robot index ea069a314282094f1fa3115c5a9551c664bb8f59..814867ab4981b395332f47bfc11d983c92d8e269 100644 --- a/TP/NGSI-LD/ContextInformation/Provision/BatchEntities/UpdateBatchOfEntities/005_03.robot +++ b/TP/NGSI-LD/ContextInformation/Provision/BatchEntities/UpdateBatchOfEntities/005_03.robot @@ -1,8 +1,9 @@ *** Settings *** Documentation Check that one can update a batch of entities where some will succeed and others will fail -Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationConsumption.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -11,7 +12,6 @@ Suite Teardown Delete Initial Entities *** Variables *** -${building_id_prefix}= urn:ngsi-ld:Building: ${entity_payload_filename}= building-simple-attributes.jsonld ${update_fragment_filename}= fragmentEntities/simple-attributes-relationship-of-property-fragment.json @@ -26,7 +26,7 @@ ${update_fragment_filename}= fragmentEntities/simple-attributes-relationship- ${second_existing_entity}= Load Entity ... building-relationship-of-property.jsonld ... ${second_existing_entity_id} - ${new_entity_id}= Generate Random Entity Id ${building_id_prefix} + ${new_entity_id}= Generate Random Building Entity Id ${new_entity}= Load Entity building-relationship-of-property.jsonld ${new_entity_id} @{entities_to_be_updated}= Create List ${first_existing_entity} ${second_existing_entity} ${new_entity} @@ -61,11 +61,11 @@ ${update_fragment_filename}= fragmentEntities/simple-attributes-relationship- *** Keywords *** Setup Initial Entities - ${first_existing_entity_id}= Generate Random Entity Id ${building_id_prefix} + ${first_existing_entity_id}= Generate Random Building Entity Id ${create_response1}= Create Entity ${entity_payload_filename} ${first_existing_entity_id} Check Response Status Code 201 ${create_response1.status_code} Set Suite Variable ${first_existing_entity_id} - ${second_existing_entity_id}= Generate Random Entity Id ${building_id_prefix} + ${second_existing_entity_id}= Generate Random Building Entity Id ${create_response2}= Create Entity ${entity_payload_filename} ${second_existing_entity_id} Check Response Status Code 201 ${create_response2.status_code} Set Suite Variable ${second_existing_entity_id} diff --git a/TP/NGSI-LD/ContextInformation/Provision/BatchEntities/UpdateBatchOfEntities/005_05.robot b/TP/NGSI-LD/ContextInformation/Provision/BatchEntities/UpdateBatchOfEntities/005_05.robot index f8cbb19711803dd374c25fa703a20ad11a0a6ec4..b9c2645b68cf217e917fd7267c544a5dc9406230 100644 --- a/TP/NGSI-LD/ContextInformation/Provision/BatchEntities/UpdateBatchOfEntities/005_05.robot +++ b/TP/NGSI-LD/ContextInformation/Provision/BatchEntities/UpdateBatchOfEntities/005_05.robot @@ -1,8 +1,9 @@ *** Settings *** Documentation Check that you can update types of entities in a batch update operation -Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationConsumption.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -12,7 +13,6 @@ Test Template Batch Update Entity Scenarios *** Variables *** -${building_id_prefix}= urn:ngsi-ld:Building: ${entity_payload_filename}= building-minimal.jsonld @@ -47,8 +47,8 @@ Batch Update Entity Scenarios Check Updated Resources Set To ${updated_entities} ${response1.json()} Setup Initial Entities - ${first_entity_id}= Generate Random Entity Id ${building_id_prefix} - ${second_entity_id}= Generate Random Entity Id ${building_id_prefix} + ${first_entity_id}= Generate Random Building Entity Id + ${second_entity_id}= Generate Random Building Entity Id Create Entity ${entity_payload_filename} ${first_entity_id} Create Entity ${entity_payload_filename} ${second_entity_id} Set Test Variable ${first_entity_id} diff --git a/TP/NGSI-LD/ContextInformation/Provision/BatchEntities/UpsertBatchOfEntities/004_01.robot b/TP/NGSI-LD/ContextInformation/Provision/BatchEntities/UpsertBatchOfEntities/004_01.robot index 4a38b317b6636228a0c2146a0e05ea45f7042ea5..572b9bfbe575e1b27822900c1d5d174464f98859 100644 --- a/TP/NGSI-LD/ContextInformation/Provision/BatchEntities/UpsertBatchOfEntities/004_01.robot +++ b/TP/NGSI-LD/ContextInformation/Provision/BatchEntities/UpsertBatchOfEntities/004_01.robot @@ -1,8 +1,9 @@ *** Settings *** Documentation Check that one can upsert a batch of non-existing entities and they will be created -Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationConsumption.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -10,10 +11,6 @@ Test Teardown Delete Initial Entities Test Template Batch Upsert Entity Scenarios -*** Variables *** -${building_id_prefix}= urn:ngsi-ld:Building: - - *** Test Cases *** FILENAME 004_01_01 EntityWithSimpleProperties [Tags] be-upsert 5_6_8 @@ -30,8 +27,8 @@ ${building_id_prefix}= urn:ngsi-ld:Building: Batch Upsert Entity Scenarios [Documentation] Check that one can upsert a batch of non-existing entities [Arguments] ${filename} - ${first_entity_id}= Generate Random Entity Id ${building_id_prefix} - ${second_entity_id}= Generate Random Entity Id ${building_id_prefix} + ${first_entity_id}= Generate Random Building Entity Id + ${second_entity_id}= Generate Random Building Entity Id ${first_entity}= Load Entity ${filename} ${first_entity_id} ${second_entity}= Load Entity ${filename} ${second_entity_id} @{entities_to_be_upserted}= Create List ${first_entity} ${second_entity} diff --git a/TP/NGSI-LD/ContextInformation/Provision/BatchEntities/UpsertBatchOfEntities/004_02.robot b/TP/NGSI-LD/ContextInformation/Provision/BatchEntities/UpsertBatchOfEntities/004_02.robot index 7212be861b00dfea82cc576df4c4f7bc8c65f9ba..1a33fb631c62eddbde4f26dac36b188abc8e400a 100644 --- a/TP/NGSI-LD/ContextInformation/Provision/BatchEntities/UpsertBatchOfEntities/004_02.robot +++ b/TP/NGSI-LD/ContextInformation/Provision/BatchEntities/UpsertBatchOfEntities/004_02.robot @@ -1,8 +1,9 @@ *** Settings *** Documentation Check that one can upsert a batch of non-existing and existing entities where non-existing will be created and existing will be replaced -Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationConsumption.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -10,10 +11,6 @@ Test Teardown Delete Initial Entities Test Template Batch Upsert Non-existing And Existing Entities Scenarios -*** Variables *** -${building_id_prefix}= urn:ngsi-ld:Building: - - *** Test Cases *** FILENAME 004_02_01 EntityWithSimpleProperties [Tags] be-upsert 5_6_8 @@ -51,13 +48,13 @@ Batch Upsert Non-existing And Existing Entities Scenarios Prepare Entities To Upsert [Arguments] ${filename} - ${first_existing_entity_id}= Generate Random Entity Id ${building_id_prefix} - ${second_existing_entity_id}= Generate Random Entity Id ${building_id_prefix} + ${first_existing_entity_id}= Generate Random Building Entity Id + ${second_existing_entity_id}= Generate Random Building Entity Id Create Entity building-minimal.jsonld ${first_existing_entity_id} Create Entity building-minimal.jsonld ${second_existing_entity_id} Set Test Variable ${first_existing_entity_id} Set Test Variable ${second_existing_entity_id} - ${new_entity_id}= Generate Random Entity Id ${building_id_prefix} + ${new_entity_id}= Generate Random Building Entity Id Set Test Variable ${new_entity_id} ${new_entity}= Load Entity ${filename} ${new_entity_id} ${first_existing_entity}= Load Entity ${filename} ${first_existing_entity_id} diff --git a/TP/NGSI-LD/ContextInformation/Provision/BatchEntities/UpsertBatchOfEntities/004_03.robot b/TP/NGSI-LD/ContextInformation/Provision/BatchEntities/UpsertBatchOfEntities/004_03.robot index ac887633f4bc80f6700e802582ef30358249e894..dcd2612f183f415f40cf1c0996ccd2ff537f01e6 100644 --- a/TP/NGSI-LD/ContextInformation/Provision/BatchEntities/UpsertBatchOfEntities/004_03.robot +++ b/TP/NGSI-LD/ContextInformation/Provision/BatchEntities/UpsertBatchOfEntities/004_03.robot @@ -1,8 +1,9 @@ *** Settings *** Documentation Check that one can upsert a batch of existing entities and they will be replaced -Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationConsumption.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -11,10 +12,6 @@ Test Teardown Delete Initial Entities Test Template Batch Upsert Existing Entities Scenarios -*** Variables *** -${building_id_prefix}= urn:ngsi-ld:Building: - - *** Test Cases *** FILENAME 004_03_01 EntityWithSimpleProperties [Tags] be-upsert 5_6_8 @@ -54,11 +51,11 @@ Batch Upsert Existing Entities Scenarios Check Updated Resources Set To ${entities_to_be_upserted} ${response1.json()} Setup Initial Entities - ${first_existing_entity_id}= Generate Random Entity Id ${building_id_prefix} + ${first_existing_entity_id}= Generate Random Building Entity Id ${create_response1}= Create Entity building-minimal.jsonld ${first_existing_entity_id} Check Response Status Code 201 ${create_response1.status_code} Set Test Variable ${first_existing_entity_id} - ${second_existing_entity_id}= Generate Random Entity Id ${building_id_prefix} + ${second_existing_entity_id}= Generate Random Building Entity Id ${create_response2}= Create Entity building-minimal.jsonld ${second_existing_entity_id} Check Response Status Code 201 ${create_response2.status_code} Set Test Variable ${second_existing_entity_id} diff --git a/TP/NGSI-LD/ContextInformation/Provision/BatchEntities/UpsertBatchOfEntities/004_04.robot b/TP/NGSI-LD/ContextInformation/Provision/BatchEntities/UpsertBatchOfEntities/004_04.robot index 6ed310ed19bdf2427a12fc92e2afbbfe55fc7642..1270a13348fa1a98dff776b165c5bfe5a51544e4 100644 --- a/TP/NGSI-LD/ContextInformation/Provision/BatchEntities/UpsertBatchOfEntities/004_04.robot +++ b/TP/NGSI-LD/ContextInformation/Provision/BatchEntities/UpsertBatchOfEntities/004_04.robot @@ -1,8 +1,9 @@ *** Settings *** Documentation Check that one can upsert a batch of entities with update option -Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationConsumption.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -12,7 +13,6 @@ Test Template Batch Upsert Entities With Update Option Scenarios *** Variables *** -${building_id_prefix}= urn:ngsi-ld:Building: ${existing_entity_payload_filename}= building-minimal.jsonld @@ -32,7 +32,7 @@ ${existing_entity_payload_filename}= building-minimal.jsonld Batch Upsert Entities With Update Option Scenarios [Documentation] Check that one can upsert a batch of entities with update option [Arguments] ${filename} ${update_fragment_filename} - ${new_entity_id}= Generate Random Entity Id ${building_id_prefix} + ${new_entity_id}= Generate Random Building Entity Id Set Test Variable ${new_entity_id} ${new_entity}= Load Entity ${filename} ${new_entity_id} ${existing_entity}= Load Entity ${filename} ${existing_entity_id} @@ -57,7 +57,7 @@ Batch Upsert Entities With Update Option Scenarios Check Updated Resources Set To ${updated_entities} ${response1.json()} Setup Initial Entity - ${existing_entity_id}= Generate Random Entity Id ${building_id_prefix} + ${existing_entity_id}= Generate Random Building Entity Id ${create_response}= Create Entity ${existing_entity_payload_filename} ${existing_entity_id} Check Response Status Code 201 ${create_response.status_code} Set Test Variable ${existing_entity_id} diff --git a/TP/NGSI-LD/ContextInformation/Provision/BatchEntities/UpsertBatchOfEntities/004_05.robot b/TP/NGSI-LD/ContextInformation/Provision/BatchEntities/UpsertBatchOfEntities/004_05.robot index c96f5de87c34d806734d8c4719f01041c74bd677..f3a7833caae5f574b4f1fb5720c0b5841e0e685d 100644 --- a/TP/NGSI-LD/ContextInformation/Provision/BatchEntities/UpsertBatchOfEntities/004_05.robot +++ b/TP/NGSI-LD/ContextInformation/Provision/BatchEntities/UpsertBatchOfEntities/004_05.robot @@ -1,29 +1,27 @@ *** Settings *** Documentation Check that one can upsert a batch of entities where some will succeed and others will fail -Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationConsumption.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource Test Teardown Delete Entities -*** Variables *** -${building_id_prefix}= urn:ngsi-ld:Building: - - *** Test Cases *** 004_05_01 Upsert a batch of two valid entities and one invalid entity [Documentation] Check that one can upsert a batch of two valid entities and one invalid entity [Tags] be-upsert 5_6_8 - ${first_entity_id}= Generate Random Entity Id ${building_id_prefix} - ${second_entity_id}= Generate Random Entity Id ${building_id_prefix} - ${third_entity_id}= Generate Random Entity Id ${building_id_prefix} + ${first_entity_id}= Generate Random Building Entity Id + ${second_entity_id}= Generate Random Building Entity Id + ${third_entity_id}= Generate Random Building Entity Id ${first_entity}= Load Entity building-minimal.jsonld ${first_entity_id} ${second_entity}= Load Entity building-minimal.jsonld ${second_entity_id} ${third_entity}= Load Entity building-minimal.jsonld ${third_entity_id} - ${invalid_entity}= Remove Entity Type ${third_entity} + ${invalid_entity}= Delete Object From JSON ${third_entity} $.type + @{entities_to_be_upserted}= Create List ${first_entity} ${second_entity} ${invalid_entity} ${response}= Batch Upsert Entities @{entities_to_be_upserted} diff --git a/TP/NGSI-LD/ContextInformation/Provision/BatchEntities/UpsertBatchOfEntities/004_07.robot b/TP/NGSI-LD/ContextInformation/Provision/BatchEntities/UpsertBatchOfEntities/004_07.robot index 05c933f17b0d1652b9ad8b04c931c466cbfeaf87..0717f7abffcbd29c216e6e442865c0cc92d711b2 100644 --- a/TP/NGSI-LD/ContextInformation/Provision/BatchEntities/UpsertBatchOfEntities/004_07.robot +++ b/TP/NGSI-LD/ContextInformation/Provision/BatchEntities/UpsertBatchOfEntities/004_07.robot @@ -1,24 +1,21 @@ *** Settings *** Documentation Check that one can upsert a batch of entities where two have the same id -Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationConsumption.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource Test Teardown Delete Entities -*** Variables *** -${building_id_prefix}= urn:ngsi-ld:Building: - - *** Test Cases *** 004_07_01 Upsert a batch of three valid entities where two have the same id [Documentation] Check that one can upsert a batch of where two have the same id [Tags] be-upsert 5_6_8 5_5_11 since_v1.5.1 - ${first_entity_id}= Generate Random Entity Id ${building_id_prefix} - ${second_entity_id}= Generate Random Entity Id ${building_id_prefix} + ${first_entity_id}= Generate Random Building Entity Id + ${second_entity_id}= Generate Random Building Entity Id ${first_entity}= Load Entity building-minimal.jsonld ${first_entity_id} ${second_entity}= Load Entity building-minimal.jsonld ${second_entity_id} @{entities_to_be_upserted}= Create List ${first_entity} ${second_entity} ${first_entity} diff --git a/TP/NGSI-LD/ContextInformation/Provision/BatchEntities/UpsertBatchOfEntities/004_08.robot b/TP/NGSI-LD/ContextInformation/Provision/BatchEntities/UpsertBatchOfEntities/004_08.robot index 6e30947da90803e2ac687a8556123d2033886a42..e3ce82b15f95f5aa2d885a378fecfe1d24197d5b 100644 --- a/TP/NGSI-LD/ContextInformation/Provision/BatchEntities/UpsertBatchOfEntities/004_08.robot +++ b/TP/NGSI-LD/ContextInformation/Provision/BatchEntities/UpsertBatchOfEntities/004_08.robot @@ -1,8 +1,9 @@ *** Settings *** Documentation Check that you can upsert a batch of existing entities with new types and they will be replaced -Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationConsumption.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -11,10 +12,6 @@ Test Teardown Delete Initial Entities Test Template Batch Upsert Existing Entities Scenarios -*** Variables *** -${building_id_prefix}= urn:ngsi-ld:Building: - - *** Test Cases *** FILENAME 004_08_01 EntityWithNewTypes [Tags] be-upsert 5_6_8 4_16 @@ -40,8 +37,8 @@ Batch Upsert Existing Entities Scenarios Check Updated Resources Set To ${entities_to_be_upserted} ${response1.json()} Setup Initial Entities - ${first_existing_entity_id}= Generate Random Entity Id ${building_id_prefix} - ${second_existing_entity_id}= Generate Random Entity Id ${building_id_prefix} + ${first_existing_entity_id}= Generate Random Building Entity Id + ${second_existing_entity_id}= Generate Random Building Entity Id Create Entity building-minimal.jsonld ${first_existing_entity_id} Create Entity building-minimal.jsonld ${second_existing_entity_id} Set Test Variable ${first_existing_entity_id} diff --git a/TP/NGSI-LD/ContextInformation/Provision/Entities/CreateEntity/001_01.robot b/TP/NGSI-LD/ContextInformation/Provision/Entities/CreateEntity/001_01.robot index 9418ed7bf3929944c88a93ffb8d4dffff247d3d4..860b9445c7c7cdcbd93f80e3ce3840bb99ffc0ca 100644 --- a/TP/NGSI-LD/ContextInformation/Provision/Entities/CreateEntity/001_01.robot +++ b/TP/NGSI-LD/ContextInformation/Provision/Entities/CreateEntity/001_01.robot @@ -1,8 +1,9 @@ *** Settings *** Documentation Check that one can create an entity -Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationConsumption.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -10,10 +11,6 @@ Test Teardown Delete Initial Entity Test Template Create Entity Scenarios -*** Variables *** -${building_id_prefix}= urn:ngsi-ld:Building: - - *** Test Cases *** FILENAME CONTENT_TYPE 001_01_01 MinimalEntity [Tags] e-create 5_6_1 @@ -36,7 +33,7 @@ ${building_id_prefix}= urn:ngsi-ld:Building: Create Entity Scenarios [Documentation] Check that one can create an entity [Arguments] ${filename} ${content_type} - ${entity_id}= Generate Random Entity Id ${building_id_prefix} + ${entity_id}= Generate Random Building Entity Id Set Test Variable ${entity_id} ${response}= Create Entity Selecting Content Type ... ${filename} diff --git a/TP/NGSI-LD/ContextInformation/Provision/Entities/CreateEntity/001_03.robot b/TP/NGSI-LD/ContextInformation/Provision/Entities/CreateEntity/001_03.robot index 2c1d7e14ca32bee15c295296307fb2f683d6bbf2..539d78fee876d717cee4e8fac9bcaa2606f960ce 100644 --- a/TP/NGSI-LD/ContextInformation/Provision/Entities/CreateEntity/001_03.robot +++ b/TP/NGSI-LD/ContextInformation/Provision/Entities/CreateEntity/001_03.robot @@ -1,6 +1,7 @@ *** Settings *** Documentation Check that one cannot create an entity with an existing id +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -10,9 +11,8 @@ Suite Teardown Delete Initial Entity *** Variables *** -${building_id_prefix}= urn:ngsi-ld:Building: -${filename}= building-minimal.jsonld -${content_type}= application/ld+json +${filename}= building-minimal.jsonld +${content_type}= application/ld+json *** Test Cases *** @@ -33,7 +33,7 @@ ${content_type}= application/ld+json *** Keywords *** Setup Initial Entity - ${entity_id}= Generate Random Entity Id ${building_id_prefix} + ${entity_id}= Generate Random Building Entity Id Set Suite Variable ${entity_id} ${create_response}= Create Entity Selecting Content Type ... ${filename} diff --git a/TP/NGSI-LD/ContextInformation/Provision/Entities/CreateEntity/001_04.robot b/TP/NGSI-LD/ContextInformation/Provision/Entities/CreateEntity/001_04.robot index 58f228c67484d79061f293e5867f5029943d2d67..8f1d3f779e06491874cb441bb68e5750baaaae1b 100644 --- a/TP/NGSI-LD/ContextInformation/Provision/Entities/CreateEntity/001_04.robot +++ b/TP/NGSI-LD/ContextInformation/Provision/Entities/CreateEntity/001_04.robot @@ -1,8 +1,9 @@ *** Settings *** Documentation Check that the @context is obtained from a Link Header if the Content-Type header is "application/json" -Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationConsumption.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -10,15 +11,14 @@ Test Teardown Delete Initial Entity *** Variables *** -${building_id_prefix}= urn:ngsi-ld:Building: -${filename}= building-simple-attributes.json +${filename}= building-simple-attributes.json *** Test Cases *** 001_04_01 Create one entity using a provided Link header with JSON content type and NGSILD context [Documentation] Check that the @context is obtained from a Link Header if the Content-Type header is "application/json" [Tags] e-create 6_3_5 - ${entity_id}= Generate Random Entity Id ${building_id_prefix} + ${entity_id}= Generate Random Building Entity Id Set Suite Variable ${entity_id} ${response}= Create Entity Selecting Content Type ... ${filename} @@ -34,7 +34,7 @@ ${filename}= building-simple-attributes.json 001_04_02 Create one entity using a provided Link header with JSON content type and no context [Documentation] Check that the @context is obtained from a Link Header if the Content-Type header is "application/json" [Tags] e-create 6_3_5 - ${entity_id}= Generate Random Entity Id ${building_id_prefix} + ${entity_id}= Generate Random Building Entity Id Set Suite Variable ${entity_id} ${response}= Create Entity Selecting Content Type ... ${filename} diff --git a/TP/NGSI-LD/ContextInformation/Provision/Entities/CreateEntity/001_05.robot b/TP/NGSI-LD/ContextInformation/Provision/Entities/CreateEntity/001_05.robot index 4fcab0c452656f67595cc5e64ee04f47d3341a0c..e2e780c288e9736f9bc1ded39db86e0834f2c8d2 100644 --- a/TP/NGSI-LD/ContextInformation/Provision/Entities/CreateEntity/001_05.robot +++ b/TP/NGSI-LD/ContextInformation/Provision/Entities/CreateEntity/001_05.robot @@ -1,8 +1,9 @@ *** Settings *** Documentation Check that the default @context is used if the Content-Type header is "application/json" and the Link header does not contain a JSON-LD @context -Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationConsumption.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -10,15 +11,14 @@ Test Teardown Delete Initial Entity *** Variables *** -${building_id_prefix}= urn:ngsi-ld:Building: -${filename}= building-simple-attributes.json +${filename}= building-simple-attributes.json *** Test Cases *** 001_05_01 Create one entity using the default context with JSON content type and request without context [Documentation] Check that the default @context is used if the Content-Type header is "application/json" and the Link header does not contain a JSON-LD @context, requesting without context [Tags] e-create 6_3_5 - ${entity_id}= Generate Random Entity Id ${building_id_prefix} + ${entity_id}= Generate Random Building Entity Id Set Suite Variable ${entity_id} ${response}= Create Entity Selecting Content Type ${filename} ${entity_id} ${CONTENT_TYPE_JSON} ${response1}= Retrieve Entity by Id id=${entity_id} @@ -30,7 +30,7 @@ ${filename}= building-simple-attributes.json 001_05_02 Create one entity using the default context with JSON content type and request with context [Documentation] Check that the default @context is used if the Content-Type header is "application/json" and the Link header does not contain a JSON-LD @context, requesting with context [Tags] e-create 6_3_5 - ${entity_id}= Generate Random Entity Id ${building_id_prefix} + ${entity_id}= Generate Random Building Entity Id Set Suite Variable ${entity_id} ${response}= Create Entity Selecting Content Type ${filename} ${entity_id} ${CONTENT_TYPE_JSON} ${response1}= Retrieve Entity by Id diff --git a/TP/NGSI-LD/ContextInformation/Provision/Entities/CreateEntity/001_06.robot b/TP/NGSI-LD/ContextInformation/Provision/Entities/CreateEntity/001_06.robot index 464cfe76ba8ae296cdcbb95244f8d92142e5f468..52439c750651919f22a1f5184726059a2e41bea6 100644 --- a/TP/NGSI-LD/ContextInformation/Provision/Entities/CreateEntity/001_06.robot +++ b/TP/NGSI-LD/ContextInformation/Provision/Entities/CreateEntity/001_06.robot @@ -1,21 +1,21 @@ *** Settings *** Documentation Check that an HTTP error response of type BadRequestData is raised if the Content-Type header is "application/json" and the request payload body (as JSON) contains a "@context" term +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource *** Variables *** -${building_id_prefix}= urn:ngsi-ld:Building: -${filename}= building-simple-attributes.jsonld +${filename}= building-simple-attributes.jsonld *** Test Cases *** 001_06_01 Create one entity containing a JSON-LD @context with a JSON content type [Documentation] Check that an HTTP error response of type BadRequestData is raised if the Content-Type header is "application/json" and the request payload body (as JSON) contains a "@context" term [Tags] e-create 6_3_5 - ${entity_id}= Generate Random Entity Id ${building_id_prefix} + ${entity_id}= Generate Random Building Entity Id ${response}= Create Entity Selecting Content Type ... ${filename} ... ${entity_id} diff --git a/TP/NGSI-LD/ContextInformation/Provision/Entities/CreateEntity/001_07.robot b/TP/NGSI-LD/ContextInformation/Provision/Entities/CreateEntity/001_07.robot index 20cb883ed4457e21cf8af431698e9009a078ce11..eb7897cc9742bd83a4b1501890fc376803629d30 100644 --- a/TP/NGSI-LD/ContextInformation/Provision/Entities/CreateEntity/001_07.robot +++ b/TP/NGSI-LD/ContextInformation/Provision/Entities/CreateEntity/001_07.robot @@ -1,8 +1,9 @@ *** Settings *** Documentation Check that the @context is obtained from the request payload body itself if the Content-Type header is "application/ld+json" -Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationConsumption.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -10,15 +11,14 @@ Test Teardown Delete Initial Entity *** Variables *** -${building_id_prefix}= urn:ngsi-ld:Building: -${filename}= building-simple-attributes.jsonld +${filename}= building-simple-attributes.jsonld *** Test Cases *** 001_07_01 Create one entity using a JSON-LD @context obtained from the request payload with ld context [Documentation] Check that the @context is obtained from the request payload body itself if the Content-Type header is "application/ld+json" and retrieve with ld context [Tags] e-create 6_3_5 - ${entity_id}= Generate Random Entity Id ${building_id_prefix} + ${entity_id}= Generate Random Building Entity Id Set Suite Variable ${entity_id} ${response}= Create Entity Selecting Content Type ${filename} ${entity_id} ${CONTENT_TYPE_LD_JSON} ${response1}= Retrieve Entity by Id id=${entity_id} context=${ngsild_test_suite_context} @@ -30,7 +30,7 @@ ${filename}= building-simple-attributes.jsonld 001_07_02 Create one entity using a JSON-LD @context obtained from the request payload without context [Documentation] Check that the @context is obtained from the request payload body itself if the Content-Type header is "application/ld+json" and retrieve without context [Tags] e-create 6_3_5 - ${entity_id}= Generate Random Entity Id ${building_id_prefix} + ${entity_id}= Generate Random Building Entity Id Set Suite Variable ${entity_id} ${response}= Create Entity Selecting Content Type ${filename} ${entity_id} ${CONTENT_TYPE_LD_JSON} ${response1}= Retrieve Entity by Id id=${entity_id} diff --git a/TP/NGSI-LD/ContextInformation/Provision/Entities/CreateEntity/001_08.robot b/TP/NGSI-LD/ContextInformation/Provision/Entities/CreateEntity/001_08.robot index 2b44b19f85a1a74b283f4e9f5e89278967e050f5..df7fb32b46667e6f2712d5f3b00f638a836c7478 100644 --- a/TP/NGSI-LD/ContextInformation/Provision/Entities/CreateEntity/001_08.robot +++ b/TP/NGSI-LD/ContextInformation/Provision/Entities/CreateEntity/001_08.robot @@ -1,21 +1,21 @@ *** Settings *** Documentation Check that an HTTP error response of type BadRequestData is raised if the Content-Type header is "application/ld+json" and the request payload body does not contain a @context term +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource *** Variables *** -${building_id_prefix}= urn:ngsi-ld:Building: -${filename}= building-simple-attributes.json +${filename}= building-simple-attributes.json *** Test Cases *** 001_08_01 Create one entity not containing a JSON-LD @context with a JSON-LD content type [Documentation] Check that an HTTP error response of type BadRequestData is raised if the Content-Type header is "application/ld+json" and the request payload body does not contain a @context term [Tags] e-create 6_3_5 - ${entity_id}= Generate Random Entity Id ${building_id_prefix} + ${entity_id}= Generate Random Building Entity Id ${response}= Create Entity Selecting Content Type ... ${filename} ... ${entity_id} diff --git a/TP/NGSI-LD/ContextInformation/Provision/Entities/CreateEntity/001_09.robot b/TP/NGSI-LD/ContextInformation/Provision/Entities/CreateEntity/001_09.robot index 47917f1082ff56035e161db133a2dae553c0c5fa..9fab24a1b18434cde06b36a59b795d945f3ae8a1 100644 --- a/TP/NGSI-LD/ContextInformation/Provision/Entities/CreateEntity/001_09.robot +++ b/TP/NGSI-LD/ContextInformation/Provision/Entities/CreateEntity/001_09.robot @@ -1,21 +1,21 @@ *** Settings *** Documentation Check that an HTTP error response of type BadRequestData is raised if the Content-Type header is "application/ld+json" and a JSON-LD Link header is present in the incoming HTTP request +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource *** Variables *** -${building_id_prefix}= urn:ngsi-ld:Building: -${filename}= building-simple-attributes.jsonld +${filename}= building-simple-attributes.jsonld *** Test Cases *** 001_09_01 Create one entity with a Link header and a JSON-LD content type [Documentation] Check that an HTTP error response of type BadRequestData is raised if the Content-Type header is "application/ld+json" and a JSON-LD Link header is present in the incoming HTTP request [Tags] e-create 6_3_5 - ${entity_id}= Generate Random Entity Id ${building_id_prefix} + ${entity_id}= Generate Random Building Entity Id ${response}= Create Entity Selecting Content Type ... ${filename} ... ${entity_id} diff --git a/TP/NGSI-LD/ContextInformation/Provision/Entities/CreateEntity/001_10.robot b/TP/NGSI-LD/ContextInformation/Provision/Entities/CreateEntity/001_10.robot index 2dcf2ec51a7fbd796d1c75e316529f715d342861..6a8674543c29742453e359333624407fc18e458e 100644 --- a/TP/NGSI-LD/ContextInformation/Provision/Entities/CreateEntity/001_10.robot +++ b/TP/NGSI-LD/ContextInformation/Provision/Entities/CreateEntity/001_10.robot @@ -1,8 +1,9 @@ *** Settings *** Documentation Check that one can create an entity with a LanguageProperty property -Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationConsumption.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -10,10 +11,6 @@ Test Teardown Delete Initial Entity Test Template Create Entity Scenarios -*** Variables *** -${building_id_prefix}= urn:ngsi-ld:Building: - - *** Test Cases *** FILENAME CONTENT_TYPE 001_10_01 EntityWithLanguageProperty [Tags] e-create 5_6_1 4_5_18 since_v1.4.1 @@ -24,7 +21,7 @@ ${building_id_prefix}= urn:ngsi-ld:Building: Create Entity Scenarios [Documentation] Check that one can create an entity with a LanguageProperty property [Arguments] ${filename} ${content_type} - ${entity_id}= Generate Random Entity Id ${building_id_prefix} + ${entity_id}= Generate Random Building Entity Id Set Test Variable ${entity_id} ${response}= Create Entity Selecting Content Type diff --git a/TP/NGSI-LD/ContextInformation/Provision/Entities/CreateEntity/001_11.robot b/TP/NGSI-LD/ContextInformation/Provision/Entities/CreateEntity/001_11.robot index b6341b02191bdb33f5999bbda6cbe0d79e6c8ed3..cc98c873bf79350d37748efb8fa5badeacbcac5a 100644 --- a/TP/NGSI-LD/ContextInformation/Provision/Entities/CreateEntity/001_11.robot +++ b/TP/NGSI-LD/ContextInformation/Provision/Entities/CreateEntity/001_11.robot @@ -1,8 +1,9 @@ *** Settings *** Documentation Check that one can create an entity with one or more scopes -Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationConsumption.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -10,10 +11,6 @@ Test Teardown Delete Initial Entity Test Template Create Entity Scenarios -*** Variables *** -${building_id_prefix}= urn:ngsi-ld:Building: - - *** Test Cases *** FILENAME CONTENT_TYPE 001_11_01 EntityWithOneScope [Tags] e-create 4_18 since_v1.5.1 @@ -27,7 +24,7 @@ ${building_id_prefix}= urn:ngsi-ld:Building: Create Entity Scenarios [Documentation] Check that one can create an entity with one or more scopes [Arguments] ${filename} ${content_type} - ${entity_id}= Generate Random Entity Id ${building_id_prefix} + ${entity_id}= Generate Random Building Entity Id Set Test Variable ${entity_id} ${response}= Create Entity Selecting Content Type diff --git a/TP/NGSI-LD/ContextInformation/Provision/Entities/CreateEntity/001_12.robot b/TP/NGSI-LD/ContextInformation/Provision/Entities/CreateEntity/001_12.robot index d1357bcaecf609bc222a1c25ddd1ecdcd6be5135..73a88dfc6325a682559364ba2a565095d0a5affe 100644 --- a/TP/NGSI-LD/ContextInformation/Provision/Entities/CreateEntity/001_12.robot +++ b/TP/NGSI-LD/ContextInformation/Provision/Entities/CreateEntity/001_12.robot @@ -1,8 +1,9 @@ *** Settings *** Documentation Check that one can create an entity with observationSpace geospatial Property -Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationConsumption.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -10,9 +11,8 @@ Test Teardown Delete Initial Entity *** Variables *** -${building_id_prefix}= urn:ngsi-ld:Building: -${filename}= building-observation-space-geoproperty.jsonld -${content_type}= application/ld+json +${filename}= building-observation-space-geoproperty.jsonld +${content_type}= application/ld+json *** Test Cases *** @@ -20,7 +20,7 @@ ${content_type}= application/ld+json [Documentation] Check that one can create an entity with observationSpace geospatial Property [Tags] e-create 5_6_1 4_7 - ${entity_id}= Generate Random Entity Id ${building_id_prefix} + ${entity_id}= Generate Random Building Entity Id Set Test Variable ${entity_id} ${response}= Create Entity Selecting Content Type diff --git a/TP/NGSI-LD/ContextInformation/Provision/Entities/CreateEntity/001_13.robot b/TP/NGSI-LD/ContextInformation/Provision/Entities/CreateEntity/001_13.robot index 08bcaa127a03b42ee95d27cd97b0faad56bc9b8b..3358c56e944de35a3b55bc9b59a2cc1e23b88dcb 100644 --- a/TP/NGSI-LD/ContextInformation/Provision/Entities/CreateEntity/001_13.robot +++ b/TP/NGSI-LD/ContextInformation/Provision/Entities/CreateEntity/001_13.robot @@ -1,8 +1,9 @@ *** Settings *** Documentation Check that one can create an entity with operationSpace geospatial Property -Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationConsumption.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -10,9 +11,8 @@ Test Teardown Delete Initial Entity *** Variables *** -${building_id_prefix}= urn:ngsi-ld:Building: -${filename}= building-operation-space-geoproperty.jsonld -${content_type}= application/ld+json +${filename}= building-operation-space-geoproperty.jsonld +${content_type}= application/ld+json *** Test Cases *** @@ -20,7 +20,7 @@ ${content_type}= application/ld+json [Documentation] Check that one can create an entity with operationSpace geospatial Property [Tags] e-create 5_6_1 4_7 - ${entity_id}= Generate Random Entity Id ${building_id_prefix} + ${entity_id}= Generate Random Building Entity Id Set Test Variable ${entity_id} ${response}= Create Entity Selecting Content Type diff --git a/TP/NGSI-LD/ContextInformation/Provision/Entities/DeleteEntity/002_01.robot b/TP/NGSI-LD/ContextInformation/Provision/Entities/DeleteEntity/002_01.robot index a9ecdf6e042cd6d28254bc923bf298b739014ae2..eebee0b62b21aec8fe831d657d73ca9efb778acd 100644 --- a/TP/NGSI-LD/ContextInformation/Provision/Entities/DeleteEntity/002_01.robot +++ b/TP/NGSI-LD/ContextInformation/Provision/Entities/DeleteEntity/002_01.robot @@ -1,18 +1,15 @@ *** Settings *** Documentation Check that one can delete an entity by id -Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationConsumption.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource Test Setup Setup Initial Entity -*** Variables *** -${building_id_prefix}= urn:ngsi-ld:Building: - - *** Test Cases *** 002_01_01 Delete an entity [Documentation] Check that one can delete an entity by id @@ -25,7 +22,7 @@ ${building_id_prefix}= urn:ngsi-ld:Building: *** Keywords *** Setup Initial Entity - ${entity_id}= Generate Random Entity Id ${building_id_prefix} + ${entity_id}= Generate Random Building Entity Id ${response}= Create Entity Selecting Content Type ... building-simple-attributes.jsonld ... ${entity_id} diff --git a/TP/NGSI-LD/ContextInformation/Provision/Entities/DeleteEntity/002_03.robot b/TP/NGSI-LD/ContextInformation/Provision/Entities/DeleteEntity/002_03.robot index f872c9077a10ec8433397a27ac051e12b341590a..5aa3128e27cbb0dc4ebbd96866c979459487be66 100644 --- a/TP/NGSI-LD/ContextInformation/Provision/Entities/DeleteEntity/002_03.robot +++ b/TP/NGSI-LD/ContextInformation/Provision/Entities/DeleteEntity/002_03.robot @@ -1,13 +1,13 @@ *** Settings *** Documentation Check that one cannot delete an entity if the entity id is not known to the system +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource *** Variables *** -${building_id_prefix}= urn:ngsi-ld:Building: ${expected_status_code}= 404 @@ -15,7 +15,7 @@ ${expected_status_code}= 404 002_03_01 Delete an entity with an id not known to the system [Documentation] Check that one cannot delete an entity if the entity id is not known to the system [Tags] e-delete 5_6_6 - ${entity_id}= Generate Random Entity Id ${building_id_prefix} + ${entity_id}= Generate Random Building Entity Id ${response}= Delete Entity by Id ${entity_id} Check Response Status Code ${expected_status_code} ${response.status_code} Check Response Body Containing ProblemDetails Element Containing Type Element set to diff --git a/TP/NGSI-LD/ContextInformation/Provision/Entities/MergeEntity/056_01.robot b/TP/NGSI-LD/ContextInformation/Provision/Entities/MergeEntity/056_01.robot index 72c4959ceec92922e36c6b0de379ac82cc0b6c75..278c6df32146255b65ac5fc95f90988e41cf29fc 100644 --- a/TP/NGSI-LD/ContextInformation/Provision/Entities/MergeEntity/056_01.robot +++ b/TP/NGSI-LD/ContextInformation/Provision/Entities/MergeEntity/056_01.robot @@ -1,8 +1,9 @@ *** Settings *** Documentation Check that one can merge an entity -Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationConsumption.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -12,7 +13,6 @@ Test Template Merge Entity Scenarios *** Variables *** -${building_id_prefix}= urn:ngsi-ld:Building: ${entity_payload_filename}= merge/building-merge-data.jsonld @@ -51,7 +51,7 @@ Merge Entity Scenarios ... response_body=${response1.json()} Setup Initial Entity - ${entity_id}= Generate Random Entity Id ${building_id_prefix} + ${entity_id}= Generate Random Building Entity Id ${response}= Create Entity ${entity_payload_filename} ${entity_id} Set Test Variable ${entity_id} Check Response Status Code 201 ${response.status_code} diff --git a/TP/NGSI-LD/ContextInformation/Provision/Entities/MergeEntity/056_02.robot b/TP/NGSI-LD/ContextInformation/Provision/Entities/MergeEntity/056_02.robot index f277ea3076d7459c75b7240e6f9dee9b1b1fa589..0b6200dcecbff6a7642d8fe66f08d37b13dd9d44 100644 --- a/TP/NGSI-LD/ContextInformation/Provision/Entities/MergeEntity/056_02.robot +++ b/TP/NGSI-LD/ContextInformation/Provision/Entities/MergeEntity/056_02.robot @@ -1,8 +1,9 @@ *** Settings *** Documentation Check that if the target entity ID is faulty an error is raised -Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationConsumption.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -12,7 +13,6 @@ Test Template Merge an existing entity with a faulty ID *** Variables *** -${building_id_prefix} urn:ngsi-ld:Building: ${entity_filename} building-simple-attributes.json ${entity_replacement_filename} building-locatedAt-and-name.json @@ -43,7 +43,7 @@ Merge an existing entity with a faulty ID Check Response Status Code ${expected_status_code} ${response.status_code} Setup Initial Entity - ${entity_id}= Generate Random Entity Id ${building_id_prefix} + ${entity_id}= Generate Random Building Entity Id Set Test Variable ${entity_id} ${response}= Create Entity Selecting Content Type ... ${entity_filename} diff --git a/TP/NGSI-LD/ContextInformation/Provision/Entities/MergeEntity/056_03.robot b/TP/NGSI-LD/ContextInformation/Provision/Entities/MergeEntity/056_03.robot index 3e878bec52c1194265754f9f27216d13af6e7ef5..247992bd90ef65393c09ac9e13c71e6c35086095 100644 --- a/TP/NGSI-LD/ContextInformation/Provision/Entities/MergeEntity/056_03.robot +++ b/TP/NGSI-LD/ContextInformation/Provision/Entities/MergeEntity/056_03.robot @@ -1,8 +1,9 @@ *** Settings *** Documentation Check that one can delete an attribute using NGSI-LD Null in a Merge Entity operation -Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationConsumption.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -12,7 +13,6 @@ Test Template Merge Entity Scenarios *** Variables *** -${building_id_prefix}= urn:ngsi-ld:Building: ${entity_payload_filename}= building-different-attributes-types.jsonld @@ -51,7 +51,7 @@ Merge Entity Scenarios ... response_body=${response1.json()} Setup Initial Entity - ${entity_id}= Generate Random Entity Id ${building_id_prefix} + ${entity_id}= Generate Random Building Entity Id ${response}= Create Entity ${entity_payload_filename} ${entity_id} Set Test Variable ${entity_id} Check Response Status Code 201 ${response.status_code} diff --git a/TP/NGSI-LD/ContextInformation/Provision/Entities/MergeEntity/056_04.robot b/TP/NGSI-LD/ContextInformation/Provision/Entities/MergeEntity/056_04.robot index a2bda14cb761fd10ead887460750998724f45bd0..d2ffb5308672708384911bb226c452b7c8af2209 100644 --- a/TP/NGSI-LD/ContextInformation/Provision/Entities/MergeEntity/056_04.robot +++ b/TP/NGSI-LD/ContextInformation/Provision/Entities/MergeEntity/056_04.robot @@ -1,8 +1,9 @@ *** Settings *** Documentation Check that one can delete a specific attribute instance using NGSI-LD Null in a Merge Entity operation -Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationConsumption.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -12,7 +13,6 @@ Test Template Merge Entity Scenarios *** Variables *** -${building_id_prefix}= urn:ngsi-ld:Building: ${entity_payload_filename}= building-different-attributes-instances-and-types.jsonld @@ -51,7 +51,7 @@ Merge Entity Scenarios ... response_body=${response1.json()} Setup Initial Entity - ${entity_id}= Generate Random Entity Id ${building_id_prefix} + ${entity_id}= Generate Random Building Entity Id ${response}= Create Entity ${entity_payload_filename} ${entity_id} Set Test Variable ${entity_id} Check Response Status Code 201 ${response.status_code} diff --git a/TP/NGSI-LD/ContextInformation/Provision/Entities/MergeEntity/056_05.robot b/TP/NGSI-LD/ContextInformation/Provision/Entities/MergeEntity/056_05.robot index 027e63d08395987b33552015610a0a47c1bc19de..f53da455259ec3d2e446ec71224bf84455fc7239 100644 --- a/TP/NGSI-LD/ContextInformation/Provision/Entities/MergeEntity/056_05.robot +++ b/TP/NGSI-LD/ContextInformation/Provision/Entities/MergeEntity/056_05.robot @@ -1,8 +1,9 @@ *** Settings *** Documentation Check that one can delete the default attribute instance using NGSI-LD Null in a Merge Entity operation -Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationConsumption.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -12,7 +13,6 @@ Test Template Merge Entity Scenarios *** Variables *** -${building_id_prefix}= urn:ngsi-ld:Building: ${entity_payload_filename}= building-different-default-attributes-instances-and-types.jsonld @@ -51,7 +51,7 @@ Merge Entity Scenarios ... response_body=${response1.json()} Setup Initial Entity - ${entity_id}= Generate Random Entity Id ${building_id_prefix} + ${entity_id}= Generate Random Building Entity Id ${response}= Create Entity ${entity_payload_filename} ${entity_id} Set Test Variable ${entity_id} Check Response Status Code 201 ${response.status_code} diff --git a/TP/NGSI-LD/ContextInformation/Provision/Entities/ReplaceEntity/054_01.robot b/TP/NGSI-LD/ContextInformation/Provision/Entities/ReplaceEntity/054_01.robot index dffa254a0dfd0728aec88d532d5262a618d86420..d5ccbc163f969f05244690c5629046adabd198c6 100644 --- a/TP/NGSI-LD/ContextInformation/Provision/Entities/ReplaceEntity/054_01.robot +++ b/TP/NGSI-LD/ContextInformation/Provision/Entities/ReplaceEntity/054_01.robot @@ -1,8 +1,9 @@ *** Settings *** Documentation Check that one can replace an existing entity and that its createdAt Temporal Property remains unchanged -Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationConsumption.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -11,7 +12,6 @@ Test Teardown Delete Initial Entity *** Variables *** -${building_id_prefix} urn:ngsi-ld:Building: ${entity_filename} building-simple-attributes.json ${entity_replacement_filename} building-locatedAt-and-name.json ${expectation_filename} building-locatedAt-and-name-normalized.jsonld @@ -50,7 +50,7 @@ ${expectation_filename} building-locatedAt-and-name-normalized.jsonl *** Keywords *** Setup Initial Entity - ${entity_id}= Generate Random Entity Id ${building_id_prefix} + ${entity_id}= Generate Random Building Entity Id Set Test Variable ${entity_id} ${response}= Create Entity Selecting Content Type ... ${entity_filename} diff --git a/TP/NGSI-LD/ContextInformation/Provision/Entities/ReplaceEntity/054_02.robot b/TP/NGSI-LD/ContextInformation/Provision/Entities/ReplaceEntity/054_02.robot index 47b262fe70fa74f29ad5fc59955b8c16e9baabda..84ab3660a8e89ce0e0b8648d95253b2152108ca9 100644 --- a/TP/NGSI-LD/ContextInformation/Provision/Entities/ReplaceEntity/054_02.robot +++ b/TP/NGSI-LD/ContextInformation/Provision/Entities/ReplaceEntity/054_02.robot @@ -1,8 +1,9 @@ *** Settings *** Documentation Check that if the target entity ID is faulty an error is raised -Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationConsumption.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -12,7 +13,6 @@ Test Template Replace an existing entity with a faulty ID *** Variables *** -${building_id_prefix} urn:ngsi-ld:Building: ${entity_filename} building-simple-attributes.json ${entity_replacement_filename} building-locatedAt-and-name.json @@ -44,7 +44,7 @@ Replace an existing entity with a faulty ID Check Response Status Code ${expected_status_code} ${response.status_code} Setup Initial Entity - ${entity_id}= Generate Random Entity Id ${building_id_prefix} + ${entity_id}= Generate Random Building Entity Id Set Test Variable ${entity_id} ${response}= Create Entity Selecting Content Type ... ${entity_filename} diff --git a/TP/NGSI-LD/ContextInformation/Provision/Entities/ReplaceEntity/054_03.robot b/TP/NGSI-LD/ContextInformation/Provision/Entities/ReplaceEntity/054_03.robot index 19e2b34fcfedf44eb6fc204e82dea65a59ebb998..1f5837606e1a72ad075c08850f47d07153c118ad 100644 --- a/TP/NGSI-LD/ContextInformation/Provision/Entities/ReplaceEntity/054_03.robot +++ b/TP/NGSI-LD/ContextInformation/Provision/Entities/ReplaceEntity/054_03.robot @@ -1,8 +1,9 @@ *** Settings *** Documentation Check that one can replace an existing entity and that scopes are replaced -Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationConsumption.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Test Setup Setup Initial Entity @@ -10,7 +11,6 @@ Test Teardown Delete Initial Entity *** Variables *** -${building_id_prefix} urn:ngsi-ld:Building: ${entity_filename} building-minimal-with-one-scope.json ${entity_replacement_filename} building-minimal-with-many-scopes.json ${expectation_filename} building-minimal-with-two-scopes.json @@ -39,7 +39,7 @@ ${expectation_filename} building-minimal-with-two-scopes.json *** Keywords *** Setup Initial Entity - ${entity_id}= Generate Random Entity Id ${building_id_prefix} + ${entity_id}= Generate Random Building Entity Id Set Test Variable ${entity_id} ${response}= Create Entity Selecting Content Type ... ${entity_filename} diff --git a/TP/NGSI-LD/ContextInformation/Provision/EntityAttributes/AppendEntityAttributes/010_01.robot b/TP/NGSI-LD/ContextInformation/Provision/EntityAttributes/AppendEntityAttributes/010_01.robot index 30a523c220f227e4f3648120fbcfd61942e9863c..cb9f8934fa420987008ea95bc42167f021c0c43f 100644 --- a/TP/NGSI-LD/ContextInformation/Provision/EntityAttributes/AppendEntityAttributes/010_01.robot +++ b/TP/NGSI-LD/ContextInformation/Provision/EntityAttributes/AppendEntityAttributes/010_01.robot @@ -1,8 +1,9 @@ *** Settings *** Documentation Check that one can append entity attributes -Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationConsumption.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -12,8 +13,7 @@ Test Template Append Attributes Without Params *** Variables *** -${vehicle_id_prefix}= urn:ngsi-ld:Vehicle: -${filename}= vehicle-speed-two-datasetid.jsonld +${filename}= vehicle-speed-two-datasetid.jsonld *** Test Cases *** STATUS_CODE FRAGMENT_FILENAME EXPECTATION_FILENAME @@ -41,7 +41,7 @@ Append Attributes Without Params ... response_body=${response1.json()} Create Initial Entity - ${entity_id}= Generate Random Entity Id ${vehicle_id_prefix} + ${entity_id}= Generate Random Vehicle Entity Id ${response}= Create Entity Selecting Content Type ... ${filename} ... ${entity_id} diff --git a/TP/NGSI-LD/ContextInformation/Provision/EntityAttributes/AppendEntityAttributes/010_02.robot b/TP/NGSI-LD/ContextInformation/Provision/EntityAttributes/AppendEntityAttributes/010_02.robot index dd5c5b63917c056782df708ced04a69caf79de66..f5b43cb2e76bedcc43655a6b34f9f69a79177564 100644 --- a/TP/NGSI-LD/ContextInformation/Provision/EntityAttributes/AppendEntityAttributes/010_02.robot +++ b/TP/NGSI-LD/ContextInformation/Provision/EntityAttributes/AppendEntityAttributes/010_02.robot @@ -1,6 +1,7 @@ *** Settings *** Documentation Check that one cannot append entity attributes with invalid/missing id or invalid request body +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -11,7 +12,6 @@ Test Template Append Attributes *** Variables *** -${vehicle_id_prefix}= urn:ngsi-ld:Vehicle: ${filename}= vehicle-speed-two-datasetid.jsonld ${fragment_filename}= vehicle-attribute-to-add-fragment.jsonld ${status_code}= 400 @@ -39,7 +39,7 @@ Append Attributes [Teardown] Delete Entity by Id ${entity_id} Create Initial Entity - ${entity_id}= Generate Random Entity Id ${vehicle_id_prefix} + ${entity_id}= Generate Random Vehicle Entity Id ${response}= Create Entity Selecting Content Type ... ${filename} ... ${entity_id} diff --git a/TP/NGSI-LD/ContextInformation/Provision/EntityAttributes/AppendEntityAttributes/010_03.robot b/TP/NGSI-LD/ContextInformation/Provision/EntityAttributes/AppendEntityAttributes/010_03.robot index 659cfd227ce6ae5620795058a7a380131863803b..07d3e62e7cc2cb4ed94359089cba397fa84d6c83 100644 --- a/TP/NGSI-LD/ContextInformation/Provision/EntityAttributes/AppendEntityAttributes/010_03.robot +++ b/TP/NGSI-LD/ContextInformation/Provision/EntityAttributes/AppendEntityAttributes/010_03.robot @@ -1,6 +1,7 @@ *** Settings *** Documentation Check that one cannot append entity attributes if the entity id is not known to the system +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -9,7 +10,6 @@ Suite Teardown Delete Initial Entities *** Variables *** -${vehicle_id_prefix}= urn:ngsi-ld:Vehicle: ${fragment_filename}= vehicle-attribute-to-add-fragment.jsonld @@ -17,7 +17,7 @@ ${fragment_filename}= vehicle-attribute-to-add-fragment.jsonld 010_03_01 Append entity attributes when the entity id is not known to the system [Documentation] Check that one cannot append entity attributes if the entity id is not known to the system [Tags] ea-append 5_6_3 - ${entity_id}= Generate Random Entity Id ${vehicle_id_prefix} + ${entity_id}= Generate Random Vehicle Entity Id Set Suite Variable ${entity_id} ${response}= Append Entity Attributes ${entity_id} ${fragment_filename} ${CONTENT_TYPE_LD_JSON} Check Response Status Code 404 ${response.status_code} diff --git a/TP/NGSI-LD/ContextInformation/Provision/EntityAttributes/AppendEntityAttributes/010_04.robot b/TP/NGSI-LD/ContextInformation/Provision/EntityAttributes/AppendEntityAttributes/010_04.robot index 35d2e2feb2d3c3e2bca8e1934c58b1a5132cbcd6..71eee8cb9f035e608739feb7867a12c645d0c999 100644 --- a/TP/NGSI-LD/ContextInformation/Provision/EntityAttributes/AppendEntityAttributes/010_04.robot +++ b/TP/NGSI-LD/ContextInformation/Provision/EntityAttributes/AppendEntityAttributes/010_04.robot @@ -1,6 +1,7 @@ *** Settings *** Documentation Check that one can append entity attributes with noOverwrite option +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationConsumption.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource Resource ${EXECDIR}/resources/AssertionUtils.resource @@ -12,7 +13,6 @@ Test Template Append Attributes With Params *** Variables *** -${vehicle_id_prefix}= urn:ngsi-ld:Vehicle: ${filename}= vehicle-speed-two-datasetid.jsonld ${existing_attribute_name}= https://ngsi-ld-test-suite/context#speed ${non_existing_attribute_name}= https://uri.etsi.org/ngsi-ld/default-context/attribute_to_be_added @@ -57,7 +57,7 @@ Append Attributes With Params ... ignored_keys=${ignored_attributes} Create Initial Entity - ${entity_id}= Generate Random Entity Id ${vehicle_id_prefix} + ${entity_id}= Generate Random Vehicle Entity Id ${response}= Create Entity Selecting Content Type ... ${filename} ... ${entity_id} diff --git a/TP/NGSI-LD/ContextInformation/Provision/EntityAttributes/AppendEntityAttributes/010_05.robot b/TP/NGSI-LD/ContextInformation/Provision/EntityAttributes/AppendEntityAttributes/010_05.robot index 48022c6a4778b6d404cb5b4765a77cb9c84f6417..b8f08070bb5230fa0674cb08587f8b1957fb115e 100644 --- a/TP/NGSI-LD/ContextInformation/Provision/EntityAttributes/AppendEntityAttributes/010_05.robot +++ b/TP/NGSI-LD/ContextInformation/Provision/EntityAttributes/AppendEntityAttributes/010_05.robot @@ -1,6 +1,7 @@ *** Settings *** Documentation Check that one cannot append entity attributes with invalid/missing id or invalid request body +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -10,7 +11,6 @@ Test Teardown Delete Initial Entity *** Variables *** -${vehicle_id_prefix}= urn:ngsi-ld:Vehicle: ${filename}= vehicle-speed-two-datasetid.jsonld ${fragment_filename}= vehicle-attribute-to-add-fragment.jsonld ${status_code}= 400 @@ -32,7 +32,7 @@ ${invalid_fragment_filename}= invalid-fragment.jsonld *** Keywords *** Create Initial Entity - ${entity_id}= Generate Random Entity Id ${vehicle_id_prefix} + ${entity_id}= Generate Random Vehicle Entity Id ${response}= Create Entity Selecting Content Type ... ${filename} ... ${entity_id} diff --git a/TP/NGSI-LD/ContextInformation/Provision/EntityAttributes/AppendEntityAttributes/010_06.robot b/TP/NGSI-LD/ContextInformation/Provision/EntityAttributes/AppendEntityAttributes/010_06.robot index aa01055505817f2bc7816b51bb3202dc1c2035d0..b9de0b2de0a567bd659b691e29032d5eae3338bd 100644 --- a/TP/NGSI-LD/ContextInformation/Provision/EntityAttributes/AppendEntityAttributes/010_06.robot +++ b/TP/NGSI-LD/ContextInformation/Provision/EntityAttributes/AppendEntityAttributes/010_06.robot @@ -1,8 +1,9 @@ *** Settings *** Documentation Check that one can append a LanguageProperty property to an entity -Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationConsumption.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -12,8 +13,7 @@ Test Template Append Attributes Without Params *** Variables *** -${vehicle_id_prefix}= urn:ngsi-ld:Vehicle: -${filename}= vehicle-speed-two-datasetid.jsonld +${filename}= vehicle-speed-two-datasetid.jsonld *** Test Cases *** STATUS_CODE FRAGMENT_FILENAME EXPECTATION_FILENAME @@ -36,7 +36,7 @@ Append Attributes Without Params Check Updated Resource Set To ${entity_expectation_payload} ${response1.json()} Create Initial Entity - ${entity_id}= Generate Random Entity Id ${vehicle_id_prefix} + ${entity_id}= Generate Random Vehicle Entity Id ${create_response}= Create Entity Selecting Content Type ... ${filename} ... ${entity_id} diff --git a/TP/NGSI-LD/ContextInformation/Provision/EntityAttributes/AppendEntityAttributes/010_07.robot b/TP/NGSI-LD/ContextInformation/Provision/EntityAttributes/AppendEntityAttributes/010_07.robot index 2f2ef05fbc7bb1e901df9da2e40cb74067cb1b16..a9520bdaf99037884430f62a2ec7bcc6cd412043 100644 --- a/TP/NGSI-LD/ContextInformation/Provision/EntityAttributes/AppendEntityAttributes/010_07.robot +++ b/TP/NGSI-LD/ContextInformation/Provision/EntityAttributes/AppendEntityAttributes/010_07.robot @@ -1,8 +1,9 @@ *** Settings *** Documentation Check that one can append a scope to an entity -Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationConsumption.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -11,7 +12,6 @@ Test Teardown Delete Initial Entity *** Variables *** -${vehicle_id_prefix}= urn:ngsi-ld:Vehicle: ${filename}= building-minimal-with-one-scope.json ${scope_fragment_filename}= one-scope-fragment.json @@ -53,7 +53,7 @@ ${scope_fragment_filename}= one-scope-fragment.json *** Keywords *** Create Initial Entity - ${entity_id}= Generate Random Entity Id ${vehicle_id_prefix} + ${entity_id}= Generate Random Vehicle Entity Id Set Test Variable ${entity_id} ${response}= Create Entity Selecting Content Type ... ${filename} diff --git a/TP/NGSI-LD/ContextInformation/Provision/EntityAttributes/AppendEntityAttributes/010_08.robot b/TP/NGSI-LD/ContextInformation/Provision/EntityAttributes/AppendEntityAttributes/010_08.robot index 8e74c85275fbac064c1bbe89b4b61327335f7c47..f625be32a89204d30a0ec2f6dcf141c6caa4f706 100644 --- a/TP/NGSI-LD/ContextInformation/Provision/EntityAttributes/AppendEntityAttributes/010_08.robot +++ b/TP/NGSI-LD/ContextInformation/Provision/EntityAttributes/AppendEntityAttributes/010_08.robot @@ -1,8 +1,9 @@ *** Settings *** Documentation Check that one can append an observationSpace geospatial Property to an entity -Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationConsumption.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -11,7 +12,6 @@ Test Teardown Delete Initial Entity *** Variables *** -${building_id_prefix}= urn:ngsi-ld:Building: ${filename}= building-minimal.jsonld ${observation_space_fragment_filename}= observation-space-fragment.json ${expectation_filename}= building-observation-space-geoproperty-normalized.jsonld @@ -36,7 +36,7 @@ ${expectation_filename}= building-observation-space-geoproper *** Keywords *** Create Initial Entity - ${entity_id}= Generate Random Entity Id ${building_id_prefix} + ${entity_id}= Generate Random Building Entity Id Set Test Variable ${entity_id} ${response}= Create Entity ... ${filename} diff --git a/TP/NGSI-LD/ContextInformation/Provision/EntityAttributes/AppendEntityAttributes/010_09.robot b/TP/NGSI-LD/ContextInformation/Provision/EntityAttributes/AppendEntityAttributes/010_09.robot index 853f9724551fb49502ec960636060954341c061d..6e78b67c627a7eb381eaace89ae5caa29604402d 100644 --- a/TP/NGSI-LD/ContextInformation/Provision/EntityAttributes/AppendEntityAttributes/010_09.robot +++ b/TP/NGSI-LD/ContextInformation/Provision/EntityAttributes/AppendEntityAttributes/010_09.robot @@ -1,8 +1,9 @@ *** Settings *** Documentation Check that one can append an operationSpace geospatial Property to an entity -Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationConsumption.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -11,7 +12,6 @@ Test Teardown Delete Initial Entity *** Variables *** -${building_id_prefix}= urn:ngsi-ld:Building: ${filename}= building-minimal.jsonld ${operation_space_fragment_filename}= operation-space-fragment.json ${expectation_filename}= building-operation-space-geoproperty-normalized.jsonld @@ -36,7 +36,7 @@ ${expectation_filename}= building-operation-space-geoproperty *** Keywords *** Create Initial Entity - ${entity_id}= Generate Random Entity Id ${building_id_prefix} + ${entity_id}= Generate Random Building Entity Id Set Test Variable ${entity_id} ${response}= Create Entity ... ${filename} diff --git a/TP/NGSI-LD/ContextInformation/Provision/EntityAttributes/DeleteEntityAttribute/013_01.robot b/TP/NGSI-LD/ContextInformation/Provision/EntityAttributes/DeleteEntityAttribute/013_01.robot index e92c21dd9dac84954d46695314c6cf4da7e02cb2..96648d8a1f30727ac4c3e99c7b304e55cde7ab11 100644 --- a/TP/NGSI-LD/ContextInformation/Provision/EntityAttributes/DeleteEntityAttribute/013_01.robot +++ b/TP/NGSI-LD/ContextInformation/Provision/EntityAttributes/DeleteEntityAttribute/013_01.robot @@ -1,8 +1,9 @@ *** Settings *** Documentation Check that one can delete an attribute from an entity -Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationConsumption.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -12,10 +13,9 @@ Test Template Delete Attributes *** Variables *** -${vehicle_id_prefix}= urn:ngsi-ld:Vehicle: -${status_code}= 204 -${filename}= vehicle-two-datasetid-attributes.jsonld -${attribute_id}= speed +${status_code}= 204 +${filename}= vehicle-two-datasetid-attributes.jsonld +${attribute_id}= speed *** Test Cases *** DATASETID DELETEALL EXPECTATION_FILENAME @@ -52,7 +52,7 @@ Delete Attributes ... ignored_keys=${ignored_attributes} Setup Initial Entity - ${entity_id}= Generate Random Entity Id ${vehicle_id_prefix} + ${entity_id}= Generate Random Vehicle Entity Id Set Test Variable ${entity_id} ${create_response}= Create Entity Selecting Content Type ... ${filename} diff --git a/TP/NGSI-LD/ContextInformation/Provision/EntityAttributes/DeleteEntityAttribute/013_02.robot b/TP/NGSI-LD/ContextInformation/Provision/EntityAttributes/DeleteEntityAttribute/013_02.robot index 36b23f39926473a8a9e6c71d1a52fc1a11a7ba19..51752453b4e3f778268da42c6cf0a6d65659502a 100644 --- a/TP/NGSI-LD/ContextInformation/Provision/EntityAttributes/DeleteEntityAttribute/013_02.robot +++ b/TP/NGSI-LD/ContextInformation/Provision/EntityAttributes/DeleteEntityAttribute/013_02.robot @@ -1,6 +1,7 @@ *** Settings *** Documentation Check that one cannot delete an attribute from an entity with invalid/missing ids +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -11,8 +12,7 @@ Test Template Delete Attributes *** Variables *** -${vehicle_id_prefix}= urn:ngsi-ld:Vehicle: -${filename}= vehicle-two-datasetid-attributes.jsonld +${filename}= vehicle-two-datasetid-attributes.jsonld *** Test Cases *** ENTITY_ID ATTRIBUTE_ID EXPECTED_STATUS_CODE @@ -37,7 +37,7 @@ Delete Attributes Check Response Status Code ${expected_status_code} ${response.status_code} Create Initial Entity - ${valid_entity_id}= Generate Random Entity Id ${vehicle_id_prefix} + ${valid_entity_id}= Generate Random Vehicle Entity Id Set Test Variable ${valid_entity_id} ${create_response}= Create Entity Selecting Content Type ... ${filename} diff --git a/TP/NGSI-LD/ContextInformation/Provision/EntityAttributes/DeleteEntityAttribute/013_03.robot b/TP/NGSI-LD/ContextInformation/Provision/EntityAttributes/DeleteEntityAttribute/013_03.robot index b1c0448d1bfddb4c255ca0b02fc5df788a53964c..3ba0ff03a4b72bae45b4789b976f399a54544f23 100644 --- a/TP/NGSI-LD/ContextInformation/Provision/EntityAttributes/DeleteEntityAttribute/013_03.robot +++ b/TP/NGSI-LD/ContextInformation/Provision/EntityAttributes/DeleteEntityAttribute/013_03.robot @@ -1,6 +1,7 @@ *** Settings *** Documentation Check that one cannot delete an attribute from an entity with invalid/missing ids +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -11,9 +12,8 @@ Test Template Delete Attributes *** Variables *** -${vehicle_id_prefix}= urn:ngsi-ld:Vehicle: -${status_code}= 404 -${filename}= vehicle-two-datasetid-attributes.jsonld +${status_code}= 404 +${filename}= vehicle-two-datasetid-attributes.jsonld *** Test Cases *** ENTITY_ID ATTRIBUTE_ID DATASETID @@ -38,14 +38,14 @@ Delete Attributes Check Response Status Code ${status_code} ${response.status_code} Setup Initial Entity - ${valid_entity_id}= Generate Random Entity Id ${vehicle_id_prefix} + ${valid_entity_id}= Generate Random Vehicle Entity Id Set Test Variable ${valid_entity_id} ${response}= Create Entity Selecting Content Type ... ${filename} ... ${valid_entity_id} ... ${CONTENT_TYPE_LD_JSON} Check Response Status Code 201 ${response.status_code} - ${not_found_entity_id}= Generate Random Entity Id ${vehicle_id_prefix} + ${not_found_entity_id}= Generate Random Vehicle Entity Id Set Suite Variable ${not_found_entity_id} Delete Initial Entity diff --git a/TP/NGSI-LD/ContextInformation/Provision/EntityAttributes/DeleteEntityAttribute/013_04.robot b/TP/NGSI-LD/ContextInformation/Provision/EntityAttributes/DeleteEntityAttribute/013_04.robot index bc4464f08323dbf545ae2b2fda459930a17748bc..c4793c28b8bceebdc4f0c44fd3e9d8ec164188aa 100644 --- a/TP/NGSI-LD/ContextInformation/Provision/EntityAttributes/DeleteEntityAttribute/013_04.robot +++ b/TP/NGSI-LD/ContextInformation/Provision/EntityAttributes/DeleteEntityAttribute/013_04.robot @@ -1,8 +1,9 @@ *** Settings *** Documentation Check that one can delete a scope from an entity -Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationConsumption.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -11,7 +12,6 @@ Test Teardown Delete Initial Entity *** Variables *** -${vehicle_id_prefix}= urn:ngsi-ld:Vehicle: ${filename}= building-minimal-with-one-scope.json ${expectation_filename}= building-minimal-compacted.json @@ -35,7 +35,7 @@ ${expectation_filename}= building-minimal-compacted.json *** Keywords *** Create Initial Entity - ${entity_id}= Generate Random Entity Id ${vehicle_id_prefix} + ${entity_id}= Generate Random Vehicle Entity Id Set Test Variable ${entity_id} ${response}= Create Entity Selecting Content Type ... ${filename} diff --git a/TP/NGSI-LD/ContextInformation/Provision/EntityAttributes/DeleteEntityAttribute/013_05.robot b/TP/NGSI-LD/ContextInformation/Provision/EntityAttributes/DeleteEntityAttribute/013_05.robot index 3a7162f88cd133413c0df4e626bad9ceaea2869a..82cee02c14c6f708ebb3eee4bb937312de155790 100644 --- a/TP/NGSI-LD/ContextInformation/Provision/EntityAttributes/DeleteEntityAttribute/013_05.robot +++ b/TP/NGSI-LD/ContextInformation/Provision/EntityAttributes/DeleteEntityAttribute/013_05.robot @@ -1,8 +1,9 @@ *** Settings *** Documentation Check that one can delete an observationSpace geospatial Property from an entity -Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationConsumption.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -11,7 +12,6 @@ Test Teardown Delete Initial Entity *** Variables *** -${building_id_prefix}= urn:ngsi-ld:Building: ${filename}= building-observation-space-geoproperty.jsonld ${expectation_filename}= building-minimal-compacted.json @@ -35,7 +35,7 @@ ${expectation_filename}= building-minimal-compacted.json *** Keywords *** Create Initial Entity - ${entity_id}= Generate Random Entity Id ${building_id_prefix} + ${entity_id}= Generate Random Building Entity Id Set Test Variable ${entity_id} ${response}= Create Entity ... ${filename} diff --git a/TP/NGSI-LD/ContextInformation/Provision/EntityAttributes/DeleteEntityAttribute/013_06.robot b/TP/NGSI-LD/ContextInformation/Provision/EntityAttributes/DeleteEntityAttribute/013_06.robot index 4aa62543218e0c8d67e9298939fa34ee4728c1d7..c7952056cc373133400053eff28315df819f8822 100644 --- a/TP/NGSI-LD/ContextInformation/Provision/EntityAttributes/DeleteEntityAttribute/013_06.robot +++ b/TP/NGSI-LD/ContextInformation/Provision/EntityAttributes/DeleteEntityAttribute/013_06.robot @@ -1,8 +1,9 @@ *** Settings *** Documentation Check that one can delete an operationSpace geospatial Property from an entity -Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationConsumption.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -11,7 +12,6 @@ Test Teardown Delete Initial Entity *** Variables *** -${building_id_prefix}= urn:ngsi-ld:Building: ${filename}= building-operation-space-geoproperty.jsonld ${expectation_filename}= building-minimal-compacted.json @@ -35,7 +35,7 @@ ${expectation_filename}= building-minimal-compacted.json *** Keywords *** Create Initial Entity - ${entity_id}= Generate Random Entity Id ${building_id_prefix} + ${entity_id}= Generate Random Building Entity Id Set Test Variable ${entity_id} ${response}= Create Entity ... ${filename} diff --git a/TP/NGSI-LD/ContextInformation/Provision/EntityAttributes/PartialAttributeUpdate/012_01.robot b/TP/NGSI-LD/ContextInformation/Provision/EntityAttributes/PartialAttributeUpdate/012_01.robot index 214864fb347329a65f01127138329b1d132758b1..cd86697d65b63638bf03172e0189e913cf24c531 100644 --- a/TP/NGSI-LD/ContextInformation/Provision/EntityAttributes/PartialAttributeUpdate/012_01.robot +++ b/TP/NGSI-LD/ContextInformation/Provision/EntityAttributes/PartialAttributeUpdate/012_01.robot @@ -1,8 +1,9 @@ *** Settings *** Documentation Check that one can perform a partial update on an entity attribute -Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationConsumption.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -12,9 +13,8 @@ Test Template Update Attributes *** Variables *** -${vehicle_id_prefix}= urn:ngsi-ld:Vehicle: -${filename}= vehicle-speed-two-datasetid.jsonld -${status_code}= 204 +${filename}= vehicle-speed-two-datasetid.jsonld +${status_code}= 204 *** Test Cases *** FRAGMENT_FILENAME ATTRIBUTE_ID EXPECTATION_FILENAME @@ -47,7 +47,7 @@ Update Attributes ... ignored_keys=${ignored_attributes} Initiate Test Case - ${entity_id}= Generate Random Entity Id ${vehicle_id_prefix} + ${entity_id}= Generate Random Vehicle Entity Id Set Test Variable ${entity_id} ${response}= Create Entity Selecting Content Type ... ${filename} diff --git a/TP/NGSI-LD/ContextInformation/Provision/EntityAttributes/PartialAttributeUpdate/012_02.robot b/TP/NGSI-LD/ContextInformation/Provision/EntityAttributes/PartialAttributeUpdate/012_02.robot index 5f830c2a14b291f3b4c3a0d9649335eee5322926..4b0993a3c9ab584f37135a4715184d30fdfc5ea1 100644 --- a/TP/NGSI-LD/ContextInformation/Provision/EntityAttributes/PartialAttributeUpdate/012_02.robot +++ b/TP/NGSI-LD/ContextInformation/Provision/EntityAttributes/PartialAttributeUpdate/012_02.robot @@ -1,6 +1,7 @@ *** Settings *** Documentation Check that one cannot perform a partial update on an entity attribute with invalid data +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -11,9 +12,8 @@ Test Template Update Attributes *** Variables *** -${vehicle_id_prefix}= urn:ngsi-ld:Vehicle: -${filename}= vehicle-two-datasetid-attributes.jsonld -${status_code}= 400 +${filename}= vehicle-two-datasetid-attributes.jsonld +${status_code}= 400 *** Test Cases *** ENTITY_ID ATTRIBUTE_ID FRAGMENT_FILENAME @@ -48,7 +48,7 @@ Update Attributes Check Response Body Containing ProblemDetails Element Containing Title Element ${response.json()} Setup Initial Entity - ${valid_entity_id}= Generate Random Entity Id ${vehicle_id_prefix} + ${valid_entity_id}= Generate Random Vehicle Entity Id Set Test Variable ${valid_entity_id} ${response}= Create Entity Selecting Content Type ... ${filename} diff --git a/TP/NGSI-LD/ContextInformation/Provision/EntityAttributes/PartialAttributeUpdate/012_03.robot b/TP/NGSI-LD/ContextInformation/Provision/EntityAttributes/PartialAttributeUpdate/012_03.robot index c6fbdec3565c767272a361167362ca4ba27a4d11..27b0743745eae3b07dc4c71c925622dc69e03c67 100644 --- a/TP/NGSI-LD/ContextInformation/Provision/EntityAttributes/PartialAttributeUpdate/012_03.robot +++ b/TP/NGSI-LD/ContextInformation/Provision/EntityAttributes/PartialAttributeUpdate/012_03.robot @@ -1,6 +1,7 @@ *** Settings *** Documentation Check that one cannot perform a partial update on an entity attribute if the entity id or attribute is not known to the system +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -11,10 +12,9 @@ Test Template Partial Update Attributes *** Variables *** -${vehicle_id_prefix}= urn:ngsi-ld:Vehicle: -${filename}= vehicle-speed-two-datasetid.jsonld -${status_code}= 404 -${default_attr_id}= speed +${filename}= vehicle-speed-two-datasetid.jsonld +${status_code}= 404 +${default_attr_id}= speed *** Test Cases *** ENTITY_ID ATTR_ID FRAGMENT_FILENAME @@ -45,9 +45,9 @@ Partial Update Attributes Check Response Body Containing ProblemDetails Element Containing Title Element ${response.json()} Create Initial Entity - ${valid_entity_id}= Generate Random Entity Id ${vehicle_id_prefix} + ${valid_entity_id}= Generate Random Vehicle Entity Id Set Test Variable ${valid_entity_id} - ${not_found_entity_id}= Generate Random Entity Id ${vehicle_id_prefix} + ${not_found_entity_id}= Generate Random Vehicle Entity Id Set Test Variable ${not_found_entity_id} ${response}= Create Entity Selecting Content Type ... ${filename} diff --git a/TP/NGSI-LD/ContextInformation/Provision/EntityAttributes/PartialAttributeUpdate/012_04.robot b/TP/NGSI-LD/ContextInformation/Provision/EntityAttributes/PartialAttributeUpdate/012_04.robot index 10948bc18e9a27656cdac66b55382ba4f5d54cef..ebbd6c4723862b3a44eef69d4fa9928d0814d59f 100644 --- a/TP/NGSI-LD/ContextInformation/Provision/EntityAttributes/PartialAttributeUpdate/012_04.robot +++ b/TP/NGSI-LD/ContextInformation/Provision/EntityAttributes/PartialAttributeUpdate/012_04.robot @@ -1,8 +1,9 @@ *** Settings *** Documentation Check that one can perform a partial update on a LanguageProperty property -Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationConsumption.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -12,9 +13,8 @@ Test Template Update Attributes *** Variables *** -${vehicle_id_prefix}= urn:ngsi-ld:Building: -${filename}= building-language-property-sub-property.jsonld -${status_code}= 204 +${filename}= building-language-property-sub-property.jsonld +${status_code}= 204 *** Test Cases *** FRAGMENT_FILENAME ATTRIBUTE_ID EXPECTATION_FILENAME @@ -42,7 +42,7 @@ Update Attributes Check Updated Resource Set To ${entity_expectation_payload} ${response1.json()} ${ignored_attributes} Initiate Test Case - ${entity_id}= Generate Random Entity Id ${vehicle_id_prefix} + ${entity_id}= Generate Random Vehicle Entity Id Set Test Variable ${entity_id} ${response}= Create Entity Selecting Content Type ... ${filename} diff --git a/TP/NGSI-LD/ContextInformation/Provision/EntityAttributes/PartialAttributeUpdate/012_05.robot b/TP/NGSI-LD/ContextInformation/Provision/EntityAttributes/PartialAttributeUpdate/012_05.robot index 48bd9fb88fbbef1f8d95a3716981731c69f20712..9779ba3a77f3fe84ecaf1680de3aa027f2fe4f9f 100644 --- a/TP/NGSI-LD/ContextInformation/Provision/EntityAttributes/PartialAttributeUpdate/012_05.robot +++ b/TP/NGSI-LD/ContextInformation/Provision/EntityAttributes/PartialAttributeUpdate/012_05.robot @@ -1,8 +1,9 @@ *** Settings *** Documentation Check that one can delete an attribute using NGSI-LD Null in an Partial Attribute Update operation -Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationConsumption.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -12,8 +13,7 @@ Test Template Update Attributes *** Variables *** -${vehicle_id_prefix}= urn:ngsi-ld:Vehicle: -${filename}= building-different-attributes-types.jsonld +${filename}= building-different-attributes-types.jsonld *** Test Cases *** STATUS_CODE ATTR_NAME FRAGMENT_FILENAME EXPECTATION_FILENAME @@ -59,7 +59,7 @@ Delete Initial Entity Delete Entity by Id ${entity_id} Setup Initial Entity - ${entity_id}= Generate Random Entity Id ${vehicle_id_prefix} + ${entity_id}= Generate Random Vehicle Entity Id Set Test Variable ${entity_id} ${response}= Create Entity Selecting Content Type ... ${filename} diff --git a/TP/NGSI-LD/ContextInformation/Provision/EntityAttributes/PartialAttributeUpdate/012_06.robot b/TP/NGSI-LD/ContextInformation/Provision/EntityAttributes/PartialAttributeUpdate/012_06.robot index 3f9beead5a4e28ff6e255bc9c62c827d46c77a52..30d494b2f261cf7009447f70289cc772d9be700a 100644 --- a/TP/NGSI-LD/ContextInformation/Provision/EntityAttributes/PartialAttributeUpdate/012_06.robot +++ b/TP/NGSI-LD/ContextInformation/Provision/EntityAttributes/PartialAttributeUpdate/012_06.robot @@ -1,8 +1,9 @@ *** Settings *** Documentation Check that one can delete a specific attribute instance using NGSI-LD Null in an Partial Attribute Update operation -Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationConsumption.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -12,8 +13,7 @@ Test Template Update Attributes *** Variables *** -${vehicle_id_prefix}= urn:ngsi-ld:Vehicle: -${filename}= building-different-attributes-instances-and-types.jsonld +${filename}= building-different-attributes-instances-and-types.jsonld *** Test Cases *** STATUS_CODE ATTR_NAME FRAGMENT_FILENAME EXPECTATION_FILENAME @@ -59,7 +59,7 @@ Delete Initial Entity Delete Entity by Id ${entity_id} Setup Initial Entity - ${entity_id}= Generate Random Entity Id ${vehicle_id_prefix} + ${entity_id}= Generate Random Vehicle Entity Id Set Test Variable ${entity_id} ${response}= Create Entity Selecting Content Type ... ${filename} diff --git a/TP/NGSI-LD/ContextInformation/Provision/EntityAttributes/PartialAttributeUpdate/012_07.robot b/TP/NGSI-LD/ContextInformation/Provision/EntityAttributes/PartialAttributeUpdate/012_07.robot index c2a477cbe8cba788518bd1ccb10faa19b718c60a..67074f83b4aecd06f27a814317032a8c856de37c 100644 --- a/TP/NGSI-LD/ContextInformation/Provision/EntityAttributes/PartialAttributeUpdate/012_07.robot +++ b/TP/NGSI-LD/ContextInformation/Provision/EntityAttributes/PartialAttributeUpdate/012_07.robot @@ -1,8 +1,9 @@ *** Settings *** Documentation Check that one can delete the default attribute instance using NGSI-LD Null in an Partial Attribute Update operation -Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationConsumption.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -12,8 +13,7 @@ Test Template Update Attributes *** Variables *** -${vehicle_id_prefix}= urn:ngsi-ld:Vehicle: -${filename}= building-different-default-attributes-instances-and-types.jsonld +${filename}= building-different-default-attributes-instances-and-types.jsonld *** Test Cases *** STATUS_CODE ATTR_NAME FRAGMENT_FILENAME EXPECTATION_FILENAME @@ -59,7 +59,7 @@ Delete Initial Entity Delete Entity by Id ${entity_id} Setup Initial Entity - ${entity_id}= Generate Random Entity Id ${vehicle_id_prefix} + ${entity_id}= Generate Random Vehicle Entity Id Set Test Variable ${entity_id} ${response}= Create Entity Selecting Content Type ... ${filename} diff --git a/TP/NGSI-LD/ContextInformation/Provision/EntityAttributes/ReplaceEntityAttribute/055_01.robot b/TP/NGSI-LD/ContextInformation/Provision/EntityAttributes/ReplaceEntityAttribute/055_01.robot index e438615e7fdf40a2bca6fbfcb52686a41312279f..f5a9724b79a6d24d208caa9ab6cb54b2b57a5872 100644 --- a/TP/NGSI-LD/ContextInformation/Provision/EntityAttributes/ReplaceEntityAttribute/055_01.robot +++ b/TP/NGSI-LD/ContextInformation/Provision/EntityAttributes/ReplaceEntityAttribute/055_01.robot @@ -1,8 +1,9 @@ *** Settings *** Documentation Check that one can replace an existing entity attribute and that its createdAt Temporal Property remains unchanged -Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationConsumption.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -12,7 +13,6 @@ Test Template Replace Entity Attribute *** Variables *** -${vehicle_id_prefix} urn:ngsi-ld:Vehicle: ${entity_filename} vehicle-speed-multi-instances.jsonld @@ -55,7 +55,7 @@ Replace Entity Attribute ... response_body=${response1.json()} Setup Initial Entity - ${entity_id}= Generate Random Entity Id ${vehicle_id_prefix} + ${entity_id}= Generate Random Vehicle Entity Id Set Test Variable ${entity_id} ${response}= Create Entity Selecting Content Type ... ${entity_filename} diff --git a/TP/NGSI-LD/ContextInformation/Provision/EntityAttributes/ReplaceEntityAttribute/055_02.robot b/TP/NGSI-LD/ContextInformation/Provision/EntityAttributes/ReplaceEntityAttribute/055_02.robot index ac80245a6e28cf82163246a4bbdd5de13ca22c01..5b4ae8915f2c442c0ff8982a572182074df584df 100644 --- a/TP/NGSI-LD/ContextInformation/Provision/EntityAttributes/ReplaceEntityAttribute/055_02.robot +++ b/TP/NGSI-LD/ContextInformation/Provision/EntityAttributes/ReplaceEntityAttribute/055_02.robot @@ -1,8 +1,9 @@ *** Settings *** Documentation Check that one can replace an existing multi-instance entity attribute and that its createdAt Temporal Property remains unchanged -Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationConsumption.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -12,7 +13,6 @@ Test Template Replace Multi Instance Entity Attribute *** Variables *** -${vehicle_id_prefix} urn:ngsi-ld:Vehicle: ${entity_filename} vehicle-speed-multi-instances.jsonld @@ -55,7 +55,7 @@ Replace Multi Instance Entity Attribute ... response_body=${response1.json()} Setup Initial Entity - ${entity_id}= Generate Random Entity Id ${vehicle_id_prefix} + ${entity_id}= Generate Random Vehicle Entity Id Set Test Variable ${entity_id} ${response}= Create Entity Selecting Content Type ... ${entity_filename} diff --git a/TP/NGSI-LD/ContextInformation/Provision/EntityAttributes/ReplaceEntityAttribute/055_03.robot b/TP/NGSI-LD/ContextInformation/Provision/EntityAttributes/ReplaceEntityAttribute/055_03.robot index 31938756d7a4d424f3ad4a5d16e95c0570b89d5d..3a486586055157d67a8a35dbe4643f24901532d6 100644 --- a/TP/NGSI-LD/ContextInformation/Provision/EntityAttributes/ReplaceEntityAttribute/055_03.robot +++ b/TP/NGSI-LD/ContextInformation/Provision/EntityAttributes/ReplaceEntityAttribute/055_03.robot @@ -1,8 +1,9 @@ *** Settings *** Documentation Check that the correct error type is returned when replacing an attribute with faulty data -Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationConsumption.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -12,7 +13,6 @@ Test Template Replace Entity Attribute With Faulty Data *** Variables *** -${vehicle_id_prefix} urn:ngsi-ld:Vehicle: ${entity_filename} vehicle-speed-multi-instances.jsonld @@ -50,7 +50,7 @@ Replace Entity Attribute With Faulty Data Check Response Status Code ${expected_status_code} ${response.status_code} Setup Initial Entity - ${entity_id}= Generate Random Entity Id ${vehicle_id_prefix} + ${entity_id}= Generate Random Vehicle Entity Id Set Test Variable ${entity_id} ${response}= Create Entity Selecting Content Type ... ${entity_filename} diff --git a/TP/NGSI-LD/ContextInformation/Provision/EntityAttributes/UpdateEntityAttributes/011_01.robot b/TP/NGSI-LD/ContextInformation/Provision/EntityAttributes/UpdateEntityAttributes/011_01.robot index 25df88271d97f66bf8525d02df1176dee75042b8..c7851b32f7766e232ea1af399e55cbbe9a475c23 100644 --- a/TP/NGSI-LD/ContextInformation/Provision/EntityAttributes/UpdateEntityAttributes/011_01.robot +++ b/TP/NGSI-LD/ContextInformation/Provision/EntityAttributes/UpdateEntityAttributes/011_01.robot @@ -1,8 +1,9 @@ *** Settings *** Documentation Check that one can update entity attributes -Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationConsumption.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -12,8 +13,7 @@ Test Template Update Attributes *** Variables *** -${vehicle_id_prefix}= urn:ngsi-ld:Vehicle: -${filename}= vehicle-two-datasetid-attributes.jsonld +${filename}= vehicle-two-datasetid-attributes.jsonld *** Test Cases *** STATUS_CODE FRAGMENT_FILENAME EXPECTATION_FILENAME @@ -55,7 +55,7 @@ Delete Initial Entities Delete Entity by Id ${entity_id} Initialize Test - ${entity_id}= Generate Random Entity Id ${vehicle_id_prefix} + ${entity_id}= Generate Random Vehicle Entity Id Set Test Variable ${entity_id} ${response}= Create Entity Selecting Content Type ... ${filename} diff --git a/TP/NGSI-LD/ContextInformation/Provision/EntityAttributes/UpdateEntityAttributes/011_02.robot b/TP/NGSI-LD/ContextInformation/Provision/EntityAttributes/UpdateEntityAttributes/011_02.robot index 57b5ba0cf48280ea53b20045fae60e95badd978a..2f591cda15feda4282d62471a2bdc343a5f37f24 100644 --- a/TP/NGSI-LD/ContextInformation/Provision/EntityAttributes/UpdateEntityAttributes/011_02.robot +++ b/TP/NGSI-LD/ContextInformation/Provision/EntityAttributes/UpdateEntityAttributes/011_02.robot @@ -1,6 +1,7 @@ *** Settings *** Documentation Check that one cannot update entity attributes with invalid/missing id or invalid request body +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -10,10 +11,6 @@ Test Teardown Delete Entity Test Template Update Attributes -*** Variables *** -${vehicle_id_prefix}= urn:ngsi-ld:Vehicle: - - *** Test Cases *** ENTITY_INVALID_ID FRAGMENT_FILENAME 011_02_01 Update an attribute if the Entity Id is not present ${EMPTY} vehicle-speed-two-datasetid-01-fragment.jsonld @@ -34,7 +31,7 @@ Update Attributes Check Response Body Containing ProblemDetails Element Containing Title Element ${response.json()} Initialize Environment - ${entity_id}= Generate Random Entity Id ${vehicle_id_prefix} + ${entity_id}= Generate Random Vehicle Entity Id Set Test Variable ${entity_id} ${response}= Create Entity Selecting Content Type ... vehicle-two-datasetid-attributes.jsonld diff --git a/TP/NGSI-LD/ContextInformation/Provision/EntityAttributes/UpdateEntityAttributes/011_03.robot b/TP/NGSI-LD/ContextInformation/Provision/EntityAttributes/UpdateEntityAttributes/011_03.robot index 3e8250998399c9d05985f895e29c10d9e95b86f6..eea13c066271e8ef0c810e8883b7b9f9f5b9c50f 100644 --- a/TP/NGSI-LD/ContextInformation/Provision/EntityAttributes/UpdateEntityAttributes/011_03.robot +++ b/TP/NGSI-LD/ContextInformation/Provision/EntityAttributes/UpdateEntityAttributes/011_03.robot @@ -1,6 +1,7 @@ *** Settings *** Documentation Check that one cannot update entity attributes if the entity id or attributes are not known to the system +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -9,7 +10,6 @@ Suite Teardown Delete Initial Entities *** Variables *** -${vehicle_id_prefix}= urn:ngsi-ld:Vehicle: ${fragment_filename}= vehicle-speed-two-datasetid-01-fragment.jsonld @@ -17,7 +17,7 @@ ${fragment_filename}= vehicle-speed-two-datasetid-01-fragment.jsonld 011_03_01 Update entity attributes when the entity id is not known to the system [Documentation] Check that one cannot update entity attributes if the entity id or attributes are not known to the system [Tags] ea-update 5_6_2 - ${entity_id}= Generate Random Entity Id ${vehicle_id_prefix} + ${entity_id}= Generate Random Vehicle Entity Id Set Suite Variable ${entity_id} ${response}= Update Entity Attributes ${entity_id} ${fragment_filename} ${CONTENT_TYPE_LD_JSON} Check Response Status Code 404 ${response.status_code} diff --git a/TP/NGSI-LD/ContextInformation/Provision/EntityAttributes/UpdateEntityAttributes/011_04.robot b/TP/NGSI-LD/ContextInformation/Provision/EntityAttributes/UpdateEntityAttributes/011_04.robot index b47bf2354f8cae5eeb31ef70022314affaf316b1..dd5480038136f3b4fa642927b83b659905f601fa 100644 --- a/TP/NGSI-LD/ContextInformation/Provision/EntityAttributes/UpdateEntityAttributes/011_04.robot +++ b/TP/NGSI-LD/ContextInformation/Provision/EntityAttributes/UpdateEntityAttributes/011_04.robot @@ -1,6 +1,7 @@ *** Settings *** Documentation Check that one cannot update entity attributes with invalid request body +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -10,8 +11,7 @@ Test Template Update entity attributes with invalid entity fragments *** Variables *** -${vehicle_id_prefix}= urn:ngsi-ld:Vehicle: -${filename}= vehicle-speed-two-datasetid.jsonld +${filename}= vehicle-speed-two-datasetid.jsonld *** Test Cases *** @@ -35,7 +35,7 @@ Update entity attributes with invalid entity fragments Initialize Environment [Arguments] ${filename} - ${entity_id}= Generate Random Entity Id ${vehicle_id_prefix} + ${entity_id}= Generate Random Vehicle Entity Id Set Test Variable ${entity_id} ${response}= Create Entity Selecting Content Type ... ${filename} diff --git a/TP/NGSI-LD/ContextInformation/Provision/EntityAttributes/UpdateEntityAttributes/011_05.robot b/TP/NGSI-LD/ContextInformation/Provision/EntityAttributes/UpdateEntityAttributes/011_05.robot index 379ebefe03d2d6f64d2da051ba4548fe9c23e64f..b26ae606514f362f46a3921788b9e888c1fa5198 100644 --- a/TP/NGSI-LD/ContextInformation/Provision/EntityAttributes/UpdateEntityAttributes/011_05.robot +++ b/TP/NGSI-LD/ContextInformation/Provision/EntityAttributes/UpdateEntityAttributes/011_05.robot @@ -1,8 +1,9 @@ *** Settings *** Documentation Check that one can update a scope in an entity -Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationConsumption.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -10,7 +11,6 @@ Test Teardown Delete Initial Entity *** Variables *** -${vehicle_id_prefix}= urn:ngsi-ld:Vehicle: ${scope_fragment_filename}= one-scope-fragment.json @@ -53,7 +53,7 @@ ${scope_fragment_filename}= one-scope-fragment.json *** Keywords *** Create Initial Entity [Arguments] ${filename} - ${entity_id}= Generate Random Entity Id ${vehicle_id_prefix} + ${entity_id}= Generate Random Vehicle Entity Id Set Test Variable ${entity_id} ${response}= Create Entity Selecting Content Type ... ${filename} diff --git a/TP/NGSI-LD/ContextInformation/Provision/EntityAttributes/UpdateEntityAttributes/011_06.robot b/TP/NGSI-LD/ContextInformation/Provision/EntityAttributes/UpdateEntityAttributes/011_06.robot index 817c4574f53eaececc74de0402aeea849159819b..27838eeb1388a473a06a116d1534f33c434c51ef 100644 --- a/TP/NGSI-LD/ContextInformation/Provision/EntityAttributes/UpdateEntityAttributes/011_06.robot +++ b/TP/NGSI-LD/ContextInformation/Provision/EntityAttributes/UpdateEntityAttributes/011_06.robot @@ -1,8 +1,9 @@ *** Settings *** Documentation Check that you can update the types on an entity -Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationConsumption.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -12,8 +13,7 @@ Test Template Append Types to an Entity *** Variables *** -${vehicle_id_prefix}= urn:ngsi-ld:Vehicle: -${entity_filename}= building-minimal.json +${entity_filename}= building-minimal.json *** Test Cases *** FRAGMENT_FILENAME EXPECTATION_FILENAME @@ -47,7 +47,7 @@ Append Types to an Entity Check Updated Resource Set To ${entity_expectation_payload} ${response.json()} Create Initial Entity - ${entity_id}= Generate Random Entity Id ${vehicle_id_prefix} + ${entity_id}= Generate Random Vehicle Entity Id Set Test Variable ${entity_id} ${response}= Create Entity Selecting Content Type ... ${entity_filename} diff --git a/TP/NGSI-LD/ContextInformation/Provision/EntityAttributes/UpdateEntityAttributes/011_07.robot b/TP/NGSI-LD/ContextInformation/Provision/EntityAttributes/UpdateEntityAttributes/011_07.robot index c38f31ee89061946bba1167070459a71ca05deb9..f4339e354a5bcb0e76bc222a836208370e7225ec 100644 --- a/TP/NGSI-LD/ContextInformation/Provision/EntityAttributes/UpdateEntityAttributes/011_07.robot +++ b/TP/NGSI-LD/ContextInformation/Provision/EntityAttributes/UpdateEntityAttributes/011_07.robot @@ -1,8 +1,9 @@ *** Settings *** Documentation Check that one can delete an attribute using NGSI-LD Null in an Update Attributes operation -Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationConsumption.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -12,8 +13,7 @@ Test Template Update Attributes *** Variables *** -${vehicle_id_prefix}= urn:ngsi-ld:Vehicle: -${filename}= building-different-attributes-types.jsonld +${filename}= building-different-attributes-types.jsonld *** Test Cases *** STATUS_CODE FRAGMENT_FILENAME EXPECTATION_FILENAME @@ -57,7 +57,7 @@ Delete Initial Entity Delete Entity by Id ${entity_id} Setup Initial Entity - ${entity_id}= Generate Random Entity Id ${vehicle_id_prefix} + ${entity_id}= Generate Random Vehicle Entity Id Set Test Variable ${entity_id} ${response}= Create Entity Selecting Content Type ... ${filename} diff --git a/TP/NGSI-LD/ContextInformation/Provision/EntityAttributes/UpdateEntityAttributes/011_08.robot b/TP/NGSI-LD/ContextInformation/Provision/EntityAttributes/UpdateEntityAttributes/011_08.robot index a170a794bf25cce73d5d8a5ff74d0fbcecf18176..f0b4617526d322ed2bdbc282d4256d505e90c95e 100644 --- a/TP/NGSI-LD/ContextInformation/Provision/EntityAttributes/UpdateEntityAttributes/011_08.robot +++ b/TP/NGSI-LD/ContextInformation/Provision/EntityAttributes/UpdateEntityAttributes/011_08.robot @@ -1,8 +1,9 @@ *** Settings *** Documentation Check that one can delete a specific attribute instance using NGSI-LD Null in an Update Attributes operation -Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationConsumption.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -12,8 +13,7 @@ Test Template Update Attributes *** Variables *** -${vehicle_id_prefix}= urn:ngsi-ld:Vehicle: -${filename}= building-different-attributes-instances-and-types.jsonld +${filename}= building-different-attributes-instances-and-types.jsonld *** Test Cases *** STATUS_CODE FRAGMENT_FILENAME EXPECTATION_FILENAME @@ -57,7 +57,7 @@ Delete Initial Entity Delete Entity by Id ${entity_id} Setup Initial Entity - ${entity_id}= Generate Random Entity Id ${vehicle_id_prefix} + ${entity_id}= Generate Random Vehicle Entity Id Set Test Variable ${entity_id} ${response}= Create Entity Selecting Content Type ... ${filename} diff --git a/TP/NGSI-LD/ContextInformation/Provision/EntityAttributes/UpdateEntityAttributes/011_09.robot b/TP/NGSI-LD/ContextInformation/Provision/EntityAttributes/UpdateEntityAttributes/011_09.robot index f5dd1fb7c9b297feace1ef97feb2fdff84eb5902..7e8d48aa5b394a4979fd17e525aa3547b9addc32 100644 --- a/TP/NGSI-LD/ContextInformation/Provision/EntityAttributes/UpdateEntityAttributes/011_09.robot +++ b/TP/NGSI-LD/ContextInformation/Provision/EntityAttributes/UpdateEntityAttributes/011_09.robot @@ -1,8 +1,9 @@ *** Settings *** Documentation Check that one can delete the default attribute instance using NGSI-LD Null in an Update Attributes operation -Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationConsumption.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -12,8 +13,7 @@ Test Template Update Attributes *** Variables *** -${vehicle_id_prefix}= urn:ngsi-ld:Vehicle: -${filename}= building-different-default-attributes-instances-and-types.jsonld +${filename}= building-different-default-attributes-instances-and-types.jsonld *** Test Cases *** STATUS_CODE FRAGMENT_FILENAME EXPECTATION_FILENAME @@ -57,7 +57,7 @@ Delete Initial Entity Delete Entity by Id ${entity_id} Setup Initial Entity - ${entity_id}= Generate Random Entity Id ${vehicle_id_prefix} + ${entity_id}= Generate Random Vehicle Entity Id Set Test Variable ${entity_id} ${response}= Create Entity Selecting Content Type ... ${filename} diff --git a/TP/NGSI-LD/ContextInformation/Provision/TemporalEntity/CreateTemporalRepresentationOfEntity/007_01.robot b/TP/NGSI-LD/ContextInformation/Provision/TemporalEntity/CreateTemporalRepresentationOfEntity/007_01.robot index cc49b06f3113bb0932a111a977c8b0f335815935..2e30ee5f995eae4a3f725a7782dc11c33df4c4e5 100644 --- a/TP/NGSI-LD/ContextInformation/Provision/TemporalEntity/CreateTemporalRepresentationOfEntity/007_01.robot +++ b/TP/NGSI-LD/ContextInformation/Provision/TemporalEntity/CreateTemporalRepresentationOfEntity/007_01.robot @@ -1,8 +1,9 @@ *** Settings *** Documentation Check that one can create a temporal representation of an entity -Resource ${EXECDIR}/resources/ApiUtils/TemporalContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/TemporalContextInformationConsumption.resource +Resource ${EXECDIR}/resources/ApiUtils/TemporalContextInformationProvision.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -10,10 +11,6 @@ Test Teardown Delete Temporal Entity Test Template Create Temporal Entity -*** Variables *** -${vehicle_id_prefix}= urn:ngsi-ld:Vehicle: - - *** Test Cases *** FILENAME EXPECTATION_FILENAME CONTENT_TYPE 007_01_01 Create a temporal representation of an entity vehicle-create-temporal-representation.jsonld vehicle-temporal-representation-create.jsonld application/ld+json @@ -26,7 +23,7 @@ Create Temporal Entity [Documentation] Check that one can create a temporal representation of an entity [Tags] te-create 5_6_11 [Arguments] ${filename} ${expectation_filename} ${content_type} - ${temporal_entity_representation_id}= Generate Random Entity Id ${vehicle_id_prefix} + ${temporal_entity_representation_id}= Generate Random Vehicle Entity Id Set Test Variable ${temporal_entity_representation_id} ${response}= Create Or Update Temporal Representation Of Entity Selecting Content Type diff --git a/TP/NGSI-LD/ContextInformation/Provision/TemporalEntity/DeleteTemporalRepresentationOfEntity/009_01.robot b/TP/NGSI-LD/ContextInformation/Provision/TemporalEntity/DeleteTemporalRepresentationOfEntity/009_01.robot index b101168ecf6ba55525601fea7ff9641ca228e29d..2cb8ededc6e045a2faf6dbd0c610123f97fdb555 100644 --- a/TP/NGSI-LD/ContextInformation/Provision/TemporalEntity/DeleteTemporalRepresentationOfEntity/009_01.robot +++ b/TP/NGSI-LD/ContextInformation/Provision/TemporalEntity/DeleteTemporalRepresentationOfEntity/009_01.robot @@ -1,8 +1,9 @@ *** Settings *** Documentation Check that one can delete a temporal representation of an entity with simple temporal properties -Resource ${EXECDIR}/resources/ApiUtils/TemporalContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/TemporalContextInformationConsumption.resource +Resource ${EXECDIR}/resources/ApiUtils/TemporalContextInformationProvision.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -10,8 +11,7 @@ Test Setup Create Initial Temporal Entity *** Variables *** -${vehicle_id_prefix}= urn:ngsi-ld:Vehicle: -${filename}= vehicle-temporal-representation.jsonld +${filename}= vehicle-temporal-representation.jsonld *** Test Cases *** @@ -29,7 +29,7 @@ ${filename}= vehicle-temporal-representation.jsonld *** Keywords *** Create Initial Temporal Entity - ${temporal_entity_representation_id}= Generate Random Entity Id ${vehicle_id_prefix} + ${temporal_entity_representation_id}= Generate Random Vehicle Entity Id Set Test Variable ${temporal_entity_representation_id} ${response}= Create Or Update Temporal Representation Of Entity Selecting Content Type ... temporal_entity_representation_id=${temporal_entity_representation_id} diff --git a/TP/NGSI-LD/ContextInformation/Provision/TemporalEntity/DeleteTemporalRepresentationOfEntity/009_02.robot b/TP/NGSI-LD/ContextInformation/Provision/TemporalEntity/DeleteTemporalRepresentationOfEntity/009_02.robot index 2eb55336ca404dc8ecdd17a897758c750642f8ad..16b5ede7b925f4d9b4f4140a3b93fb256eea9845 100644 --- a/TP/NGSI-LD/ContextInformation/Provision/TemporalEntity/DeleteTemporalRepresentationOfEntity/009_02.robot +++ b/TP/NGSI-LD/ContextInformation/Provision/TemporalEntity/DeleteTemporalRepresentationOfEntity/009_02.robot @@ -8,10 +8,6 @@ Resource ${EXECDIR}/resources/JsonUtils.resource Test Template Delete Temporal Entity -*** Variables *** -${vehicle_id_prefix}= urn:ngsi-ld:Vehicle: - - *** Test Cases *** ID EXPECTED_STATUS_CODE PROBLEM_TYPE 009_02_01 Delete a temporal representation of an entity with an empty entity id ${EMPTY} 405 ${EMPTY} diff --git a/TP/NGSI-LD/ContextInformation/Provision/TemporalEntity/DeleteTemporalRepresentationOfEntity/009_03.robot b/TP/NGSI-LD/ContextInformation/Provision/TemporalEntity/DeleteTemporalRepresentationOfEntity/009_03.robot index 4f9b44bdc6af09acdfe75715ee8d19245fff3df7..589c0f506168b96d43da014bf73c4cf7fb21394c 100644 --- a/TP/NGSI-LD/ContextInformation/Provision/TemporalEntity/DeleteTemporalRepresentationOfEntity/009_03.robot +++ b/TP/NGSI-LD/ContextInformation/Provision/TemporalEntity/DeleteTemporalRepresentationOfEntity/009_03.robot @@ -1,21 +1,21 @@ *** Settings *** Documentation Check that an error is raised if one deletes a temporal entity with a non-existing/invalid EntityId +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/TemporalContextInformationProvision.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource *** Variables *** -${vehicle_id_prefix}= urn:ngsi-ld:Vehicle: -${status_code}= 404 +${status_code}= 404 *** Test Cases *** 009_03_01 Delete a temporal representation of an entity with an unknown entity id [Documentation] Check that an error is raised if one deletes a temporal entity with a non-existing entity id [Tags] te-delete 5_6_16 - ${temporal_entity_id}= Generate Random Entity Id ${vehicle_id_prefix} + ${temporal_entity_id}= Generate Random Vehicle Entity Id ${response}= Delete Temporal Representation Of Entity With Returning Response ${temporal_entity_id} Check Response Status Code ${status_code} ${response.status_code} Check Response Body Containing ProblemDetails Element Containing Type Element set to diff --git a/TP/NGSI-LD/ContextInformation/Provision/TemporalEntity/UpdateTemporalRepresentationOfEntity/008_01.robot b/TP/NGSI-LD/ContextInformation/Provision/TemporalEntity/UpdateTemporalRepresentationOfEntity/008_01.robot index baa4e31e53aebe9dd9db25a9e62d7a9fe904fd69..398c2e55198d2f0e8a04c6c8ef8a6df2e31eb883 100644 --- a/TP/NGSI-LD/ContextInformation/Provision/TemporalEntity/UpdateTemporalRepresentationOfEntity/008_01.robot +++ b/TP/NGSI-LD/ContextInformation/Provision/TemporalEntity/UpdateTemporalRepresentationOfEntity/008_01.robot @@ -1,8 +1,9 @@ *** Settings *** Documentation Check that one can update a temporal representation of an entity with simple temporal properties -Resource ${EXECDIR}/resources/ApiUtils/TemporalContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/TemporalContextInformationConsumption.resource +Resource ${EXECDIR}/resources/ApiUtils/TemporalContextInformationProvision.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -11,7 +12,6 @@ Suite Teardown Delete Temporal Entity *** Variables *** -${vehicle_id_prefix}= urn:ngsi-ld:Vehicle: ${filename}= vehicle-create-temporal-representation.jsonld ${update_filename}= vehicle-temporal-representation-update.jsonld ${expectation_filename}= vehicle-temporal-representation-update.jsonld @@ -43,7 +43,7 @@ ${expectation_filename}= vehicle-temporal-representation-update.jsonld *** Keywords *** Create Temporal Entity - ${temporal_entity_representation_id}= Generate Random Entity Id ${vehicle_id_prefix} + ${temporal_entity_representation_id}= Generate Random Vehicle Entity Id Set Suite Variable ${temporal_entity_representation_id} ${response}= Create Or Update Temporal Representation Of Entity Selecting Content Type ... temporal_entity_representation_id=${temporal_entity_representation_id} diff --git a/TP/NGSI-LD/ContextInformation/Provision/TemporalEntityAttributes/AddAttributes/014_01.robot b/TP/NGSI-LD/ContextInformation/Provision/TemporalEntityAttributes/AddAttributes/014_01.robot index 9e4d40470a5688d8baef6222c65a54d71c264cef..23a9b371cd4b8fcb5b3c1cb277f79eb39484ebd2 100644 --- a/TP/NGSI-LD/ContextInformation/Provision/TemporalEntityAttributes/AddAttributes/014_01.robot +++ b/TP/NGSI-LD/ContextInformation/Provision/TemporalEntityAttributes/AddAttributes/014_01.robot @@ -1,8 +1,9 @@ *** Settings *** Documentation Check that one can add a simple temporal attribute to a temporal representation of an entity -Resource ${EXECDIR}/resources/ApiUtils/TemporalContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/TemporalContextInformationConsumption.resource +Resource ${EXECDIR}/resources/ApiUtils/TemporalContextInformationProvision.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -11,7 +12,6 @@ Suite Teardown Delete Temporal Entity *** Variables *** -${vehicle_id_prefix}= urn:ngsi-ld:Vehicle: ${filename}= vehicle-temporal-representation.jsonld ${fragment_filename}= vehicle-temporal-representation-fragment.jsonld ${expectation_filename}= vehicle-temporal-representation-added-attribute.jsonld @@ -43,7 +43,7 @@ ${expectation_filename}= vehicle-temporal-representation-added-attribute.json *** Keywords *** Create Temporal Entity - ${temporal_entity_representation_id}= Generate Random Entity Id ${vehicle_id_prefix} + ${temporal_entity_representation_id}= Generate Random Vehicle Entity Id Set Suite Variable ${temporal_entity_representation_id} ${create_response}= Create Or Update Temporal Representation Of Entity Selecting Content Type ... temporal_entity_representation_id=${temporal_entity_representation_id} diff --git a/TP/NGSI-LD/ContextInformation/Provision/TemporalEntityAttributes/AddAttributes/014_02.robot b/TP/NGSI-LD/ContextInformation/Provision/TemporalEntityAttributes/AddAttributes/014_02.robot index 960b7db7f9ccb05529e6a9f5600a70dd0a76ff35..38fdb41288895661149dfcdbeb5e5639331c30ff 100644 --- a/TP/NGSI-LD/ContextInformation/Provision/TemporalEntityAttributes/AddAttributes/014_02.robot +++ b/TP/NGSI-LD/ContextInformation/Provision/TemporalEntityAttributes/AddAttributes/014_02.robot @@ -1,6 +1,7 @@ *** Settings *** Documentation Check that an error is raised if one adds an attribute to a temporal entity with invalid content +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/TemporalContextInformationProvision.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -11,7 +12,6 @@ Test Template Add Attribute To Temporal Entity *** Variables *** -${vehicle_id_prefix}= urn:ngsi-ld:Vehicle: ${filename}= vehicle-temporal-representation.jsonld ${fragment_filename}= vehicle-temporal-representation-fragment.jsonld ${status_code}= 400 @@ -33,7 +33,7 @@ Add Attribute To Temporal Entity Check Response Status Code ${status_code} ${response.status_code} Create Temporal Entity - ${temporal_entity_representation_id}= Generate Random Entity Id ${vehicle_id_prefix} + ${temporal_entity_representation_id}= Generate Random Vehicle Entity Id Set Test Variable ${temporal_entity_representation_id} ${create_response}= Create Or Update Temporal Representation Of Entity Selecting Content Type ... temporal_entity_representation_id=${temporal_entity_representation_id} diff --git a/TP/NGSI-LD/ContextInformation/Provision/TemporalEntityAttributes/AddAttributes/014_03.robot b/TP/NGSI-LD/ContextInformation/Provision/TemporalEntityAttributes/AddAttributes/014_03.robot index 46c42b3d286af54f4c9a1521ca4bcca049efd122..508c417ed1322c6a49f033d250c619c5d8ee23df 100644 --- a/TP/NGSI-LD/ContextInformation/Provision/TemporalEntityAttributes/AddAttributes/014_03.robot +++ b/TP/NGSI-LD/ContextInformation/Provision/TemporalEntityAttributes/AddAttributes/014_03.robot @@ -1,13 +1,13 @@ *** Settings *** Documentation Check that an error is raised if one adds an attribute to a non-existent entity +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/TemporalContextInformationProvision.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource *** Variables *** -${vehicle_id_prefix}= urn:ngsi-ld:Vehicle: ${filename}= vehicle-temporal-representation.jsonld ${fragment_filename}= vehicle-temporal-representation-fragment.jsonld ${status_code}= 404 @@ -17,7 +17,7 @@ ${status_code}= 404 014_03_01 Add Attribute To Temporal Entity [Documentation] Check that an error is raised if one adds an attribute to a non-existent entity [Tags] tea-append 5_6_12 - ${not_found_temporal_entity_representation_id}= Generate Random Entity Id ${vehicle_id_prefix} + ${not_found_temporal_entity_representation_id}= Generate Random Vehicle Entity Id ${response}= Append Attribute To Temporal Entity ... ${not_found_temporal_entity_representation_id} ... ${fragment_filename} diff --git a/TP/NGSI-LD/ContextInformation/Provision/TemporalEntityAttributes/AddAttributes/014_04.robot b/TP/NGSI-LD/ContextInformation/Provision/TemporalEntityAttributes/AddAttributes/014_04.robot index 24a19441a9df6c19f56b609e79eabbdbab6462ff..3c8d6f9614176b9854f1b5521da7ffc3210a375f 100644 --- a/TP/NGSI-LD/ContextInformation/Provision/TemporalEntityAttributes/AddAttributes/014_04.robot +++ b/TP/NGSI-LD/ContextInformation/Provision/TemporalEntityAttributes/AddAttributes/014_04.robot @@ -1,6 +1,7 @@ *** Settings *** Documentation Check that an error is raised if one adds a temporal entity attribute with empty/invalid content +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/TemporalContextInformationProvision.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -11,7 +12,6 @@ Test Template Add an Attribute To a Temporal Entity From File *** Variables *** -${vehicle_id_prefix}= urn:ngsi-ld:Vehicle: ${filename}= vehicle-temporal-representation.jsonld ${fragment_filename}= vehicle-temporal-representation-fragment.jsonld ${status_code}= 400 @@ -38,7 +38,7 @@ Add an Attribute To a Temporal Entity From File Check Response Body Title When Using Session Request ${response.json()} Initialize Test Case - ${temporal_entity_representation_id}= Generate Random Entity Id ${vehicle_id_prefix} + ${temporal_entity_representation_id}= Generate Random Vehicle Entity Id Set Test Variable ${temporal_entity_representation_id} ${response}= Create Or Update Temporal Representation Of Entity Selecting Content Type ... temporal_entity_representation_id=${temporal_entity_representation_id} diff --git a/TP/NGSI-LD/ContextInformation/Provision/TemporalEntityAttributes/DeleteAttribute/015_01.robot b/TP/NGSI-LD/ContextInformation/Provision/TemporalEntityAttributes/DeleteAttribute/015_01.robot index a3d0e607ac99f076c6cb12519da745518540d08c..aa1e6b1256e2cdfb28f59a9e567a978bf2ecc57f 100644 --- a/TP/NGSI-LD/ContextInformation/Provision/TemporalEntityAttributes/DeleteAttribute/015_01.robot +++ b/TP/NGSI-LD/ContextInformation/Provision/TemporalEntityAttributes/DeleteAttribute/015_01.robot @@ -1,8 +1,9 @@ *** Settings *** Documentation Check that one can delete an attribute of a temporal representation of an entity with simple temporal properties -Resource ${EXECDIR}/resources/ApiUtils/TemporalContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/TemporalContextInformationConsumption.resource +Resource ${EXECDIR}/resources/ApiUtils/TemporalContextInformationProvision.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -12,10 +13,9 @@ Test Template Delete Attribute From A Temporal Entity *** Variables *** -${vehicle_id_prefix}= urn:ngsi-ld:Vehicle: -${filename}= vehicle-temporal-representation.jsonld -${status_code}= 204 -${attribute_id}= fuelLevel +${filename}= vehicle-temporal-representation.jsonld +${status_code}= 204 +${attribute_id}= fuelLevel *** Test Cases *** DELETE_ALL DATASET_ID EXPECTATION_FILE @@ -55,7 +55,7 @@ Delete Attribute From A Temporal Entity ... ignored_keys=${ignored_attributes} Initialize Setup - ${temporal_entity_representation_id}= Generate Random Entity Id ${vehicle_id_prefix} + ${temporal_entity_representation_id}= Generate Random Vehicle Entity Id Set Test Variable ${temporal_entity_representation_id} ${response}= Create Or Update Temporal Representation Of Entity Selecting Content Type ... temporal_entity_representation_id=${temporal_entity_representation_id} diff --git a/TP/NGSI-LD/ContextInformation/Provision/TemporalEntityAttributes/DeleteAttribute/015_02.robot b/TP/NGSI-LD/ContextInformation/Provision/TemporalEntityAttributes/DeleteAttribute/015_02.robot index 861752c017ec69fc4cb908b1179659b60e96ec02..b89aa5219ea309651a711d0634262b943f44b9f2 100644 --- a/TP/NGSI-LD/ContextInformation/Provision/TemporalEntityAttributes/DeleteAttribute/015_02.robot +++ b/TP/NGSI-LD/ContextInformation/Provision/TemporalEntityAttributes/DeleteAttribute/015_02.robot @@ -1,6 +1,7 @@ *** Settings *** Documentation Check that an error is raised if one deletes an attribute to temporal entity with an unknown/invalid Entity/Attribute Id +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/TemporalContextInformationProvision.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -11,9 +12,8 @@ Test Template Delete attribute from temporal entity with unknow entity/att *** Variables *** -${vehicle_id_prefix}= urn:ngsi-ld:Vehicle: -${status_code}= 400 -${filename}= vehicle-temporal-representation.jsonld +${status_code}= 400 +${filename}= vehicle-temporal-representation.jsonld *** Test Cases *** ENTITY_ID ATTRIBUTE_ID @@ -43,7 +43,7 @@ Delete attribute from temporal entity with unknow entity/attribute id Check Response Body Containing ProblemDetails Element Containing Title Element ${response.json()} Create Temporal Entity - ${valid_temporal_entity_id}= Generate Random Entity Id ${vehicle_id_prefix} + ${valid_temporal_entity_id}= Generate Random Vehicle Entity Id ${response}= Create Or Update Temporal Representation Of Entity Selecting Content Type ... temporal_entity_representation_id=${valid_temporal_entity_id} ... filename=${filename} diff --git a/TP/NGSI-LD/ContextInformation/Provision/TemporalEntityAttributes/DeleteAttribute/015_03.robot b/TP/NGSI-LD/ContextInformation/Provision/TemporalEntityAttributes/DeleteAttribute/015_03.robot index 493bdae75ff1dc914449223cfda0cb1002bae94a..07af2a29be5b138193b9fa8ae907ea5d351815c8 100644 --- a/TP/NGSI-LD/ContextInformation/Provision/TemporalEntityAttributes/DeleteAttribute/015_03.robot +++ b/TP/NGSI-LD/ContextInformation/Provision/TemporalEntityAttributes/DeleteAttribute/015_03.robot @@ -1,6 +1,7 @@ *** Settings *** Documentation Check that an error is raised if one deletes a temporal entity with an unknown EntityId/Attribute Id +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/TemporalContextInformationProvision.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -11,9 +12,8 @@ Test Template Delete An Attribute *** Variables *** -${vehicle_id_prefix}= urn:ngsi-ld:Vehicle: -${filename}= vehicle-temporal-representation.jsonld -${status_code}= 404 +${filename}= vehicle-temporal-representation.jsonld +${status_code}= 404 *** Test Cases *** ENTITY_ID ATTRIBUTE_ID @@ -42,8 +42,8 @@ Delete An Attribute Check Response Body Containing ProblemDetails Element Containing Title Element ${response.json()} Create Id - ${valid_temporal_entity_id}= Generate Random Entity Id ${vehicle_id_prefix} - ${unknown_temporal_entity_id}= Generate Random Entity Id ${vehicle_id_prefix} + ${valid_temporal_entity_id}= Generate Random Vehicle Entity Id + ${unknown_temporal_entity_id}= Generate Random Vehicle Entity Id Set Test Variable ${valid_temporal_entity_id} Set Test Variable ${unknown_temporal_entity_id} ${response}= Create Or Update Temporal Representation Of Entity Selecting Content Type diff --git a/TP/NGSI-LD/ContextInformation/Provision/TemporalEntityAttributes/DeleteAttributeInstance/017_01.robot b/TP/NGSI-LD/ContextInformation/Provision/TemporalEntityAttributes/DeleteAttributeInstance/017_01.robot index 7c1a37943bd42b8b16ba13bb8e0c76984c6d267f..105ed76b7efe228750ce9983d29491e1c7b49d53 100644 --- a/TP/NGSI-LD/ContextInformation/Provision/TemporalEntityAttributes/DeleteAttributeInstance/017_01.robot +++ b/TP/NGSI-LD/ContextInformation/Provision/TemporalEntityAttributes/DeleteAttributeInstance/017_01.robot @@ -1,8 +1,9 @@ *** Settings *** Documentation Check that one can delete an attribute instance in temporal representation of an entity -Resource ${EXECDIR}/resources/ApiUtils/TemporalContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/TemporalContextInformationConsumption.resource +Resource ${EXECDIR}/resources/ApiUtils/TemporalContextInformationProvision.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -11,7 +12,6 @@ Suite Teardown Delete Temporal Entity *** Variables *** -${vehicle_id_prefix}= urn:ngsi-ld:Vehicle: ${filename}= vehicle-temporal-representation.jsonld ${attributeId}= speed ${expectation_filename}= vehicle-temporal-representation-delete-speed-instanceid.jsonld @@ -51,7 +51,7 @@ ${expectation_filename}= vehicle-temporal-representation-delete-speed-instanc *** Keywords *** Create Temporal Entity - ${temporal_entity_representation_id}= Generate Random Entity Id ${vehicle_id_prefix} + ${temporal_entity_representation_id}= Generate Random Vehicle Entity Id Set Suite Variable ${temporal_entity_representation_id} ${create_response}= Create Or Update Temporal Representation Of Entity Selecting Content Type ... temporal_entity_representation_id=${temporal_entity_representation_id} diff --git a/TP/NGSI-LD/ContextInformation/Provision/TemporalEntityAttributes/DeleteAttributeInstance/017_02.robot b/TP/NGSI-LD/ContextInformation/Provision/TemporalEntityAttributes/DeleteAttributeInstance/017_02.robot index 98adc7bcda0155c9afad1b9ebd8e04ea715d9a63..72e8ff57badab824b6f49e681cb6200a3de9b57f 100644 --- a/TP/NGSI-LD/ContextInformation/Provision/TemporalEntityAttributes/DeleteAttributeInstance/017_02.robot +++ b/TP/NGSI-LD/ContextInformation/Provision/TemporalEntityAttributes/DeleteAttributeInstance/017_02.robot @@ -1,8 +1,9 @@ *** Settings *** Documentation Check that one cannot delete an attribute instance in temporal representation of an entity if the EntityId/AttributeId/InstanceId is not right -Resource ${EXECDIR}/resources/ApiUtils/TemporalContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/TemporalContextInformationConsumption.resource +Resource ${EXECDIR}/resources/ApiUtils/TemporalContextInformationProvision.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -12,9 +13,8 @@ Test Template Delete attribute instance *** Variables *** -${vehicle_id_prefix}= urn:ngsi-ld:Vehicle: -${filename}= vehicle-temporal-representation.jsonld -${status_code}= 400 +${filename}= vehicle-temporal-representation.jsonld +${status_code}= 400 *** Test Cases *** TEMPORAL_ENTITY_ID ATTRIBUTE_ID INSTANCE_ID @@ -44,7 +44,7 @@ Delete attribute instance Check Response Status Code ${status_code} ${response.status_code} Create Temporal Entity - ${temporal_entity_representation_id}= Generate Random Entity Id ${vehicle_id_prefix} + ${temporal_entity_representation_id}= Generate Random Vehicle Entity Id Set Test Variable ${temporal_entity_representation_id} ${response}= Create Or Update Temporal Representation Of Entity Selecting Content Type ... temporal_entity_representation_id=${temporal_entity_representation_id} diff --git a/TP/NGSI-LD/ContextInformation/Provision/TemporalEntityAttributes/DeleteAttributeInstance/017_03.robot b/TP/NGSI-LD/ContextInformation/Provision/TemporalEntityAttributes/DeleteAttributeInstance/017_03.robot index dcdb0de065c8e3c9d6a62c93c5788f4f4b7ecbbe..638eb85a1dca19e803f5b3e5fe7eb47260c0a2ad 100644 --- a/TP/NGSI-LD/ContextInformation/Provision/TemporalEntityAttributes/DeleteAttributeInstance/017_03.robot +++ b/TP/NGSI-LD/ContextInformation/Provision/TemporalEntityAttributes/DeleteAttributeInstance/017_03.robot @@ -1,8 +1,9 @@ *** Settings *** Documentation Check that one cannot delete an attribute instance in temporal representation of an entity if the EntityId/AttributeId/InstanceId is not right -Resource ${EXECDIR}/resources/ApiUtils/TemporalContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/TemporalContextInformationConsumption.resource +Resource ${EXECDIR}/resources/ApiUtils/TemporalContextInformationProvision.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -12,9 +13,8 @@ Test Template Delete An Attribute Instance *** Variables *** -${vehicle_id_prefix}= urn:ngsi-ld:Vehicle: -${filename}= vehicle-temporal-representation.jsonld -${status_code}= 404 +${filename}= vehicle-temporal-representation.jsonld +${status_code}= 404 *** Test Cases *** TEMPORAL_ENTITY_ID ATTRIBUTE_ID INSTANCE_ID @@ -40,7 +40,7 @@ Delete An Attribute Instance Check Response Status Code ${status_code} ${response.status_code} Create Id - ${temporal_entity_representation_id}= Generate Random Entity Id ${vehicle_id_prefix} + ${temporal_entity_representation_id}= Generate Random Vehicle Entity Id Set Test Variable ${temporal_entity_representation_id} ${response}= Create Or Update Temporal Representation Of Entity Selecting Content Type ... temporal_entity_representation_id=${temporal_entity_representation_id} @@ -54,7 +54,7 @@ Create Id ... context=${ngsild_test_suite_context} ${valid_instanceId}= Set Variable ${response.json()['speed'][0]['instanceId']} Set Test Variable ${valid_instanceId} - ${unknown_temporal_entity_id}= Generate Random Entity Id ${vehicle_id_prefix} + ${unknown_temporal_entity_id}= Generate Random Vehicle Entity Id Set Test Variable ${unknown_temporal_entity_id} Delete Initial Temporal Representation Of Entity diff --git a/TP/NGSI-LD/ContextInformation/Provision/TemporalEntityAttributes/PartialUpdateAttributeInstance/016_01.robot b/TP/NGSI-LD/ContextInformation/Provision/TemporalEntityAttributes/PartialUpdateAttributeInstance/016_01.robot index 48cfee351296dd389f7b55547d12ab096697e0a5..d8c1ee172834b0a71e58b8d43c5968941a02bac3 100644 --- a/TP/NGSI-LD/ContextInformation/Provision/TemporalEntityAttributes/PartialUpdateAttributeInstance/016_01.robot +++ b/TP/NGSI-LD/ContextInformation/Provision/TemporalEntityAttributes/PartialUpdateAttributeInstance/016_01.robot @@ -1,8 +1,9 @@ *** Settings *** Documentation Check that one can modify an attribute instance in temporal representation of an entity -Resource ${EXECDIR}/resources/ApiUtils/TemporalContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/TemporalContextInformationConsumption.resource +Resource ${EXECDIR}/resources/ApiUtils/TemporalContextInformationProvision.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -11,7 +12,6 @@ Suite Teardown Delete Intitial Temporal Representation Of Entity *** Variables *** -${vehicle_id_prefix}= urn:ngsi-ld:Vehicle: ${filename}= vehicle-temporal-representation.jsonld ${fragment_filename}= vehicle-temporal-modify-attribute-instance-fragment.jsonld ${expectation_filename}= vehicle-temporal-representation-modify-attribute-instance.jsonld @@ -60,7 +60,7 @@ ${attributeId}= speed *** Keywords *** Create Temporal Entity - ${temporal_entity_representation_id}= Generate Random Entity Id ${vehicle_id_prefix} + ${temporal_entity_representation_id}= Generate Random Vehicle Entity Id Set Suite Variable ${temporal_entity_representation_id} ${response}= Create Or Update Temporal Representation Of Entity Selecting Content Type diff --git a/TP/NGSI-LD/ContextInformation/Provision/TemporalEntityAttributes/PartialUpdateAttributeInstance/016_02.robot b/TP/NGSI-LD/ContextInformation/Provision/TemporalEntityAttributes/PartialUpdateAttributeInstance/016_02.robot index b65a5f4b17d806d7fcc46c555a948f5c3b71efed..f0f3f85b6f8b66e1307dca8e591568d9de348167 100644 --- a/TP/NGSI-LD/ContextInformation/Provision/TemporalEntityAttributes/PartialUpdateAttributeInstance/016_02.robot +++ b/TP/NGSI-LD/ContextInformation/Provision/TemporalEntityAttributes/PartialUpdateAttributeInstance/016_02.robot @@ -1,8 +1,9 @@ *** Settings *** Documentation Check that one cannot modify an attribute instance in temporal representation of an entity if the EntityId/AttributeId/InstanceId is not right -Resource ${EXECDIR}/resources/ApiUtils/TemporalContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/TemporalContextInformationConsumption.resource +Resource ${EXECDIR}/resources/ApiUtils/TemporalContextInformationProvision.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -12,7 +13,6 @@ Test Template Modify Attribute Instance Temporal Entity *** Variables *** -${vehicle_id_prefix}= urn:ngsi-ld:Vehicle: ${filename}= vehicle-temporal-representation.jsonld ${fragment_filename}= vehicle-temporal-modify-attribute-instance-fragment.jsonld @@ -47,7 +47,7 @@ Modify Attribute Instance Temporal Entity Check Response Status Code ${expected_status_code} ${response.status_code} Create Id - ${temporal_entity_representation_id}= Generate Random Entity Id ${vehicle_id_prefix} + ${temporal_entity_representation_id}= Generate Random Vehicle Entity Id Set Test Variable ${temporal_entity_representation_id} ${response}= Create Or Update Temporal Representation Of Entity Selecting Content Type ... temporal_entity_representation_id=${temporal_entity_representation_id} diff --git a/TP/NGSI-LD/ContextInformation/Provision/TemporalEntityAttributes/PartialUpdateAttributeInstance/016_03.robot b/TP/NGSI-LD/ContextInformation/Provision/TemporalEntityAttributes/PartialUpdateAttributeInstance/016_03.robot index 3b2a8633c16b9beda1b099a70cb51712e2a3f2ab..d134c5b0398c156a0aa31ef5eef90bcdeb9f1677 100644 --- a/TP/NGSI-LD/ContextInformation/Provision/TemporalEntityAttributes/PartialUpdateAttributeInstance/016_03.robot +++ b/TP/NGSI-LD/ContextInformation/Provision/TemporalEntityAttributes/PartialUpdateAttributeInstance/016_03.robot @@ -1,8 +1,9 @@ *** Settings *** Documentation Check that one cannot partially modify attribute instance in temporal representation of an entity if the EntityId/AttributeId/InstanceId is not found -Resource ${EXECDIR}/resources/ApiUtils/TemporalContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/TemporalContextInformationConsumption.resource +Resource ${EXECDIR}/resources/ApiUtils/TemporalContextInformationProvision.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -12,7 +13,6 @@ Test Template Modify Attribute Instance Temporal Entity *** Variables *** -${vehicle_id_prefix}= urn:ngsi-ld:Vehicle: ${filename}= vehicle-temporal-representation.jsonld ${fragment_filename}= vehicle-temporal-modify-attribute-instance-fragment.jsonld ${status_code}= 404 @@ -42,7 +42,7 @@ Modify Attribute Instance Temporal Entity Check Response Status Code ${status_code} ${response.status_code} Create Id - ${temporal_entity_representation_id}= Generate Random Entity Id ${vehicle_id_prefix} + ${temporal_entity_representation_id}= Generate Random Vehicle Entity Id Set Suite Variable ${temporal_entity_representation_id} ${response}= Create Or Update Temporal Representation Of Entity Selecting Content Type ... temporal_entity_representation_id=${temporal_entity_representation_id} @@ -56,7 +56,7 @@ Create Id ... context=${ngsild_test_suite_context} ${valid_instanceId}= Set Variable ${response.json()['speed'][0]['instanceId']} Set Test Variable ${valid_instanceId} - ${unknown_temporal_entity_id}= Generate Random Entity Id ${vehicle_id_prefix} + ${unknown_temporal_entity_id}= Generate Random Vehicle Entity Id Set Test Variable ${unknown_temporal_entity_id} Delete Temporal Entity diff --git a/TP/NGSI-LD/ContextInformation/Subscription/CreateSubscription/028_01.robot b/TP/NGSI-LD/ContextInformation/Subscription/CreateSubscription/028_01.robot index 8c618ad7276147abd7a2a39f5fc837f4df12389d..cb06d411ac491cf4b69293e9e65fbebc76c1819b 100644 --- a/TP/NGSI-LD/ContextInformation/Subscription/CreateSubscription/028_01.robot +++ b/TP/NGSI-LD/ContextInformation/Subscription/CreateSubscription/028_01.robot @@ -1,6 +1,7 @@ *** Settings *** Documentation Check that one can create a subscription +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationSubscription.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -9,7 +10,6 @@ Suite Teardown Delete Initial Subscriptions *** Variables *** -${subscription_id_prefix}= urn:ngsi-ld:Subscription: ${subscription_payload_file_path}= subscriptions/subscription.jsonld ${subscription_expectation_file_path}= subscriptions/expectations/subscription-028-01.jsonld @@ -18,7 +18,7 @@ ${subscription_expectation_file_path}= subscriptions/expectations/subscript 028_01_01 Create Subscription [Documentation] Check that one can create a subscription [Tags] sub-create 5_8_1 - ${subscription_id}= Generate Random Entity Id ${subscription_id_prefix} + ${subscription_id}= Generate Random Subscription Id Set Suite Variable ${subscription_id} ${response}= Create Subscription ... ${subscription_id} diff --git a/TP/NGSI-LD/ContextInformation/Subscription/CreateSubscription/028_04.robot b/TP/NGSI-LD/ContextInformation/Subscription/CreateSubscription/028_04.robot index dde6d4c44656014cc37449aee64fe35b0fcd734a..66106a66cfc31d83968e0770f05f4b08995d75e1 100644 --- a/TP/NGSI-LD/ContextInformation/Subscription/CreateSubscription/028_04.robot +++ b/TP/NGSI-LD/ContextInformation/Subscription/CreateSubscription/028_04.robot @@ -1,6 +1,7 @@ *** Settings *** Documentation Check that one cannot create a subscription with an existing id +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationSubscription.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -10,7 +11,6 @@ Suite Teardown Delete Initial Subscriptions *** Variables *** -${subscription_id_prefix}= urn:ngsi-ld:Subscription: ${subscription_payload_file_path}= subscriptions/subscription.jsonld @@ -32,7 +32,7 @@ ${subscription_payload_file_path}= subscriptions/subscription.jsonld *** Keywords *** Create Initial Subscription - ${subscription_id}= Generate Random Entity Id ${subscription_id_prefix} + ${subscription_id}= Generate Random Subscription Id Set Suite Variable ${subscription_id} ${initial_response}= Create Subscription ... ${subscription_id} diff --git a/TP/NGSI-LD/ContextInformation/Subscription/DeleteSubscription/032_03.robot b/TP/NGSI-LD/ContextInformation/Subscription/DeleteSubscription/032_03.robot index 066f7c38ecbf5ad1fcf815daa9fa25af93b2cbcf..a092939dc1a47aef711ebc6498583735d65bf140 100644 --- a/TP/NGSI-LD/ContextInformation/Subscription/DeleteSubscription/032_03.robot +++ b/TP/NGSI-LD/ContextInformation/Subscription/DeleteSubscription/032_03.robot @@ -1,6 +1,7 @@ *** Settings *** Documentation Check that one can delete a subscription +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationSubscription.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -9,7 +10,6 @@ Suite Setup Setup Initial Subscriptions *** Variables *** -${subscription_id_prefix}= urn:ngsi-ld:Subscription: ${subscription_payload_file_path}= subscriptions/subscription.jsonld @@ -26,7 +26,7 @@ ${subscription_payload_file_path}= subscriptions/subscription.jsonld *** Keywords *** Setup Initial Subscriptions - ${subscription_id}= Generate Random Entity Id ${subscription_id_prefix} + ${subscription_id}= Generate Random Subscription Id ${create_response}= Create Subscription ... ${subscription_id} ... ${subscription_payload_file_path} diff --git a/TP/NGSI-LD/ContextInformation/Subscription/QuerySubscriptions/031_01.robot b/TP/NGSI-LD/ContextInformation/Subscription/QuerySubscriptions/031_01.robot index 7e94cad0eeaa45ba4d7c19e276ba5ce4daa54fe9..d98e1f935bb48d231e6c0a4f1532367f74c1a951 100644 --- a/TP/NGSI-LD/ContextInformation/Subscription/QuerySubscriptions/031_01.robot +++ b/TP/NGSI-LD/ContextInformation/Subscription/QuerySubscriptions/031_01.robot @@ -1,6 +1,7 @@ *** Settings *** Documentation Check that one can query a list of subscriptions +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationSubscription.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -10,7 +11,6 @@ Suite Teardown Delete Initial Subscriptions *** Variables *** -${subscription_id_prefix}= urn:ngsi-ld:Subscription: ${first_subscription_payload_file_path}= subscriptions/subscription.jsonld ${second_subscription_payload_file_path}= subscriptions/subscription-watchedAttributes.jsonld ${third_subscription_payload_file_path}= subscriptions/subscription-inactive.jsonld @@ -35,21 +35,21 @@ ${expectation_file_path}= subscriptions/expectations/subsc *** Keywords *** Setup Initial Subscriptions - ${first_subscription_id}= Generate Random Entity Id ${subscription_id_prefix} + ${first_subscription_id}= Generate Random Subscription Id ${create_response1}= Create Subscription ... ${first_subscription_id} ... ${first_subscription_payload_file_path} ... ${CONTENT_TYPE_LD_JSON} Check Response Status Code 201 ${create_response1.status_code} Set Suite Variable ${first_subscription_id} - ${second_subscription_id}= Generate Random Entity Id ${subscription_id_prefix} + ${second_subscription_id}= Generate Random Subscription Id ${create_response2}= Create Subscription ... ${second_subscription_id} ... ${second_subscription_payload_file_path} ... ${CONTENT_TYPE_LD_JSON} Check Response Status Code 201 ${create_response2.status_code} Set Suite Variable ${second_subscription_id} - ${third_subscription_id}= Generate Random Entity Id ${subscription_id_prefix} + ${third_subscription_id}= Generate Random Subscription Id ${create_response3}= Create Subscription ... ${third_subscription_id} ... ${third_subscription_payload_file_path} diff --git a/TP/NGSI-LD/ContextInformation/Subscription/QuerySubscriptions/031_02.robot b/TP/NGSI-LD/ContextInformation/Subscription/QuerySubscriptions/031_02.robot index 0440eb19f70b30ed8fd38594898688bc6cea3d11..0747791018abd0a11803105fc951952cdcc6a850 100644 --- a/TP/NGSI-LD/ContextInformation/Subscription/QuerySubscriptions/031_02.robot +++ b/TP/NGSI-LD/ContextInformation/Subscription/QuerySubscriptions/031_02.robot @@ -1,6 +1,7 @@ *** Settings *** Documentation Check that one can query a list of subscriptions: Pagination logic shall be in place +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationSubscription.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -11,7 +12,6 @@ Test Template Query Subscriptions With Limit And Page Parameters *** Variables *** -${subscription_id_prefix}= urn:ngsi-ld:Subscription: ${first_subscription_payload_file_path}= subscriptions/subscription.jsonld ${second_subscription_payload_file_path}= subscriptions/subscription-watchedAttributes.jsonld ${third_subscription_payload_file_path}= subscriptions/subscription-inactive.jsonld @@ -46,21 +46,21 @@ Query Subscriptions With Limit And Page Parameters Check Pagination Prev And Next Headers ${prev_link} ${next_link} ${response.headers} Setup Initial Subscriptions - ${first_subscription_id}= Generate Random Entity Id ${subscription_id_prefix} + ${first_subscription_id}= Generate Random Subscription Id ${create_response1}= Create Subscription ... ${first_subscription_id} ... ${first_subscription_payload_file_path} ... ${CONTENT_TYPE_LD_JSON} Check Response Status Code 201 ${create_response1.status_code} Set Test Variable ${first_subscription_id} - ${second_subscription_id}= Generate Random Entity Id ${subscription_id_prefix} + ${second_subscription_id}= Generate Random Subscription Id ${create_response2}= Create Subscription ... ${second_subscription_id} ... ${second_subscription_payload_file_path} ... ${CONTENT_TYPE_LD_JSON} Check Response Status Code 201 ${create_response2.status_code} Set Test Variable ${second_subscription_id} - ${third_subscription_id}= Generate Random Entity Id ${subscription_id_prefix} + ${third_subscription_id}= Generate Random Subscription Id ${create_response3}= Create Subscription ... ${third_subscription_id} ... ${third_subscription_payload_file_path} diff --git a/TP/NGSI-LD/ContextInformation/Subscription/RetrieveSubscription/030_03.robot b/TP/NGSI-LD/ContextInformation/Subscription/RetrieveSubscription/030_03.robot index 69baa4d00be394a1f05b93f096b6223358fa89b1..ee2404b0ecbbbcea9db1501239e50a831178efb8 100644 --- a/TP/NGSI-LD/ContextInformation/Subscription/RetrieveSubscription/030_03.robot +++ b/TP/NGSI-LD/ContextInformation/Subscription/RetrieveSubscription/030_03.robot @@ -1,6 +1,7 @@ *** Settings *** Documentation Check that one can retrieve a subscription +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationSubscription.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -10,7 +11,6 @@ Suite Teardown Delete Initial Subscriptions *** Variables *** -${subscription_id_prefix}= urn:ngsi-ld:Subscription: ${subscription_payload_file_path}= subscriptions/subscription.jsonld ${expectation_file_path}= subscriptions/expectations/subscriptions-030-03.json @@ -31,7 +31,7 @@ ${expectation_file_path}= subscriptions/expectations/subscriptions *** Keywords *** Setup Initial Subscriptions - ${subscription_id}= Generate Random Entity Id ${subscription_id_prefix} + ${subscription_id}= Generate Random Subscription Id ${create_response}= Create Subscription ... ${subscription_id} ... ${subscription_payload_file_path} diff --git a/TP/NGSI-LD/ContextInformation/Subscription/SubscriptionNotificationBehaviour/046_01.robot b/TP/NGSI-LD/ContextInformation/Subscription/SubscriptionNotificationBehaviour/046_01.robot index 36af1c75d31fb72c06ad7d2585a4bb4d70d37b7c..aed10b6a2b234357f4c7b575c82361b4d0f20fae 100644 --- a/TP/NGSI-LD/ContextInformation/Subscription/SubscriptionNotificationBehaviour/046_01.robot +++ b/TP/NGSI-LD/ContextInformation/Subscription/SubscriptionNotificationBehaviour/046_01.robot @@ -1,8 +1,9 @@ *** Settings *** Documentation Check that a notification is only sent if and only if the status is active -Resource ${EXECDIR}/resources/ApiUtils/ContextInformationSubscription.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextInformationSubscription.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource Resource ${EXECDIR}/resources/NotificationUtils.resource @@ -12,9 +13,7 @@ Suite Teardown After Test *** Variables *** -${subscription_id_prefix}= urn:ngsi-ld:Subscription: ${subscription_payload_file_path}= subscriptions/subscription-building-entities-active.jsonld -${building_id_prefix}= urn:ngsi-ld:Building: ${entity_building_filepath}= building-simple-attributes.jsonld ${fragment_filename}= airQualityLevel-fragment.jsonld ${notification_server_send_url}= http://${notification_server_host}:${notification_server_port}/notify @@ -42,13 +41,13 @@ Before Test Setup Initial Subscriptions Add Initial Entity - ${entity_id}= Generate Random Entity Id ${building_id_prefix} + ${entity_id}= Generate Random Building Entity Id ${create_response}= Create Entity ${entity_building_filepath} ${entity_id} Check Response Status Code 201 ${create_response.status_code} Set Suite Variable ${entity_id} Setup Initial Subscriptions - ${subscription_id}= Generate Random Entity Id ${subscription_id_prefix} + ${subscription_id}= Generate Random Subscription Id ${subscription_payload}= Load Subscription Sample With Reachable Endpoint ... ${subscription_payload_file_path} ... ${subscription_id} diff --git a/TP/NGSI-LD/ContextInformation/Subscription/SubscriptionNotificationBehaviour/046_02.robot b/TP/NGSI-LD/ContextInformation/Subscription/SubscriptionNotificationBehaviour/046_02.robot index c14633af0cd3955ed2fdb9fb3a28eb80989c8b62..ace3e6f1a3e27066cf1d7f9a649fb3c6eb004738 100644 --- a/TP/NGSI-LD/ContextInformation/Subscription/SubscriptionNotificationBehaviour/046_02.robot +++ b/TP/NGSI-LD/ContextInformation/Subscription/SubscriptionNotificationBehaviour/046_02.robot @@ -1,8 +1,9 @@ *** Settings *** Documentation If a Subscription defines a timeInterval member, a Notification shall be sent periodically, when the time interval (in seconds) specified in such value field is reached, regardless of Attribute changes. -Resource ${EXECDIR}/resources/ApiUtils/ContextInformationSubscription.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextInformationSubscription.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource Resource ${EXECDIR}/resources/NotificationUtils.resource @@ -12,9 +13,7 @@ Suite Teardown After Test *** Variables *** -${subscription_id_prefix}= urn:ngsi-ld:Subscription: ${subscription_payload_file_path}= subscriptions/subscription-timeInterval.jsonld -${building_id_prefix}= urn:ngsi-ld:Building: ${notification_server_send_url}= http://${notification_server_host}:${notification_server_port}/notify ${entity_building_filepath}= building-simple-attributes.jsonld @@ -43,8 +42,8 @@ Before Test Start Local Server ${notification_server_host} ${notification_server_port} Setup Initial Subscriptions - ${subscription_id}= Generate Random Entity Id ${subscription_id_prefix} - ${entity_id}= Generate Random Entity Id ${building_id_prefix} + ${subscription_id}= Generate Random Subscription Id + ${entity_id}= Generate Random Building Entity Id ${subscription_payload}= Load Subscription Sample With Reachable Endpoint ... ${subscription_payload_file_path} ... ${subscription_id} diff --git a/TP/NGSI-LD/ContextInformation/Subscription/SubscriptionNotificationBehaviour/046_03.robot b/TP/NGSI-LD/ContextInformation/Subscription/SubscriptionNotificationBehaviour/046_03.robot index 7257da2b4c658ce49bdc03b57c09fc63b3b2613e..6237d17cd664e830cf305579992f7faa9509149d 100644 --- a/TP/NGSI-LD/ContextInformation/Subscription/SubscriptionNotificationBehaviour/046_03.robot +++ b/TP/NGSI-LD/ContextInformation/Subscription/SubscriptionNotificationBehaviour/046_03.robot @@ -1,8 +1,9 @@ *** Settings *** Documentation A notification with all subscribed Entities will be included if query or geoquery are not defined. -Resource ${EXECDIR}/resources/ApiUtils/ContextInformationSubscription.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextInformationSubscription.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource Resource ${EXECDIR}/resources/NotificationUtils.resource @@ -12,9 +13,7 @@ Suite Teardown After Test *** Variables *** -${subscription_id_prefix}= urn:ngsi-ld:Subscription: ${subscription_payload_file_path}= subscriptions/subscription-building-entities-default.jsonld -${building_id_prefix}= urn:ngsi-ld:Building: ${notification_server_send_url}= http://${notification_server_host}:${notification_server_port}/notify ${entity_building_filepath}= building-simple-attributes.jsonld ${fragment_filename}= airQualityLevel-fragment.jsonld @@ -43,8 +42,8 @@ Before Test Setup Initial Subscriptions Setup Initial Subscriptions - ${subscription_id}= Generate Random Entity Id ${subscription_id_prefix} - ${entity_id}= Generate Random Entity Id ${building_id_prefix} + ${subscription_id}= Generate Random Subscription Id + ${entity_id}= Generate Random Building Entity Id ${subscription_payload}= Load Subscription Sample With Reachable Endpoint ... ${subscription_payload_file_path} ... ${subscription_id} @@ -71,7 +70,7 @@ Delete Initial Subscriptions Delete Subscription ${subscription_id} Add Initial Entity - ${entity_id}= Generate Random Entity Id ${building_id_prefix} + ${entity_id}= Generate Random Building Entity Id Create Entity ${entity_building_filepath} ${entity_id} Set Suite Variable ${entity_id} diff --git a/TP/NGSI-LD/ContextInformation/Subscription/SubscriptionNotificationBehaviour/046_04.robot b/TP/NGSI-LD/ContextInformation/Subscription/SubscriptionNotificationBehaviour/046_04.robot index dfa3c812f09a182ed470ad25c1084d9fb3cb063d..3b2ab49434cb291ec2f79992cbc87ade9e16e0ba 100644 --- a/TP/NGSI-LD/ContextInformation/Subscription/SubscriptionNotificationBehaviour/046_04.robot +++ b/TP/NGSI-LD/ContextInformation/Subscription/SubscriptionNotificationBehaviour/046_04.robot @@ -1,8 +1,9 @@ *** Settings *** Documentation If a Subscription does not define a timeInterval member, the notification shall be sent whenever there is a change in the watched Attributes. The notification message shall include all the subscribed Entities that changed and that match (as mandated by clauses 4.9 and 4.10) the query and geoquery conditions -Resource ${EXECDIR}/resources/ApiUtils/ContextInformationSubscription.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextInformationSubscription.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource Resource ${EXECDIR}/resources/NotificationUtils.resource @@ -12,9 +13,7 @@ Suite Teardown After Test *** Variables *** -${subscription_id_prefix}= urn:ngsi-ld:Subscription: ${subscription_payload_file_path}= subscriptions/subscription-building-entities-active-watchedAttributes.jsonld -${building_id_prefix}= urn:ngsi-ld:Building: ${notification_server_send_url}= http://${notification_server_host}:${notification_server_port}/notify ${entity_building_filepath}= building-simple-attributes.jsonld ${fragment_filename}= airQualityLevel-fragment.jsonld @@ -42,8 +41,8 @@ Before Test Setup Initial Subscriptions Setup Initial Subscriptions - ${subscription_id}= Generate Random Entity Id ${subscription_id_prefix} - ${entity_id}= Generate Random Entity Id ${building_id_prefix} + ${subscription_id}= Generate Random Subscription Id + ${entity_id}= Generate Random Building Entity Id ${subscription_payload}= Load Subscription Sample With Reachable Endpoint ... ${subscription_payload_file_path} ... ${subscription_id} diff --git a/TP/NGSI-LD/ContextInformation/Subscription/SubscriptionNotificationBehaviour/046_05.robot b/TP/NGSI-LD/ContextInformation/Subscription/SubscriptionNotificationBehaviour/046_05.robot index 4ec55b206133f0b4b84964d58d5a37c6c48a1539..14b267ab2963970ad215230582a93f5a4b930516 100644 --- a/TP/NGSI-LD/ContextInformation/Subscription/SubscriptionNotificationBehaviour/046_05.robot +++ b/TP/NGSI-LD/ContextInformation/Subscription/SubscriptionNotificationBehaviour/046_05.robot @@ -1,8 +1,9 @@ *** Settings *** Documentation If a Subscription does not define a timeInterval member, the notification shall be sent whenever there is a change in the watched Attributes and the entity matches the q parameter. The notification message shall include all the subscribed Entities that changed and that match (as mandated by clauses 4.9 and 4.10) the query and geoquery conditions -Resource ${EXECDIR}/resources/ApiUtils/ContextInformationSubscription.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextInformationSubscription.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource Resource ${EXECDIR}/resources/NotificationUtils.resource @@ -12,9 +13,7 @@ Suite Teardown After Test *** Variables *** -${subscription_id_prefix}= urn:ngsi-ld:Subscription: ${subscription_payload_file_path}= subscriptions/subscription-building-entities-active-watchedAttributes-query.jsonld -${building_id_prefix}= urn:ngsi-ld:Building: ${notification_server_send_url}= http://${notification_server_host}:${notification_server_port}/notify ${entity_building_filepath}= building-simple-attributes.jsonld ${fragment_filename}= airQualityLevel-fragment.jsonld @@ -43,8 +42,8 @@ Before Test Setup Initial Subscriptions Setup Initial Subscriptions - ${subscription_id}= Generate Random Entity Id ${subscription_id_prefix} - ${entity_id}= Generate Random Entity Id ${building_id_prefix} + ${subscription_id}= Generate Random Subscription Id + ${entity_id}= Generate Random Building Entity Id ${subscription_payload}= Load Subscription Sample With Reachable Endpoint ... ${subscription_payload_file_path} ... ${subscription_id} diff --git a/TP/NGSI-LD/ContextInformation/Subscription/SubscriptionNotificationBehaviour/046_06.robot b/TP/NGSI-LD/ContextInformation/Subscription/SubscriptionNotificationBehaviour/046_06.robot index a5bc12c4ff5455fe91ba254b2adce1a153ae12e4..5f1e592ce7278b8bee7f0c6624d3229ec2ac1b40 100644 --- a/TP/NGSI-LD/ContextInformation/Subscription/SubscriptionNotificationBehaviour/046_06.robot +++ b/TP/NGSI-LD/ContextInformation/Subscription/SubscriptionNotificationBehaviour/046_06.robot @@ -1,8 +1,9 @@ *** Settings *** Documentation Check that a notification is sent when an entity is created and entityCreated notification trigger is configured -Resource ${EXECDIR}/resources/ApiUtils/ContextInformationSubscription.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextInformationSubscription.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource Resource ${EXECDIR}/resources/NotificationUtils.resource @@ -12,9 +13,7 @@ Suite Teardown Delete Server And Subscriptions *** Variables *** -${subscription_id_prefix}= urn:ngsi-ld:Subscription: ${subscription_payload_file_path}= subscriptions/subscription-building-entities-entityCreated.jsonld -${building_id_prefix}= urn:ngsi-ld:Building: ${building_filename}= building-location-attribute.jsonld ${notification_server_send_url}= http://${notification_server_host}:${notification_server_port}/notify @@ -23,7 +22,7 @@ ${notification_server_send_url}= http://${notification_server_host}:${not 046_06_01 Check that a notification is sent with all matching entities [Documentation] Check that a notification is sent when an entity is created and entityCreated notification trigger is configured [Tags] sub-notification 5_8_6 since_v1.6.1 - ${entity_id}= Generate Random Entity Id ${building_id_prefix} + ${entity_id}= Generate Random Building Entity Id Set Suite Variable ${entity_id} ${response}= Create Entity Selecting Content Type @@ -38,7 +37,7 @@ ${notification_server_send_url}= http://${notification_server_host}:${not *** Keywords *** Setup Server And Subscriptions - ${subscription_id}= Generate Random Entity Id ${subscription_id_prefix} + ${subscription_id}= Generate Random Subscription Id ${subscription_payload}= Load Subscription Sample With Reachable Endpoint ... ${subscription_payload_file_path} ... ${subscription_id} diff --git a/TP/NGSI-LD/ContextInformation/Subscription/SubscriptionNotificationBehaviour/046_07.robot b/TP/NGSI-LD/ContextInformation/Subscription/SubscriptionNotificationBehaviour/046_07.robot index a7f2bc3a553b3a0da76de23f76f419231353a646..467dd4eb3d5a5916567afc9f78bb3b5f3e9dd725 100644 --- a/TP/NGSI-LD/ContextInformation/Subscription/SubscriptionNotificationBehaviour/046_07.robot +++ b/TP/NGSI-LD/ContextInformation/Subscription/SubscriptionNotificationBehaviour/046_07.robot @@ -1,8 +1,9 @@ *** Settings *** Documentation Check that a notification is only sent if and only if the status is active -Resource ${EXECDIR}/resources/ApiUtils/ContextInformationSubscription.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextInformationSubscription.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource Resource ${EXECDIR}/resources/NotificationUtils.resource @@ -13,11 +14,9 @@ Test Teardown After Test *** Variables *** -${subscription_id_prefix} urn:ngsi-ld:Subscription: ${subscription_payload_file_path} subscriptions/subscription-building-entities-active.jsonld ${subscription_payload_file_path_notificationAttributes} subscriptions/subscription-building-entities-active-notificationAttributes.jsonld ${subscription_payload_file_path_default_context} subscriptions/subscription-building-entities-active-default-context.jsonld -${building_id_prefix} urn:ngsi-ld:Building: ${notification_server_send_url} http://${notification_server_host}:${notification_server_port}/notify ${entity_building_filepath} building-simple-attributes.jsonld ${fragment_filename} airQualityLevel-fragment.jsonld @@ -75,8 +74,8 @@ Before Suite Setup Initial Subscriptions [Arguments] ${subscription_payload_path} - ${subscription_id}= Generate Random Entity Id ${subscription_id_prefix} - ${entity_id}= Generate Random Entity Id ${building_id_prefix} + ${subscription_id}= Generate Random Subscription Id + ${entity_id}= Generate Random Building Entity Id ${subscription_payload}= Load Subscription Sample With Reachable Endpoint ... ${subscription_payload_path} ... ${subscription_id} diff --git a/TP/NGSI-LD/ContextInformation/Subscription/SubscriptionNotificationBehaviour/046_08.robot b/TP/NGSI-LD/ContextInformation/Subscription/SubscriptionNotificationBehaviour/046_08.robot index 65213d783e142dbd87a0bd4b4e5f256adfdaf992..34d82d9c5418777ff57bd0669e26583db925ea2d 100644 --- a/TP/NGSI-LD/ContextInformation/Subscription/SubscriptionNotificationBehaviour/046_08.robot +++ b/TP/NGSI-LD/ContextInformation/Subscription/SubscriptionNotificationBehaviour/046_08.robot @@ -1,8 +1,9 @@ *** Settings *** Documentation Check that a notification is only sent if and only if the status is active -Resource ${EXECDIR}/resources/ApiUtils/ContextInformationSubscription.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextInformationSubscription.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource Resource ${EXECDIR}/resources/NotificationUtils.resource @@ -14,9 +15,7 @@ Test Teardown After Test *** Variables *** -${subscription_id_prefix}= urn:ngsi-ld:Subscription: ${subscription_payload_file_path}= subscriptions/subscription-building-entities-active.jsonld -${building_id_prefix}= urn:ngsi-ld:Building: ${notification_server_send_url}= http://${notification_server_host}:${notification_server_port}/notify ${entity_building_filepath}= building-simple-attributes.jsonld ${fragment_filename}= airQualityLevel-fragment.jsonld @@ -63,8 +62,8 @@ Before Suite Setup Initial Subscriptions [Arguments] ${change_json} - ${subscription_id}= Generate Random Entity Id ${subscription_id_prefix} - ${entity_id}= Generate Random Entity Id ${building_id_prefix} + ${subscription_id}= Generate Random Subscription Id + ${entity_id}= Generate Random Building Entity Id ${subscription_payload}= Load Subscription Sample With Reachable Endpoint ... ${subscription_payload_file_path} ... ${subscription_id} diff --git a/TP/NGSI-LD/ContextInformation/Subscription/SubscriptionNotificationBehaviour/046_09.robot b/TP/NGSI-LD/ContextInformation/Subscription/SubscriptionNotificationBehaviour/046_09.robot index 3a5c11eaf8c13fdd8ca38a0189460e15683330b7..4f96957ec28213ef835d22b1456c229c2d7eed03 100644 --- a/TP/NGSI-LD/ContextInformation/Subscription/SubscriptionNotificationBehaviour/046_09.robot +++ b/TP/NGSI-LD/ContextInformation/Subscription/SubscriptionNotificationBehaviour/046_09.robot @@ -1,8 +1,9 @@ *** Settings *** Documentation A Notification shall be sent (as mandated by each concrete binding and including any optional endpoint.receiverInfo 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 -Resource ${EXECDIR}/resources/ApiUtils/ContextInformationSubscription.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextInformationSubscription.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource Resource ${EXECDIR}/resources/NotificationUtils.resource @@ -12,9 +13,7 @@ Suite Teardown After Test *** Variables *** -${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.jsonld ${fragment_filename} airQualityLevel-fragment.jsonld ${notification_server_send_url} http://${notification_server_host}:${notification_server_port}/notify @@ -37,8 +36,8 @@ Before Test Setup Initial Subscriptions Setup Initial Subscriptions - ${subscription_id}= Generate Random Entity Id ${subscription_id_prefix} - ${entity_id}= Generate Random Entity Id ${building_id_prefix} + ${subscription_id}= Generate Random Subscription Id + ${entity_id}= Generate Random Building Entity Id ${subscription_payload}= Load Subscription Sample With Reachable Endpoint ... ${subscription_payload_file_path} ... ${subscription_id} diff --git a/TP/NGSI-LD/ContextInformation/Subscription/SubscriptionNotificationBehaviour/046_10.robot b/TP/NGSI-LD/ContextInformation/Subscription/SubscriptionNotificationBehaviour/046_10.robot index 885ebb79ab36c6fa6f87f8b90fec9028e3a88582..940ca5b0823c74caba428e4af713a3575f7feb76 100644 --- a/TP/NGSI-LD/ContextInformation/Subscription/SubscriptionNotificationBehaviour/046_10.robot +++ b/TP/NGSI-LD/ContextInformation/Subscription/SubscriptionNotificationBehaviour/046_10.robot @@ -2,8 +2,8 @@ Documentation The Notification content shall be JSON by default. Resource ${EXECDIR}/resources/ApiUtils/Common.resource -Resource ${EXECDIR}/resources/ApiUtils/ContextInformationSubscription.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextInformationSubscription.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource Resource ${EXECDIR}/resources/NotificationUtils.resource @@ -13,9 +13,7 @@ Suite Teardown After Test *** Variables *** -${subscription_id_prefix} urn:ngsi-ld:Subscription: ${subscription_payload_file_path} subscriptions/subscription-building-entities-default.jsonld -${building_id_prefix} urn:ngsi-ld:Building: ${entity_building_filepath} building-simple-attributes.jsonld ${fragment_filename} airQualityLevel-fragment.jsonld ${notification_server_send_url} http://${notification_server_host}:${notification_server_port}/notify @@ -41,8 +39,8 @@ Before Test Setup Initial Subscriptions Setup Initial Subscriptions - ${subscription_id}= Generate Random Entity Id ${subscription_id_prefix} - ${entity_id}= Generate Random Entity Id ${building_id_prefix} + ${subscription_id}= Generate Random Subscription Id + ${entity_id}= Generate Random Building Entity Id ${subscription_payload}= Load Subscription Sample With Reachable Endpoint ... ${subscription_payload_file_path} ... ${subscription_id} diff --git a/TP/NGSI-LD/ContextInformation/Subscription/SubscriptionNotificationBehaviour/046_11.robot b/TP/NGSI-LD/ContextInformation/Subscription/SubscriptionNotificationBehaviour/046_11.robot index b036cf9493adbbb880e1996fb5ea5b6e3a87b92f..c8d2ad243a71f7006f518c717082389f69a3d336 100644 --- a/TP/NGSI-LD/ContextInformation/Subscription/SubscriptionNotificationBehaviour/046_11.robot +++ b/TP/NGSI-LD/ContextInformation/Subscription/SubscriptionNotificationBehaviour/046_11.robot @@ -1,8 +1,9 @@ *** Settings *** 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 -Resource ${EXECDIR}/resources/ApiUtils/ContextInformationSubscription.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextInformationSubscription.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource Resource ${EXECDIR}/resources/NotificationUtils.resource @@ -12,9 +13,7 @@ Suite Teardown After Test *** Variables *** -${subscription_id_prefix}= urn:ngsi-ld:Subscription: ${subscription_payload_file_path}= subscriptions/subscription-building-entities-active.jsonld -${building_id_prefix}= urn:ngsi-ld:Building: ${entity_building_filepath}= building-simple-attributes.jsonld ${fragment_filename}= airQualityLevel-fragment.jsonld ${notification_server_send_url}= http://${notification_server_host}:${notification_server_port}/notify @@ -48,7 +47,7 @@ Before Test Setup Initial Subscriptions Setup Initial Subscriptions - ${subscription_id}= Generate Random Entity Id ${subscription_id_prefix} + ${subscription_id}= Generate Random Subscription Id ${subscription_payload}= Load Subscription Sample With Reachable Endpoint ... ${subscription_payload_file_path} ... ${subscription_id} @@ -61,7 +60,7 @@ Setup Initial Subscriptions Set Suite Variable ${subscription_id} Add Initial Entity - ${entity_id}= Generate Random Entity Id ${building_id_prefix} + ${entity_id}= Generate Random Building Entity Id ${create_response}= Create Entity ${entity_building_filepath} ${entity_id} Check Response Status Code 201 ${create_response.status_code} Set Suite Variable ${entity_id} diff --git a/TP/NGSI-LD/ContextInformation/Subscription/SubscriptionNotificationBehaviour/046_12.robot b/TP/NGSI-LD/ContextInformation/Subscription/SubscriptionNotificationBehaviour/046_12.robot index d3569130d45e1d945b4a16628e40f9bc3bed6403..26b3e43f4a681d29763f7110483291079990ceba 100644 --- a/TP/NGSI-LD/ContextInformation/Subscription/SubscriptionNotificationBehaviour/046_12.robot +++ b/TP/NGSI-LD/ContextInformation/Subscription/SubscriptionNotificationBehaviour/046_12.robot @@ -1,8 +1,9 @@ *** Settings *** 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 -Resource ${EXECDIR}/resources/ApiUtils/ContextInformationSubscription.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextInformationSubscription.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource Resource ${EXECDIR}/resources/NotificationUtils.resource @@ -12,9 +13,7 @@ Suite Teardown After Test *** Variables *** -${subscription_id_prefix}= urn:ngsi-ld:Subscription: ${subscription_payload_file_path}= subscriptions/subscription-building-entities-active.jsonld -${building_id_prefix}= urn:ngsi-ld:Building: ${entity_building_filepath}= building-simple-attributes.jsonld ${fragment_filename}= airQualityLevel-fragment.jsonld ${notification_server_send_url}= http://${notification_server_host}:${notification_server_port}/notify @@ -56,13 +55,13 @@ Before Test Setup Initial Subscriptions Add Initial Entity - ${entity_id}= Generate Random Entity Id ${building_id_prefix} + ${entity_id}= Generate Random Building Entity Id ${create_response1}= Create Entity ${entity_building_filepath} ${entity_id} Check Response Status Code 201 ${create_response1.status_code} Set Suite Variable ${entity_id} Setup Initial Subscriptions - ${subscription_id}= Generate Random Entity Id ${subscription_id_prefix} + ${subscription_id}= Generate Random Subscription Id ${subscription_payload}= Load Subscription Sample With Reachable Endpoint ... ${subscription_payload_file_path} ... ${subscription_id} diff --git a/TP/NGSI-LD/ContextInformation/Subscription/SubscriptionNotificationBehaviour/046_13.robot b/TP/NGSI-LD/ContextInformation/Subscription/SubscriptionNotificationBehaviour/046_13.robot index 7f391cfd24099702f8cb6057aabde97b6dbc0518..d07ebf64ddc489f72dab6dc57514cf99fe290dbf 100644 --- a/TP/NGSI-LD/ContextInformation/Subscription/SubscriptionNotificationBehaviour/046_13.robot +++ b/TP/NGSI-LD/ContextInformation/Subscription/SubscriptionNotificationBehaviour/046_13.robot @@ -1,21 +1,20 @@ *** Settings *** Documentation If the response to the notification request is different than 200 OK then implementations shall: Update notification.lastFailure with a timestamp representing the current date and time, update notification.status to "failed" -Resource ${EXECDIR}/resources/ApiUtils/ContextInformationSubscription.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextInformationSubscription.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource -Resource ${EXECDIR}/resources/NotificationUtils.resource Resource ${EXECDIR}/resources/MockServerUtils.resource +Resource ${EXECDIR}/resources/NotificationUtils.resource Suite Setup Before Test Suite Teardown After Test *** Variables *** -${subscription_id_prefix}= urn:ngsi-ld:Subscription: ${subscription_payload_file_path}= subscriptions/subscription-building-entities-active.jsonld -${building_id_prefix}= urn:ngsi-ld:Building: ${entity_building_filepath}= building-simple-attributes.jsonld ${fragment_filename}= airQualityLevel-fragment.jsonld @@ -51,7 +50,7 @@ Before Test Add Initial Entity Setup Initial Subscription - ${subscription_id}= Generate Random Entity Id ${subscription_id_prefix} + ${subscription_id}= Generate Random Subscription Id ${create_response}= Create Subscription ... ${subscription_id} ... ${subscription_payload_file_path} @@ -60,7 +59,7 @@ Setup Initial Subscription Set Suite Variable ${subscription_id} Add Initial Entity - ${entity_id}= Generate Random Entity Id ${building_id_prefix} + ${entity_id}= Generate Random Building Entity Id ${create_response}= Create Entity ${entity_building_filepath} ${entity_id} Check Response Status Code 201 ${create_response.status_code} Set Suite Variable ${entity_id} diff --git a/TP/NGSI-LD/ContextInformation/Subscription/SubscriptionNotificationBehaviour/046_14.robot b/TP/NGSI-LD/ContextInformation/Subscription/SubscriptionNotificationBehaviour/046_14.robot index bd15846704f71099cce70ae22c5287228471609b..4f354b9e3660d47cb2550c661f14a18898229192 100644 --- a/TP/NGSI-LD/ContextInformation/Subscription/SubscriptionNotificationBehaviour/046_14.robot +++ b/TP/NGSI-LD/ContextInformation/Subscription/SubscriptionNotificationBehaviour/046_14.robot @@ -1,8 +1,9 @@ *** Settings *** Documentation The Notification content shall be JSON-LD when endpoint.accept is set to JSON-LD -Resource ${EXECDIR}/resources/ApiUtils/ContextInformationSubscription.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextInformationSubscription.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource Resource ${EXECDIR}/resources/NotificationUtils.resource @@ -12,9 +13,7 @@ Suite Teardown After Test *** Variables *** -${subscription_id_prefix} urn:ngsi-ld:Subscription: ${subscription_payload_file_path} subscriptions/subscription-building-entities-accept-jsonld.jsonld -${building_id_prefix} urn:ngsi-ld:Building: ${entity_building_filepath} building-simple-attributes.jsonld ${fragment_filename} airQualityLevel-fragment.jsonld ${notification_server_send_url} http://${notification_server_host}:${notification_server_port}/notify @@ -49,13 +48,13 @@ Before Test Sleep 1s Add Initial Entity - ${entity_id}= Generate Random Entity Id ${building_id_prefix} + ${entity_id}= Generate Random Building Entity Id ${create_response}= Create Entity ${entity_building_filepath} ${entity_id} Check Response Status Code 201 ${create_response.status_code} Set Suite Variable ${entity_id} Setup Initial Subscriptions - ${subscription_id}= Generate Random Entity Id ${subscription_id_prefix} + ${subscription_id}= Generate Random Subscription Id ${subscription_payload}= Load Subscription Sample With Reachable Endpoint ... ${subscription_payload_file_path} ... ${subscription_id} diff --git a/TP/NGSI-LD/ContextInformation/Subscription/SubscriptionNotificationBehaviour/046_15.robot b/TP/NGSI-LD/ContextInformation/Subscription/SubscriptionNotificationBehaviour/046_15.robot index 951aa319269ce296255ecc6578ee2d6c819ea5e1..6cc1d802383744bfad40c8d868322e9adee0da60 100644 --- a/TP/NGSI-LD/ContextInformation/Subscription/SubscriptionNotificationBehaviour/046_15.robot +++ b/TP/NGSI-LD/ContextInformation/Subscription/SubscriptionNotificationBehaviour/046_15.robot @@ -1,8 +1,9 @@ *** Settings *** Documentation If a Subscription defines a throttling member, a Notification shall not be sent if the throttling specified (in seconds) has not elapsed yet. -Resource ${EXECDIR}/resources/ApiUtils/ContextInformationSubscription.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextInformationSubscription.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource Resource ${EXECDIR}/resources/NotificationUtils.resource @@ -12,9 +13,7 @@ Suite Teardown After Test *** Variables *** -${subscription_id_prefix}= urn:ngsi-ld:Subscription: ${subscription_payload_file_path}= subscriptions/subscription-valid-throttling.jsonld -${building_id_prefix}= urn:ngsi-ld:Building: ${notification_server_send_url}= http://${notification_server_host}:${notification_server_port}/notify ${entity_building_filepath}= building-simple-attributes.jsonld ${fragment_filename}= airQualityLevel-fragment.jsonld @@ -40,8 +39,8 @@ Before Test Setup Initial Subscriptions Setup Initial Subscriptions - ${subscription_id}= Generate Random Entity Id ${subscription_id_prefix} - ${entity_id}= Generate Random Entity Id ${building_id_prefix} + ${subscription_id}= Generate Random Subscription Id + ${entity_id}= Generate Random Building Entity Id ${subscription_payload}= Load Subscription Sample With Reachable Endpoint ... ${subscription_payload_file_path} ... ${subscription_id} diff --git a/TP/NGSI-LD/ContextInformation/Subscription/SubscriptionNotificationBehaviour/046_16_01.robot b/TP/NGSI-LD/ContextInformation/Subscription/SubscriptionNotificationBehaviour/046_16_01.robot index 2ff7515ae6b39a7f5f7b8ae2ba525f4f57d4dc4d..c9d538cacf45556d1b4d728381fea0d638ab67c1 100644 --- a/TP/NGSI-LD/ContextInformation/Subscription/SubscriptionNotificationBehaviour/046_16_01.robot +++ b/TP/NGSI-LD/ContextInformation/Subscription/SubscriptionNotificationBehaviour/046_16_01.robot @@ -1,8 +1,9 @@ *** Settings *** Documentation If a subscription defines an entity type selection query, a notification shall be sent whenever an entity matches the query. -Resource ${EXECDIR}/resources/ApiUtils/ContextInformationSubscription.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextInformationSubscription.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource Resource ${EXECDIR}/resources/NotificationUtils.resource @@ -12,9 +13,7 @@ Suite Teardown After Test *** Variables *** -${subscription_id_prefix}= urn:ngsi-ld:Subscription: ${subscription_payload_file_path}= subscriptions/subscription-building-entities-type-selection.jsonld -${building_id_prefix}= urn:ngsi-ld:Building: ${notification_server_send_url}= http://${notification_server_host}:${notification_server_port}/notify ${entity_building_filepath}= building-simple-attributes.jsonld ${content_type}= application/ld+json @@ -25,7 +24,7 @@ ${content_type}= application/ld+json [Documentation] If a subscription defines an entity type selection query, a notification shall be sent whenever an entity matches the query. [Tags] sub-notification 5_8_6 since_v1.5.1 - ${entity_id}= Generate Random Entity Id ${building_id_prefix} + ${entity_id}= Generate Random Building Entity Id ${response}= Create Entity Selecting Content Type ... ${entity_building_filepath} ... ${entity_id} @@ -42,7 +41,7 @@ ${content_type}= application/ld+json *** Keywords *** Setup Initial Subscription - ${subscription_id}= Generate Random Entity Id ${subscription_id_prefix} + ${subscription_id}= Generate Random Subscription Id ${subscription_payload}= Load Subscription Sample With Reachable Endpoint ... ${subscription_payload_file_path} ... ${subscription_id} diff --git a/TP/NGSI-LD/ContextInformation/Subscription/SubscriptionNotificationBehaviour/046_16_02.robot b/TP/NGSI-LD/ContextInformation/Subscription/SubscriptionNotificationBehaviour/046_16_02.robot index d9b6f08db5062558fd33e67df8eb451cf39446a9..6598466e9d6e18d7a2bc19727c7043e220d6e170 100644 --- a/TP/NGSI-LD/ContextInformation/Subscription/SubscriptionNotificationBehaviour/046_16_02.robot +++ b/TP/NGSI-LD/ContextInformation/Subscription/SubscriptionNotificationBehaviour/046_16_02.robot @@ -1,8 +1,9 @@ *** Settings *** Documentation If a subscription defines an entity type selection query, a notification shall be sent whenever an entity matches the query. -Resource ${EXECDIR}/resources/ApiUtils/ContextInformationSubscription.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextInformationSubscription.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource Resource ${EXECDIR}/resources/NotificationUtils.resource @@ -12,9 +13,7 @@ Suite Teardown After Test *** Variables *** -${subscription_id_prefix}= urn:ngsi-ld:Subscription: ${subscription_payload_file_path}= subscriptions/subscription-building-entities-type-selection.jsonld -${vehicle_id_prefix}= urn:ngsi-ld:Vehicle: ${notification_server_send_url}= http://${notification_server_host}:${notification_server_port}/notify ${entity_vehicle_filepath}= vehicle-simple-attributes.jsonld ${content_type}= application/ld+json @@ -25,7 +24,7 @@ ${content_type}= application/ld+json [Documentation] If a subscription defines an entity type selection query, a notification shall not be sent if the entity type does not match the query [Tags] sub-notification 5_8_6 since_v1.5.1 - ${vehicle_id}= Generate Random Entity Id ${vehicle_id_prefix} + ${vehicle_id}= Generate Random Vehicle Entity Id ${response}= Create Entity Selecting Content Type ... ${entity_vehicle_filepath} ... ${vehicle_id} @@ -37,7 +36,7 @@ ${content_type}= application/ld+json *** Keywords *** Setup Initial Subscription - ${subscription_id}= Generate Random Entity Id ${subscription_id_prefix} + ${subscription_id}= Generate Random Subscription Id ${subscription_payload}= Load Subscription Sample With Reachable Endpoint ... ${subscription_payload_file_path} ... ${subscription_id} diff --git a/TP/NGSI-LD/ContextInformation/Subscription/SubscriptionNotificationBehaviour/046_17.robot b/TP/NGSI-LD/ContextInformation/Subscription/SubscriptionNotificationBehaviour/046_17.robot index faf298434bca3d8fac2088c0d72328f7a258c372..49e114a910e9bc2a5e623923ba655501823ec120 100644 --- a/TP/NGSI-LD/ContextInformation/Subscription/SubscriptionNotificationBehaviour/046_17.robot +++ b/TP/NGSI-LD/ContextInformation/Subscription/SubscriptionNotificationBehaviour/046_17.robot @@ -1,8 +1,9 @@ *** Settings *** Documentation The system generated attributes are included in the response payload body of a notification if sysAttrs parameter is set to true. -Resource ${EXECDIR}/resources/ApiUtils/ContextInformationSubscription.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextInformationSubscription.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource Resource ${EXECDIR}/resources/NotificationUtils.resource @@ -12,9 +13,7 @@ Suite Teardown After Test *** Variables *** -${subscription_id_prefix} urn:ngsi-ld:Subscription: ${subscription_payload_file_path} subscriptions/subscription-with-true-sysAttrs-parameter.jsonld -${building_id_prefix} urn:ngsi-ld:Building: ${entity_building_filepath} building-simple-attributes.jsonld ${fragment_filename} airQualityLevel-fragment.jsonld ${notification_server_send_url} http://${notification_server_host}:${notification_server_port}/notify @@ -43,8 +42,8 @@ Before Test Setup Initial Subscriptions Setup Initial Subscriptions - ${subscription_id}= Generate Random Entity Id ${subscription_id_prefix} - ${entity_id}= Generate Random Entity Id ${building_id_prefix} + ${subscription_id}= Generate Random Subscription Id + ${entity_id}= Generate Random Building Entity Id ${subscription_payload}= Load Subscription Sample With Reachable Endpoint ... ${subscription_payload_file_path} ... ${subscription_id} diff --git a/TP/NGSI-LD/ContextInformation/Subscription/SubscriptionNotificationBehaviour/046_18.robot b/TP/NGSI-LD/ContextInformation/Subscription/SubscriptionNotificationBehaviour/046_18.robot index a1c6aea5b1f73d8e1dacdb5712bfafa62caaa68d..02ad0c4a296fd06892a78186324f35aa26eb8880 100644 --- a/TP/NGSI-LD/ContextInformation/Subscription/SubscriptionNotificationBehaviour/046_18.robot +++ b/TP/NGSI-LD/ContextInformation/Subscription/SubscriptionNotificationBehaviour/046_18.robot @@ -1,8 +1,9 @@ *** Settings *** Documentation The system generated attributes are not included in the response payload body of a notification if sysAttrs parameter is set to false. -Resource ${EXECDIR}/resources/ApiUtils/ContextInformationSubscription.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextInformationSubscription.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource Resource ${EXECDIR}/resources/NotificationUtils.resource @@ -12,9 +13,7 @@ Suite Teardown After Test *** Variables *** -${subscription_id_prefix} urn:ngsi-ld:Subscription: ${subscription_payload_file_path} subscriptions/subscription-with-false-sysAttrs-parameter.jsonld -${building_id_prefix} urn:ngsi-ld:Building: ${entity_building_filepath} building-simple-attributes.jsonld ${fragment_filename} airQualityLevel-fragment.jsonld ${notification_server_send_url} http://${notification_server_host}:${notification_server_port}/notify @@ -43,8 +42,8 @@ Before Test Setup Initial Subscriptions Setup Initial Subscriptions - ${subscription_id}= Generate Random Entity Id ${subscription_id_prefix} - ${entity_id}= Generate Random Entity Id ${building_id_prefix} + ${subscription_id}= Generate Random Subscription Id + ${entity_id}= Generate Random Building Entity Id ${subscription_payload}= Load Subscription Sample With Reachable Endpoint ... ${subscription_payload_file_path} ... ${subscription_id} diff --git a/TP/NGSI-LD/ContextInformation/Subscription/SubscriptionNotificationBehaviour/046_21_01.robot b/TP/NGSI-LD/ContextInformation/Subscription/SubscriptionNotificationBehaviour/046_21_01.robot index 2e5b8f65296dea0afe6c0fd7b9d725105a325d99..ea4be5c12fa96b81d24c26ca719f1dc114df67a5 100644 --- a/TP/NGSI-LD/ContextInformation/Subscription/SubscriptionNotificationBehaviour/046_21_01.robot +++ b/TP/NGSI-LD/ContextInformation/Subscription/SubscriptionNotificationBehaviour/046_21_01.robot @@ -2,8 +2,8 @@ Documentation Check that a notification is sent when an entity is deleted ... and entityDeleted notification trigger is configured -Resource ${EXECDIR}/resources/ApiUtils/ContextInformationSubscription.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextInformationSubscription.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/NotificationUtils.resource Resource ${EXECDIR}/resources/SubscriptionUtils.resource diff --git a/TP/NGSI-LD/ContextInformation/Subscription/SubscriptionNotificationBehaviour/046_21_02.robot b/TP/NGSI-LD/ContextInformation/Subscription/SubscriptionNotificationBehaviour/046_21_02.robot index 6138ce24e13d813598364c4a914f8ae040024482..acd4e36cc07691cde055a4eb61bc25d0e7b43730 100644 --- a/TP/NGSI-LD/ContextInformation/Subscription/SubscriptionNotificationBehaviour/046_21_02.robot +++ b/TP/NGSI-LD/ContextInformation/Subscription/SubscriptionNotificationBehaviour/046_21_02.robot @@ -2,8 +2,8 @@ Documentation Check that a notification is sent with sysAttrs when an entity is deleted ... and entityDeleted notification trigger is configured -Resource ${EXECDIR}/resources/ApiUtils/ContextInformationSubscription.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextInformationSubscription.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/NotificationUtils.resource Resource ${EXECDIR}/resources/SubscriptionUtils.resource diff --git a/TP/NGSI-LD/ContextInformation/Subscription/SubscriptionNotificationBehaviour/046_22_01.robot b/TP/NGSI-LD/ContextInformation/Subscription/SubscriptionNotificationBehaviour/046_22_01.robot index 25ed9e54fe851132ebfdb60486f0b5eb2ce4e1d3..08ceb0bab627f091644a48e39bdd7c799f696098 100644 --- a/TP/NGSI-LD/ContextInformation/Subscription/SubscriptionNotificationBehaviour/046_22_01.robot +++ b/TP/NGSI-LD/ContextInformation/Subscription/SubscriptionNotificationBehaviour/046_22_01.robot @@ -2,8 +2,8 @@ Documentation Check that a notification is sent with keyValues when an attribute is deleted ... and attributeDeleted notification trigger is configured -Resource ${EXECDIR}/resources/ApiUtils/ContextInformationSubscription.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextInformationSubscription.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/NotificationUtils.resource Resource ${EXECDIR}/resources/SubscriptionUtils.resource diff --git a/TP/NGSI-LD/ContextInformation/Subscription/SubscriptionNotificationBehaviour/046_22_02.robot b/TP/NGSI-LD/ContextInformation/Subscription/SubscriptionNotificationBehaviour/046_22_02.robot index aeffec03624ce8b5f976546f3962486d4e2e4662..3639de28880f811bafe8dec0f9f9c9a70e374117 100644 --- a/TP/NGSI-LD/ContextInformation/Subscription/SubscriptionNotificationBehaviour/046_22_02.robot +++ b/TP/NGSI-LD/ContextInformation/Subscription/SubscriptionNotificationBehaviour/046_22_02.robot @@ -2,8 +2,8 @@ Documentation Check that a notification is sent with keyValues when an attribute is deleted ... and attributeDeleted notification trigger is configured for this specific attribute -Resource ${EXECDIR}/resources/ApiUtils/ContextInformationSubscription.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextInformationSubscription.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/NotificationUtils.resource Resource ${EXECDIR}/resources/SubscriptionUtils.resource diff --git a/TP/NGSI-LD/ContextInformation/Subscription/SubscriptionNotificationBehaviour/046_22_03.robot b/TP/NGSI-LD/ContextInformation/Subscription/SubscriptionNotificationBehaviour/046_22_03.robot index f7a5cf821073fb3874a2e81582f36801a450e944..46f6df10b14822e00b5e4216b96e6fb40bad7743 100644 --- a/TP/NGSI-LD/ContextInformation/Subscription/SubscriptionNotificationBehaviour/046_22_03.robot +++ b/TP/NGSI-LD/ContextInformation/Subscription/SubscriptionNotificationBehaviour/046_22_03.robot @@ -2,8 +2,8 @@ Documentation Check that a notification is not sent when an attribute is deleted ... and attributeDeleted notification trigger is not configured for this specific attribute -Resource ${EXECDIR}/resources/ApiUtils/ContextInformationSubscription.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextInformationSubscription.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/NotificationUtils.resource Resource ${EXECDIR}/resources/SubscriptionUtils.resource diff --git a/TP/NGSI-LD/ContextInformation/Subscription/SubscriptionNotificationBehaviour/046_22_04.robot b/TP/NGSI-LD/ContextInformation/Subscription/SubscriptionNotificationBehaviour/046_22_04.robot index ec7f5e8e0e5d5aaaab51c7d0d73d1c8a1b31a42c..0fd763b9f097c998f5ad20fad027d50edbbe69c8 100644 --- a/TP/NGSI-LD/ContextInformation/Subscription/SubscriptionNotificationBehaviour/046_22_04.robot +++ b/TP/NGSI-LD/ContextInformation/Subscription/SubscriptionNotificationBehaviour/046_22_04.robot @@ -2,8 +2,8 @@ Documentation Check that a notification is sent in normalized format when an attribute is deleted ... and attributeDeleted notification trigger is configured for this specific attribute -Resource ${EXECDIR}/resources/ApiUtils/ContextInformationSubscription.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextInformationSubscription.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/NotificationUtils.resource Resource ${EXECDIR}/resources/SubscriptionUtils.resource diff --git a/TP/NGSI-LD/ContextInformation/Subscription/SubscriptionNotificationBehaviour/046_22_05.robot b/TP/NGSI-LD/ContextInformation/Subscription/SubscriptionNotificationBehaviour/046_22_05.robot index 5c0c837f5d5836613f0733070f4b72eb0e4b0888..f2748f01dae9ebac7254f32856db18a62cb3c804 100644 --- a/TP/NGSI-LD/ContextInformation/Subscription/SubscriptionNotificationBehaviour/046_22_05.robot +++ b/TP/NGSI-LD/ContextInformation/Subscription/SubscriptionNotificationBehaviour/046_22_05.robot @@ -2,8 +2,8 @@ Documentation Check that a notification is sent in normalized format with sysAttrs when an attribute is deleted ... and attributeDeleted notification trigger is configured for this specific attribute -Resource ${EXECDIR}/resources/ApiUtils/ContextInformationSubscription.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextInformationSubscription.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/NotificationUtils.resource Resource ${EXECDIR}/resources/SubscriptionUtils.resource diff --git a/TP/NGSI-LD/ContextInformation/Subscription/SubscriptionNotificationBehaviour/046_22_06.robot b/TP/NGSI-LD/ContextInformation/Subscription/SubscriptionNotificationBehaviour/046_22_06.robot index 09856c7d3fd88355a722e67c2681d1a125f2b99f..cf25e5c18785d4853bdbf0299036c5c2d4097bcc 100644 --- a/TP/NGSI-LD/ContextInformation/Subscription/SubscriptionNotificationBehaviour/046_22_06.robot +++ b/TP/NGSI-LD/ContextInformation/Subscription/SubscriptionNotificationBehaviour/046_22_06.robot @@ -2,8 +2,8 @@ Documentation Check that a notification is sent in normalized format when an attribute with a specific datasetId is deleted ... and attributeDeleted notification trigger is configured for this specific attribute -Resource ${EXECDIR}/resources/ApiUtils/ContextInformationSubscription.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextInformationSubscription.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/NotificationUtils.resource Resource ${EXECDIR}/resources/SubscriptionUtils.resource diff --git a/TP/NGSI-LD/ContextInformation/Subscription/SubscriptionNotificationBehaviour/046_22_07.robot b/TP/NGSI-LD/ContextInformation/Subscription/SubscriptionNotificationBehaviour/046_22_07.robot index 5d1f1e3b2a0205b44433bb2263d30fd9bcd0bb8c..75319b91d8939a9daa024a1a9b55a64e4f994322 100644 --- a/TP/NGSI-LD/ContextInformation/Subscription/SubscriptionNotificationBehaviour/046_22_07.robot +++ b/TP/NGSI-LD/ContextInformation/Subscription/SubscriptionNotificationBehaviour/046_22_07.robot @@ -2,8 +2,8 @@ Documentation Check that a notification is sent with keyValues when an attribute with a specific datasetId is deleted ... and attributeDeleted notification trigger is configured for this specific attribute -Resource ${EXECDIR}/resources/ApiUtils/ContextInformationSubscription.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextInformationSubscription.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/NotificationUtils.resource Resource ${EXECDIR}/resources/SubscriptionUtils.resource diff --git a/TP/NGSI-LD/ContextInformation/Subscription/SubscriptionNotificationBehaviour/046_22_08.robot b/TP/NGSI-LD/ContextInformation/Subscription/SubscriptionNotificationBehaviour/046_22_08.robot index caa9fd639b0a67e3ea22c8382b319e00c7118cf3..6b10cfa49c76eb51b78c47d1dca3138cd2345fad 100644 --- a/TP/NGSI-LD/ContextInformation/Subscription/SubscriptionNotificationBehaviour/046_22_08.robot +++ b/TP/NGSI-LD/ContextInformation/Subscription/SubscriptionNotificationBehaviour/046_22_08.robot @@ -2,8 +2,8 @@ Documentation Check that a notification is sent when all instances of an attribute are deleted ... and attributeDeleted notification trigger is configured for this specific attribute -Resource ${EXECDIR}/resources/ApiUtils/ContextInformationSubscription.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextInformationSubscription.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/NotificationUtils.resource Resource ${EXECDIR}/resources/SubscriptionUtils.resource diff --git a/TP/NGSI-LD/ContextInformation/Subscription/SubscriptionNotificationBehaviour/046_22_09.robot b/TP/NGSI-LD/ContextInformation/Subscription/SubscriptionNotificationBehaviour/046_22_09.robot index 3d9162c684138ea31f71f46cda12f584fb5bfaad..fa813da3e713f67e4e8fa9a1b30fc15709dc0685 100644 --- a/TP/NGSI-LD/ContextInformation/Subscription/SubscriptionNotificationBehaviour/046_22_09.robot +++ b/TP/NGSI-LD/ContextInformation/Subscription/SubscriptionNotificationBehaviour/046_22_09.robot @@ -2,8 +2,8 @@ Documentation Check that a notification is sent in normalized format when an attribute is deleted via NGSI-LD Null ... in a Merge Entity operation and attributeDeleted notification trigger is configured for this specific attribute -Resource ${EXECDIR}/resources/ApiUtils/ContextInformationSubscription.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextInformationSubscription.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/NotificationUtils.resource Resource ${EXECDIR}/resources/SubscriptionUtils.resource diff --git a/TP/NGSI-LD/ContextInformation/Subscription/SubscriptionNotificationBehaviour/046_22_10.robot b/TP/NGSI-LD/ContextInformation/Subscription/SubscriptionNotificationBehaviour/046_22_10.robot index fd960fb8f3abb6e2b8dafb2f24c816ef702f6eae..702addd6ad7d82f7f401439952a85d8f274f7cdc 100644 --- a/TP/NGSI-LD/ContextInformation/Subscription/SubscriptionNotificationBehaviour/046_22_10.robot +++ b/TP/NGSI-LD/ContextInformation/Subscription/SubscriptionNotificationBehaviour/046_22_10.robot @@ -2,8 +2,8 @@ Documentation Check that a notification is sent in normalized format when a relationship is deleted via NGSI-LD Null ... in a Merge Entity operation and attributeDeleted notification trigger is configured for this specific relationship -Resource ${EXECDIR}/resources/ApiUtils/ContextInformationSubscription.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextInformationSubscription.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/NotificationUtils.resource Resource ${EXECDIR}/resources/SubscriptionUtils.resource diff --git a/TP/NGSI-LD/ContextInformation/Subscription/SubscriptionNotificationBehaviour/046_22_11.robot b/TP/NGSI-LD/ContextInformation/Subscription/SubscriptionNotificationBehaviour/046_22_11.robot index 69d425a8665a289527289a917bacf91d56dec0ea..4bd8da924e7a122e7a9c64d01c420432e2b598fe 100644 --- a/TP/NGSI-LD/ContextInformation/Subscription/SubscriptionNotificationBehaviour/046_22_11.robot +++ b/TP/NGSI-LD/ContextInformation/Subscription/SubscriptionNotificationBehaviour/046_22_11.robot @@ -2,8 +2,8 @@ Documentation Check that a notification is sent in normalized format when a language property is deleted via NGSI-LD Null ... in a Merge Entity operation and attributeDeleted notification trigger is configured for this specific property -Resource ${EXECDIR}/resources/ApiUtils/ContextInformationSubscription.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextInformationSubscription.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/NotificationUtils.resource Resource ${EXECDIR}/resources/SubscriptionUtils.resource diff --git a/TP/NGSI-LD/ContextInformation/Subscription/SubscriptionNotificationBehaviour/046_22_12.robot b/TP/NGSI-LD/ContextInformation/Subscription/SubscriptionNotificationBehaviour/046_22_12.robot index 53d48aebba5b2b848ca39593ea1b103f64bc946e..6c5edab7d72aeb4d1061838030bf6afeae747372 100644 --- a/TP/NGSI-LD/ContextInformation/Subscription/SubscriptionNotificationBehaviour/046_22_12.robot +++ b/TP/NGSI-LD/ContextInformation/Subscription/SubscriptionNotificationBehaviour/046_22_12.robot @@ -2,8 +2,8 @@ Documentation Check that a notification is sent in normalized format when an entity is deleted ... and attributeDeleted notification trigger is configured for a matching attribute in deleted entity -Resource ${EXECDIR}/resources/ApiUtils/ContextInformationSubscription.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextInformationSubscription.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/NotificationUtils.resource Resource ${EXECDIR}/resources/SubscriptionUtils.resource diff --git a/TP/NGSI-LD/ContextInformation/Subscription/SubscriptionNotificationBehaviour/046_22_13.robot b/TP/NGSI-LD/ContextInformation/Subscription/SubscriptionNotificationBehaviour/046_22_13.robot index dbe391b3c2ade77ab96829fdddfc074796f1217a..24003f14956566f96c6eef6078cf736d1e8f1b6b 100644 --- a/TP/NGSI-LD/ContextInformation/Subscription/SubscriptionNotificationBehaviour/046_22_13.robot +++ b/TP/NGSI-LD/ContextInformation/Subscription/SubscriptionNotificationBehaviour/046_22_13.robot @@ -2,8 +2,8 @@ Documentation Check that a notification is sent in normalized format with sysAttrs when an entity is deleted ... and attributeDeleted notification trigger is configured for a matching attribute in deleted entity -Resource ${EXECDIR}/resources/ApiUtils/ContextInformationSubscription.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextInformationSubscription.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/NotificationUtils.resource Resource ${EXECDIR}/resources/SubscriptionUtils.resource diff --git a/TP/NGSI-LD/ContextInformation/Subscription/SubscriptionNotificationBehaviour/MQTT/058_01.robot b/TP/NGSI-LD/ContextInformation/Subscription/SubscriptionNotificationBehaviour/MQTT/058_01.robot index 2336b5615294a3706a1f8274c0f5aa07236d3c13..82077ef4d6b0daf23632bf6ad12a4927dedfe36d 100644 --- a/TP/NGSI-LD/ContextInformation/Subscription/SubscriptionNotificationBehaviour/MQTT/058_01.robot +++ b/TP/NGSI-LD/ContextInformation/Subscription/SubscriptionNotificationBehaviour/MQTT/058_01.robot @@ -1,8 +1,9 @@ *** Settings *** Documentation Check that the Mqtt Notification is received with different userInfo and port -Resource ${EXECDIR}/resources/ApiUtils/ContextInformationSubscription.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextInformationSubscription.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource Resource ${EXECDIR}/resources/NotificationUtils.resource @@ -13,9 +14,7 @@ Test Template Receive MQTT Notification *** Variables *** -${subscription_id_prefix} urn:ngsi-ld:Subscription: ${subscription_payload_file_path} subscriptions/subscription-building-entities-default.jsonld -${building_id_prefix} urn:ngsi-ld:Building: ${entity_building_filepath} building-simple-attributes.jsonld ${fragment_filename} airQualityLevel-fragment.jsonld ${topic} ngsild-test-suite/topic @@ -63,8 +62,8 @@ After Test Setup Mqtt Subscription [Arguments] ${endpoint_uri} - ${subscription_id}= Generate Random Entity Id ${subscription_id_prefix} - ${entity_id}= Generate Random Entity Id ${building_id_prefix} + ${subscription_id}= Generate Random Subscription Id + ${entity_id}= Generate Random Building Entity Id ${subscription_payload}= Load Subscription Sample With Reachable Endpoint ... ${subscription_payload_file_path} diff --git a/TP/NGSI-LD/ContextInformation/Subscription/SubscriptionNotificationBehaviour/MQTT/058_02.robot b/TP/NGSI-LD/ContextInformation/Subscription/SubscriptionNotificationBehaviour/MQTT/058_02.robot index 8bc65094366ea781415f1d372157ed837f2743f7..f8d6c49e840ea135f93c55fbbd3fd27b2cb09045 100644 --- a/TP/NGSI-LD/ContextInformation/Subscription/SubscriptionNotificationBehaviour/MQTT/058_02.robot +++ b/TP/NGSI-LD/ContextInformation/Subscription/SubscriptionNotificationBehaviour/MQTT/058_02.robot @@ -1,8 +1,9 @@ *** Settings *** Documentation Check that the mqtt notification is received with different qos -Resource ${EXECDIR}/resources/ApiUtils/ContextInformationSubscription.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextInformationSubscription.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource Resource ${EXECDIR}/resources/NotificationUtils.resource @@ -14,9 +15,7 @@ Test Template Receive MQTT Notification *** Variables *** -${subscription_id_prefix} urn:ngsi-ld:Subscription: ${subscription_payload_file_path} subscriptions/subscription-building-entities-default.jsonld -${building_id_prefix} urn:ngsi-ld:Building: ${entity_building_filepath} building-simple-attributes.jsonld ${fragment_filename} airQualityLevel-fragment.jsonld ${topic} ngsild-test-suite/topic @@ -60,8 +59,8 @@ After Test Setup Mqtt Subscription [Arguments] ${endpoint_uri} ${qos}=${None} - ${subscription_id}= Generate Random Entity Id ${subscription_id_prefix} - ${entity_id}= Generate Random Entity Id ${building_id_prefix} + ${subscription_id}= Generate Random Subscription Id + ${entity_id}= Generate Random Building Entity Id ${subscription_payload}= Load Subscription Sample With Reachable Endpoint ... ${subscription_payload_file_path} diff --git a/TP/NGSI-LD/ContextInformation/Subscription/SubscriptionNotificationBehaviour/MQTT/058_03.robot b/TP/NGSI-LD/ContextInformation/Subscription/SubscriptionNotificationBehaviour/MQTT/058_03.robot index 794cd76adfb2fe78d91912c7d2732b264440de58..c024d1cde15c2b1ef49e98324db29d12def631f4 100644 --- a/TP/NGSI-LD/ContextInformation/Subscription/SubscriptionNotificationBehaviour/MQTT/058_03.robot +++ b/TP/NGSI-LD/ContextInformation/Subscription/SubscriptionNotificationBehaviour/MQTT/058_03.robot @@ -1,8 +1,9 @@ *** Settings *** Documentation Check that mqtt notification is received with different mqtt version -Resource ${EXECDIR}/resources/ApiUtils/ContextInformationSubscription.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextInformationSubscription.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource Resource ${EXECDIR}/resources/NotificationUtils.resource @@ -14,9 +15,7 @@ Test Template Receive Mqtt Notification *** Variables *** -${subscription_id_prefix} urn:ngsi-ld:Subscription: ${subscription_payload_file_path} subscriptions/subscription-building-entities-default.jsonld -${building_id_prefix} urn:ngsi-ld:Building: ${entity_building_filepath} building-simple-attributes.jsonld ${fragment_filename} airQualityLevel-fragment.jsonld ${topic} ngsild-test-suite/topic @@ -62,8 +61,8 @@ After Test Setup Mqtt Subscription [Arguments] ${endpoint_uri} ${version}=${None} - ${subscription_id}= Generate Random Entity Id ${subscription_id_prefix} - ${entity_id}= Generate Random Entity Id ${building_id_prefix} + ${subscription_id}= Generate Random Subscription Id + ${entity_id}= Generate Random Building Entity Id ${subscription_payload}= Load Subscription Sample With Reachable Endpoint ... ${subscription_payload_file_path} diff --git a/TP/NGSI-LD/ContextInformation/Subscription/SubscriptionNotificationBehaviour/MQTT/058_04.robot b/TP/NGSI-LD/ContextInformation/Subscription/SubscriptionNotificationBehaviour/MQTT/058_04.robot index 3077e3c96169406904310bc913954d36a039e044..8452f4916405cbf4dd0e210b1209741ac216855d 100644 --- a/TP/NGSI-LD/ContextInformation/Subscription/SubscriptionNotificationBehaviour/MQTT/058_04.robot +++ b/TP/NGSI-LD/ContextInformation/Subscription/SubscriptionNotificationBehaviour/MQTT/058_04.robot @@ -1,8 +1,9 @@ *** Settings *** Documentation Check that the mqtt notification payload is well formed -Resource ${EXECDIR}/resources/ApiUtils/ContextInformationSubscription.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextInformationSubscription.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource Resource ${EXECDIR}/resources/NotificationUtils.resource @@ -14,9 +15,7 @@ Test Template Receive Mqtt Notification *** Variables *** -${subscription_id_prefix} urn:ngsi-ld:Subscription: ${subscription_payload_file_path} subscriptions/subscription-building-entities-default.jsonld -${building_id_prefix} urn:ngsi-ld:Building: ${entity_building_filepath} building-simple-attributes.jsonld ${fragment_filename} airQualityLevel-fragment.jsonld ${topic} ngsild-test-suite/topic @@ -65,8 +64,8 @@ After Test Setup Mqtt Subscription [Arguments] ${endpoint_uri} - ${subscription_id}= Generate Random Entity Id ${subscription_id_prefix} - ${entity_id}= Generate Random Entity Id ${building_id_prefix} + ${subscription_id}= Generate Random Subscription Id + ${entity_id}= Generate Random Building Entity Id ${subscription_payload}= Load Subscription Sample With Reachable Endpoint ... ${subscription_payload_file_path} diff --git a/TP/NGSI-LD/ContextInformation/Subscription/UpdateSubscription/029_03.robot b/TP/NGSI-LD/ContextInformation/Subscription/UpdateSubscription/029_03.robot index 31b5bceb99ea1800e3487ed2da89f7b2f417ae05..06adbf1f551ea920ce8fa5be94ad01137c972735 100644 --- a/TP/NGSI-LD/ContextInformation/Subscription/UpdateSubscription/029_03.robot +++ b/TP/NGSI-LD/ContextInformation/Subscription/UpdateSubscription/029_03.robot @@ -1,6 +1,7 @@ *** Settings *** Documentation Check that one cannot update a subscription: If the data types and restriction are not met by the Subscription Fragment, then an error of type BadRequestData shall be raised +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationSubscription.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -10,7 +11,6 @@ Suite Teardown Delete Initial Subscriptions *** Variables *** -${subscription_id_prefix}= urn:ngsi-ld:Subscription: ${subscription_payload_file_path}= subscriptions/subscription.jsonld ${subscription_update_fragment_file_path}= subscriptions/fragments/subscription-invalid-update.json @@ -32,7 +32,7 @@ ${subscription_update_fragment_file_path}= subscriptions/fragments/subscrip *** Keywords *** Setup Initial Subscriptions - ${subscription_id}= Generate Random Entity Id ${subscription_id_prefix} + ${subscription_id}= Generate Random Subscription Id ${initial_response}= Create Subscription ... ${subscription_id} ... ${subscription_payload_file_path} diff --git a/TP/NGSI-LD/ContextInformation/Subscription/UpdateSubscription/029_04.robot b/TP/NGSI-LD/ContextInformation/Subscription/UpdateSubscription/029_04.robot index 8ca7ab5525816aca9919a2ccf6bd7741e862ee77..15bb26002f4122937aac2b102a8739c8cd4a15d8 100644 --- a/TP/NGSI-LD/ContextInformation/Subscription/UpdateSubscription/029_04.robot +++ b/TP/NGSI-LD/ContextInformation/Subscription/UpdateSubscription/029_04.robot @@ -1,6 +1,7 @@ *** Settings *** Documentation Check that one cannot update a subscription: Any attempt to remove (by setting them to null in the Fragment) mandatory properties of a Subscription (clause 5.2.12) shall result in an error of type BadRequestData +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationSubscription.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -10,7 +11,6 @@ Suite Teardown Delete Initial Subscriptions *** Variables *** -${subscription_id_prefix}= urn:ngsi-ld:Subscription: ${subscription_payload_file_path}= subscriptions/subscription.jsonld ${subscription_update_fragment_file_path}= subscriptions/fragments/subscription-null-properties-update.json @@ -32,7 +32,7 @@ ${subscription_update_fragment_file_path}= subscriptions/fragments/subscrip *** Keywords *** Setup Initial Subscriptions - ${subscription_id}= Generate Random Entity Id ${subscription_id_prefix} + ${subscription_id}= Generate Random Subscription Id ${initial_response}= Create Subscription ... ${subscription_id} ... ${subscription_payload_file_path} diff --git a/TP/NGSI-LD/ContextInformation/Subscription/UpdateSubscription/029_05.robot b/TP/NGSI-LD/ContextInformation/Subscription/UpdateSubscription/029_05.robot index f5100d6a85b7fbc3c30be9006e4794bfa1f1ec86..b1c38a78117defc12926321df6c8cfaf452b1a8c 100644 --- a/TP/NGSI-LD/ContextInformation/Subscription/UpdateSubscription/029_05.robot +++ b/TP/NGSI-LD/ContextInformation/Subscription/UpdateSubscription/029_05.robot @@ -1,6 +1,7 @@ *** Settings *** Documentation Check that one can update a subcription: Term to URI expansion of Attribute names shall be observed +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationSubscription.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -10,7 +11,6 @@ Suite Teardown Delete Initial Subscriptions *** Variables *** -${subscription_id_prefix}= urn:ngsi-ld:Subscription: ${subscription_payload_file_path}= subscriptions/subscription.jsonld ${subscription_update_fragment_file_path}= subscriptions/fragments/subscription-vehicle-entities.json ${expected_subscription_payload_file_path}= subscriptions/expectations/subscription-vehicle.jsonld @@ -54,7 +54,7 @@ ${expected_expanded_subscription_payload_file_path}= subscriptions/expectatio *** Keywords *** Setup Initial Subscriptions - ${subscription_id}= Generate Random Entity Id ${subscription_id_prefix} + ${subscription_id}= Generate Random Subscription Id ${initial_response}= Create Subscription ... ${subscription_id} ... ${subscription_payload_file_path} diff --git a/TP/NGSI-LD/ContextInformation/Subscription/UpdateSubscription/029_06.robot b/TP/NGSI-LD/ContextInformation/Subscription/UpdateSubscription/029_06.robot index 45b847e297c51fa3908a021cc816888c8efadc3e..003a5802a71b1c9c286fbe4bdaffaf04491ada27 100644 --- a/TP/NGSI-LD/ContextInformation/Subscription/UpdateSubscription/029_06.robot +++ b/TP/NGSI-LD/ContextInformation/Subscription/UpdateSubscription/029_06.robot @@ -1,6 +1,7 @@ *** Settings *** Documentation Check that one can update a subscription: The implementation shall modify the target Subscription +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationSubscription.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -10,7 +11,6 @@ Suite Teardown Delete Initial Subscriptions *** Variables *** -${subscription_id_prefix}= urn:ngsi-ld:Subscription: ${subscription_payload_file_path}= subscriptions/subscription.jsonld ${subscription_update_fragment_file_path}= subscriptions/fragments/subscription-update.json @@ -40,7 +40,7 @@ ${subscription_update_fragment_file_path}= subscriptions/fragments/subscrip *** Keywords *** Setup Initial Subscriptions - ${subscription_id}= Generate Random Entity Id ${subscription_id_prefix} + ${subscription_id}= Generate Random Subscription Id ${subscription_payload}= Load Test Sample ${subscription_payload_file_path} ${subscription_id} ${initial_response}= Create Subscription ... ${subscription_id} diff --git a/TP/NGSI-LD/ContextInformation/Subscription/UpdateSubscription/029_07.robot b/TP/NGSI-LD/ContextInformation/Subscription/UpdateSubscription/029_07.robot index d3f6278dcece5b8f0f0662573adbb817565f98ec..6f7f021c3aa4f876bec4e82164766583aadf1660 100644 --- a/TP/NGSI-LD/ContextInformation/Subscription/UpdateSubscription/029_07.robot +++ b/TP/NGSI-LD/ContextInformation/Subscription/UpdateSubscription/029_07.robot @@ -1,6 +1,7 @@ *** Settings *** Documentation Check that one can update a subscription: If isActive is equal to true and expiresAt is not present, then status shall be updated to "active", if and only if, the previous value of status was different than "expired" +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationSubscription.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -11,7 +12,6 @@ Test Template Activate Paused Subscription With isActive Member *** Variables *** -${subscription_id_prefix}= urn:ngsi-ld:Subscription: ${subscription_payload_file_path}= subscriptions/subscription-inactive.jsonld @@ -38,7 +38,7 @@ Activate Paused Subscription With isActive Member ... expected_attribute_value=active Setup Initial Subscriptions - ${subscription_id}= Generate Random Entity Id ${subscription_id_prefix} + ${subscription_id}= Generate Random Subscription Id ${initial_response}= Create Subscription ... ${subscription_id} ... ${subscription_payload_file_path} diff --git a/TP/NGSI-LD/ContextInformation/Subscription/UpdateSubscription/029_08.robot b/TP/NGSI-LD/ContextInformation/Subscription/UpdateSubscription/029_08.robot index 0a497a276f5c5cfb8f9aa502280bf93d140ef4d0..5ad4cbf5baf69e133d1f2776d7494c7558fefa40 100644 --- a/TP/NGSI-LD/ContextInformation/Subscription/UpdateSubscription/029_08.robot +++ b/TP/NGSI-LD/ContextInformation/Subscription/UpdateSubscription/029_08.robot @@ -1,6 +1,7 @@ *** Settings *** Documentation Check that one can update a subscription: If isActive is equal to true and expiresAt corresponds to a DateTime in the future, then status shall be updated to "active" +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationSubscription.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -11,7 +12,6 @@ Test Template Activate Paused Subscription With isActive And ExpiresAt Mem *** Variables *** -${subscription_id_prefix}= urn:ngsi-ld:Subscription: ${subscription_payload_file_path}= subscriptions/subscription-inactive.jsonld @@ -38,7 +38,7 @@ Activate Paused Subscription With isActive And ExpiresAt Members ... expected_attribute_value=active Setup Initial Subscriptions - ${subscription_id}= Generate Random Entity Id ${subscription_id_prefix} + ${subscription_id}= Generate Random Subscription Id ${initial_response}= Create Subscription ... ${subscription_id} ... ${subscription_payload_file_path} diff --git a/TP/NGSI-LD/ContextInformation/Subscription/UpdateSubscription/029_09.robot b/TP/NGSI-LD/ContextInformation/Subscription/UpdateSubscription/029_09.robot index 4012ed415f4ea256e5e6cdfdbcc0700e142e314d..2748e5ed63ddfc6fac2c42c87ed431a1d2c594cc 100644 --- a/TP/NGSI-LD/ContextInformation/Subscription/UpdateSubscription/029_09.robot +++ b/TP/NGSI-LD/ContextInformation/Subscription/UpdateSubscription/029_09.robot @@ -1,6 +1,7 @@ *** Settings *** Documentation Check that one can update a subscription: If isActive is equal to false and expiresAt is not present, then status shall be updated to "paused", if and only if, the previous value of status was different than "expired" +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationSubscription.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -10,7 +11,6 @@ Suite Teardown Delete Initial Subscriptions *** Variables *** -${subscription_id_prefix}= urn:ngsi-ld:Subscription: ${subscription_payload_file_path}= subscriptions/subscription.jsonld ${subscription_update_fragment_file_path}= subscriptions/fragments/subscription-isActive-false-update.json @@ -34,7 +34,7 @@ ${subscription_update_fragment_file_path}= subscriptions/fragments/subscrip *** Keywords *** Setup Initial Subscriptions - ${subscription_id}= Generate Random Entity Id ${subscription_id_prefix} + ${subscription_id}= Generate Random Subscription Id ${initial_response}= Create Subscription ... ${subscription_id} ... ${subscription_payload_file_path} diff --git a/TP/NGSI-LD/ContextInformation/Subscription/UpdateSubscription/029_10.robot b/TP/NGSI-LD/ContextInformation/Subscription/UpdateSubscription/029_10.robot index 5c4cebbc33e21a52365c3f4b6df57d075959dff1..2d5ebb42c71b38b5c1cf2208cb08120579775209 100644 --- a/TP/NGSI-LD/ContextInformation/Subscription/UpdateSubscription/029_10.robot +++ b/TP/NGSI-LD/ContextInformation/Subscription/UpdateSubscription/029_10.robot @@ -1,6 +1,7 @@ *** Settings *** Documentation Check that one can update a subscription: If only expiresAt is included and refers to a DateTime in the future, then status shall be updated to "active", if and only if the previous value of status was "expired" +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationSubscription.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -10,7 +11,6 @@ Suite Teardown Delete Initial Subscriptions *** Variables *** -${subscription_id_prefix} urn:ngsi-ld:Subscription: ${subscription_payload_file_path} subscriptions/subscription.jsonld ${subscription_update_fragment_file_path} subscriptions/fragments/subscription-expiresAt-future-update.json @@ -45,7 +45,7 @@ ${subscription_update_fragment_file_path} subscriptions/fragments/subscrip *** Keywords *** Setup Initial Subscriptions - ${subscription_id}= Generate Random Entity Id ${subscription_id_prefix} + ${subscription_id}= Generate Random Subscription Id ${initial_response}= Create Subscription ... ${subscription_id} ... ${subscription_payload_file_path} diff --git a/TP/NGSI-LD/ContextInformation/Subscription/UpdateSubscription/029_11.robot b/TP/NGSI-LD/ContextInformation/Subscription/UpdateSubscription/029_11.robot index 52c642317137a804ec8276c051a8820fe06a5db0..87ca08d4dc77c7d320b64be5c70ff7f8d0017238 100644 --- a/TP/NGSI-LD/ContextInformation/Subscription/UpdateSubscription/029_11.robot +++ b/TP/NGSI-LD/ContextInformation/Subscription/UpdateSubscription/029_11.robot @@ -1,6 +1,7 @@ *** Settings *** Documentation Check that one cannot update a subscription: If expiresAt is included but referring to a DateTime in the past, then a BadRequestData error shall be raised +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationSubscription.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -10,7 +11,6 @@ Suite Teardown Delete Initial Subscriptions *** Variables *** -${subscription_id_prefix}= urn:ngsi-ld:Subscription: ${subscription_payload_file_path}= subscriptions/subscription.jsonld ${subscription_update_fragment_file_path}= subscriptions/fragments/subscription-expiresAt-update.json @@ -32,7 +32,7 @@ ${subscription_update_fragment_file_path}= subscriptions/fragments/subscrip *** Keywords *** Setup Initial Subscriptions - ${subscription_id}= Generate Random Entity Id ${subscription_id_prefix} + ${subscription_id}= Generate Random Subscription Id ${initial_response}= Create Subscription ... ${subscription_id} ... ${subscription_payload_file_path} diff --git a/TP/NGSI-LD/ContextSource/Discovery/QueryContextSourceRegistrations/037_01.robot b/TP/NGSI-LD/ContextSource/Discovery/QueryContextSourceRegistrations/037_01.robot index 5561471b226195d18337ad1bc2481adac1619588..3cd4d089aae4a0d1afb80fe24fe10bdab16bd88a 100644 --- a/TP/NGSI-LD/ContextSource/Discovery/QueryContextSourceRegistrations/037_01.robot +++ b/TP/NGSI-LD/ContextSource/Discovery/QueryContextSourceRegistrations/037_01.robot @@ -1,6 +1,7 @@ *** Settings *** Documentation Check that one can query context source registrations if at least one of list of Entity Types or list of Attribute names is present +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextSourceDiscovery.resource Resource ${EXECDIR}/resources/ApiUtils/ContextSourceRegistration.resource Resource ${EXECDIR}/resources/AssertionUtils.resource @@ -12,7 +13,6 @@ Test Template Query A Context Source Registration *** Variables *** -${context_source_registration_id_prefix}= urn:ngsi-ld:ContextSourceRegistration: ${first_context_source_registration_payload_file_path}= csourceRegistrations/context-source-registration.jsonld ${second_context_source_registration_payload_file_path}= csourceRegistrations/context-source-registration-detailed-information.jsonld @@ -44,8 +44,8 @@ Query A Context Source Registration ... ${response.json()} Setup Initial Context Source Registrations - ${first_context_source_registration_id}= Generate Random Entity Id ${context_source_registration_id_prefix} - ${second_context_source_registration_id}= Generate Random Entity Id ${context_source_registration_id_prefix} + ${first_context_source_registration_id}= Generate Random CSR Id + ${second_context_source_registration_id}= Generate Random CSR Id ${first_context_source_registration_payload}= Load Test Sample ... ${first_context_source_registration_payload_file_path} ... ${first_context_source_registration_id} diff --git a/TP/NGSI-LD/ContextSource/Discovery/QueryContextSourceRegistrations/037_04.robot b/TP/NGSI-LD/ContextSource/Discovery/QueryContextSourceRegistrations/037_04.robot index ce6506bee16fea65283134a9d5fd534ed0512265..2ad81046749a6e78627c85044d04e232ef301a5e 100644 --- a/TP/NGSI-LD/ContextSource/Discovery/QueryContextSourceRegistrations/037_04.robot +++ b/TP/NGSI-LD/ContextSource/Discovery/QueryContextSourceRegistrations/037_04.robot @@ -1,6 +1,7 @@ *** Settings *** Documentation Check that one can query context source registrations. If a JSON-LD context is not provided, then all the query terms shall be resolved against the default JSON-LD @context +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextSourceDiscovery.resource Resource ${EXECDIR}/resources/ApiUtils/ContextSourceRegistration.resource Resource ${EXECDIR}/resources/AssertionUtils.resource @@ -11,7 +12,6 @@ Suite Teardown Delete Created Context Source Registration *** Variables *** -${context_source_registration_id_prefix}= urn:ngsi-ld:ContextSourceRegistration: ${context_source_registration_payload_file_path}= csourceRegistrations/context-source-registration-detailed-information.jsonld ${expectation_file_path}= csourceRegistrations/expectations/context-source-registrations-037-04.json ${entity_type}= https://ngsi-ld-test-suite/context#Building @@ -32,7 +32,7 @@ ${entity_type}= https://ngsi-ld-test-sui *** Keywords *** Setup Initial Context Source Registration - ${context_source_registration_id}= Generate Random Entity Id ${context_source_registration_id_prefix} + ${context_source_registration_id}= Generate Random CSR Id ${context_source_registration_payload}= Load Test Sample ... ${context_source_registration_payload_file_path} ... ${context_source_registration_id} diff --git a/TP/NGSI-LD/ContextSource/Discovery/QueryContextSourceRegistrations/037_05.robot b/TP/NGSI-LD/ContextSource/Discovery/QueryContextSourceRegistrations/037_05.robot index 64d0e75f8b330de367114e6603fa6e362d0bddd2..1df96505b203edf26c93560437f548783b8c0439 100644 --- a/TP/NGSI-LD/ContextSource/Discovery/QueryContextSourceRegistrations/037_05.robot +++ b/TP/NGSI-LD/ContextSource/Discovery/QueryContextSourceRegistrations/037_05.robot @@ -1,6 +1,7 @@ *** Settings *** Documentation Check that one can query context source registrations matching EntityInfo of RegistrationInfo +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextSourceDiscovery.resource Resource ${EXECDIR}/resources/ApiUtils/ContextSourceRegistration.resource Resource ${EXECDIR}/resources/AssertionUtils.resource @@ -10,10 +11,6 @@ Test Teardown Delete Created Context Source Registration Test Template Query Context Source Registration Matching EntityInfo of RegistrationInfo -*** Variables *** -${context_source_registration_id_prefix}= urn:ngsi-ld:ContextSourceRegistration: - - *** Test Cases *** REGISTRATION_FILE_PATH EXPECTATION_FILE_PATH 037_05_01 Registration With EntityInfo Matching The Query [Tags] csr-query 5_10_2 @@ -43,7 +40,7 @@ Query Context Source Registration Matching EntityInfo of RegistrationInfo Setup Initial Context Source Registrations [Arguments] ${registration_file_path} - ${context_source_registration_id}= Generate Random Entity Id ${context_source_registration_id_prefix} + ${context_source_registration_id}= Generate Random CSR Id ${context_source_registration_payload}= Load Test Sample ... ${registration_file_path} ... ${context_source_registration_id} diff --git a/TP/NGSI-LD/ContextSource/Discovery/QueryContextSourceRegistrations/037_06.robot b/TP/NGSI-LD/ContextSource/Discovery/QueryContextSourceRegistrations/037_06.robot index dbc54401b29753921a718c5ead321e8172e433af..14f86c9d9336e28bfb89bd0611a418ad979f183c 100644 --- a/TP/NGSI-LD/ContextSource/Discovery/QueryContextSourceRegistrations/037_06.robot +++ b/TP/NGSI-LD/ContextSource/Discovery/QueryContextSourceRegistrations/037_06.robot @@ -1,6 +1,7 @@ *** Settings *** Documentation Check that one can query context source registrations matching property and relationship names of RegistrationInfo +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextSourceDiscovery.resource Resource ${EXECDIR}/resources/ApiUtils/ContextSourceRegistration.resource Resource ${EXECDIR}/resources/AssertionUtils.resource @@ -12,7 +13,6 @@ Test Template Query Context Source Registration Matching Properties And Re *** Variables *** -${context_source_registration_id_prefix}= urn:ngsi-ld:ContextSourceRegistration: ${context_source_registration_payload_file_path}= csourceRegistrations/context-source-registration-detailed-information.jsonld @@ -41,7 +41,7 @@ Query Context Source Registration Matching Properties And Relationships Of Regis ... ${response.json()} Setup Initial Context Source Registration - ${context_source_registration_id}= Generate Random Entity Id ${context_source_registration_id_prefix} + ${context_source_registration_id}= Generate Random CSR Id ${context_source_registration_payload}= Load Test Sample ... ${context_source_registration_payload_file_path} ... ${context_source_registration_id} diff --git a/TP/NGSI-LD/ContextSource/Discovery/QueryContextSourceRegistrations/037_07.robot b/TP/NGSI-LD/ContextSource/Discovery/QueryContextSourceRegistrations/037_07.robot index 6503341a1e2db8bed688e0898d39dbbb80fd77a7..712bba6959318f3e473a2e91ce3bc3def68b0c1b 100644 --- a/TP/NGSI-LD/ContextSource/Discovery/QueryContextSourceRegistrations/037_07.robot +++ b/TP/NGSI-LD/ContextSource/Discovery/QueryContextSourceRegistrations/037_07.robot @@ -1,6 +1,7 @@ *** Settings *** Documentation Check that one can query context source registrations. If present, the geoquery is matched against the GeoProperty programmatic parameter identified in the geoquery +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextSourceDiscovery.resource Resource ${EXECDIR}/resources/ApiUtils/ContextSourceRegistration.resource Resource ${EXECDIR}/resources/AssertionUtils.resource @@ -12,7 +13,6 @@ Test Template Query Context Source Registration Matching Geoquery *** Variables *** -${context_source_registration_id_prefix}= urn:ngsi-ld:ContextSourceRegistration: ${context_source_registration_payload_file_path}= csourceRegistrations/context-source-registration-location.jsonld ${expectation_file_path}= csourceRegistrations/expectations/context-source-registrations-037-07.json @@ -45,7 +45,7 @@ Query Context Source Registration Matching Geoquery ... ${response.json()} Setup Initial Context Source Registration - ${context_source_registration_id}= Generate Random Entity Id ${context_source_registration_id_prefix} + ${context_source_registration_id}= Generate Random CSR Id ${context_source_registration_payload}= Load Test Sample ... ${context_source_registration_payload_file_path} ... ${context_source_registration_id} diff --git a/TP/NGSI-LD/ContextSource/Discovery/QueryContextSourceRegistrations/037_08.robot b/TP/NGSI-LD/ContextSource/Discovery/QueryContextSourceRegistrations/037_08.robot index 1cfc514055fef13d5da5103fc44d054fe0bdb100..3ada77bf319128b4afe3adc1f8c4da85cfd344ea 100644 --- a/TP/NGSI-LD/ContextSource/Discovery/QueryContextSourceRegistrations/037_08.robot +++ b/TP/NGSI-LD/ContextSource/Discovery/QueryContextSourceRegistrations/037_08.robot @@ -1,6 +1,7 @@ *** Settings *** Documentation Check that one can query context source registrations. If no temporal query is present, only Context Source Registrations for Context Sources providing latest information are considered +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextSourceDiscovery.resource Resource ${EXECDIR}/resources/ApiUtils/ContextSourceRegistration.resource Resource ${EXECDIR}/resources/AssertionUtils.resource @@ -11,7 +12,6 @@ Suite Teardown Delete Created Context Source Registration *** Variables *** -${context_source_registration_id_prefix}= urn:ngsi-ld:ContextSourceRegistration: ${context_source_registration_payload_file_path}= csourceRegistrations/context-source-registration.jsonld ${expectation_file_path}= csourceRegistrations/expectations/context-source-registrations-037-08.json @@ -31,7 +31,7 @@ ${expectation_file_path}= csourceRegistrations/exp *** Keywords *** Setup Initial Context Source Registration - ${context_source_registration_id}= Generate Random Entity Id ${context_source_registration_id_prefix} + ${context_source_registration_id}= Generate Random CSR Id ${context_source_registration_payload}= Load Test Sample ... ${context_source_registration_payload_file_path} ... ${context_source_registration_id} diff --git a/TP/NGSI-LD/ContextSource/Discovery/QueryContextSourceRegistrations/037_09.robot b/TP/NGSI-LD/ContextSource/Discovery/QueryContextSourceRegistrations/037_09.robot index 46fed3a957bd8b0075f8e34d67f4645de3bf4b85..7db27322bf0fdbcc299054fc16e9a9866b246054 100644 --- a/TP/NGSI-LD/ContextSource/Discovery/QueryContextSourceRegistrations/037_09.robot +++ b/TP/NGSI-LD/ContextSource/Discovery/QueryContextSourceRegistrations/037_09.robot @@ -1,6 +1,7 @@ *** Settings *** Documentation Check that one can query context source registrations. If present, the temporal query is matched against the observationInterval or the managementInterval +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextSourceDiscovery.resource Resource ${EXECDIR}/resources/ApiUtils/ContextSourceRegistration.resource Resource ${EXECDIR}/resources/AssertionUtils.resource @@ -11,7 +12,6 @@ Test Template Query Context Source Registration Matching Temporal Query *** Variables *** -${context_source_registration_id_prefix}= urn:ngsi-ld:ContextSourceRegistration: ${context_source_registration_observation_interval_payload_file_path}= csourceRegistrations/context-source-registration-observationInterval.jsonld ${context_source_registration_management_interval_payload_file_path}= csourceRegistrations/context-source-registration-managementInterval.jsonld ${observation_interval_expectation_file_path}= csourceRegistrations/expectations/context-source-registrations-037-09-01.json @@ -56,7 +56,7 @@ Query Context Source Registration Matching Temporal Query Setup Initial Context Source Registrations [Arguments] ${payload_file_path} - ${context_source_registration_id}= Generate Random Entity Id ${context_source_registration_id_prefix} + ${context_source_registration_id}= Generate Random CSR Id ${context_source_registration_payload}= Load Test Sample ... ${payload_file_path} ... ${context_source_registration_id} diff --git a/TP/NGSI-LD/ContextSource/Discovery/QueryContextSourceRegistrations/037_10.robot b/TP/NGSI-LD/ContextSource/Discovery/QueryContextSourceRegistrations/037_10.robot index 5d6010a8978878a0541c59749ac30ca53dcab4f9..799d58c37c46976dccec85923c5aae1042445491 100644 --- a/TP/NGSI-LD/ContextSource/Discovery/QueryContextSourceRegistrations/037_10.robot +++ b/TP/NGSI-LD/ContextSource/Discovery/QueryContextSourceRegistrations/037_10.robot @@ -1,6 +1,7 @@ *** Settings *** Documentation Check that one can query context source registrations. If present, the conditions specified by the context source query match the respective Context Source Properties +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextSourceDiscovery.resource Resource ${EXECDIR}/resources/ApiUtils/ContextSourceRegistration.resource Resource ${EXECDIR}/resources/AssertionUtils.resource @@ -12,7 +13,6 @@ Test Template Query Context Source Registration With Query Params *** Variables *** -${context_source_registration_id_prefix}= urn:ngsi-ld:ContextSourceRegistration: ${first_context_source_registration_payload_file_path}= csourceRegistrations/context-source-registration.jsonld ${second_context_source_registration_payload_file_path}= csourceRegistrations/context-source-registration-detailed-information.jsonld ${third_context_source_registration_payload_file_path}= csourceRegistrations/context-source-registration-csourceProperty.jsonld @@ -45,9 +45,9 @@ Query Context Source Registration With Query Params ... ${response.json()} Setup Initial Context Source Registrations - ${first_context_source_registration_id}= Generate Random Entity Id ${context_source_registration_id_prefix} - ${second_context_source_registration_id}= Generate Random Entity Id ${context_source_registration_id_prefix} - ${third_context_source_registration_id}= Generate Random Entity Id ${context_source_registration_id_prefix} + ${first_context_source_registration_id}= Generate Random CSR Id + ${second_context_source_registration_id}= Generate Random CSR Id + ${third_context_source_registration_id}= Generate Random CSR Id ${first_context_source_registration_payload}= Load Test Sample ... ${first_context_source_registration_payload_file_path} ... ${first_context_source_registration_id} diff --git a/TP/NGSI-LD/ContextSource/Discovery/QueryContextSourceRegistrations/037_11.robot b/TP/NGSI-LD/ContextSource/Discovery/QueryContextSourceRegistrations/037_11.robot index 5de8035b26c2b1b43e033158e58c22553620c091..d4d2796f1d782f24b2d5e748c0a44d409ef828a6 100644 --- a/TP/NGSI-LD/ContextSource/Discovery/QueryContextSourceRegistrations/037_11.robot +++ b/TP/NGSI-LD/ContextSource/Discovery/QueryContextSourceRegistrations/037_11.robot @@ -1,6 +1,7 @@ *** Settings *** Documentation Check that one can query context source registrations with providing page and limit parameters, pagination logic shall be in place as mandated by clause 5.5.9. +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextSourceDiscovery.resource Resource ${EXECDIR}/resources/ApiUtils/ContextSourceRegistration.resource Resource ${EXECDIR}/resources/AssertionUtils.resource @@ -12,7 +13,6 @@ Test Template Query Context Source Registration With Limit And Offset Para *** Variables *** -${context_source_registration_id_prefix}= urn:ngsi-ld:ContextSourceRegistration: ${first_context_source_registration_payload_file_path}= csourceRegistrations/context-source-registration.jsonld ${second_context_source_registration_payload_file_path}= csourceRegistrations/context-source-registration-location.jsonld ${third_context_source_registration_payload_file_path}= csourceRegistrations/context-source-registration-detailed-information.jsonld @@ -47,9 +47,9 @@ Query Context Source Registration With Limit And Offset Parameters Check Pagination Prev And Next Headers ${prev_link} ${next_link} ${response.json()} Setup Initial Context Source Registrations - ${first_context_source_registration_id}= Generate Random Entity Id ${context_source_registration_id_prefix} - ${second_context_source_registration_id}= Generate Random Entity Id ${context_source_registration_id_prefix} - ${third_context_source_registration_id}= Generate Random Entity Id ${context_source_registration_id_prefix} + ${first_context_source_registration_id}= Generate Random CSR Id + ${second_context_source_registration_id}= Generate Random CSR Id + ${third_context_source_registration_id}= Generate Random CSR Id ${first_context_source_registration_payload}= Load Test Sample ... ${first_context_source_registration_payload_file_path} ... ${first_context_source_registration_id} diff --git a/TP/NGSI-LD/ContextSource/Discovery/RetrieveContextSourceRegistration/036_03.robot b/TP/NGSI-LD/ContextSource/Discovery/RetrieveContextSourceRegistration/036_03.robot index 799b458ebcc5bd1ab43b45df48e73884b7e5e4b6..a71f978e1d32473d0cc49e13e30950a7f765ede3 100644 --- a/TP/NGSI-LD/ContextSource/Discovery/RetrieveContextSourceRegistration/036_03.robot +++ b/TP/NGSI-LD/ContextSource/Discovery/RetrieveContextSourceRegistration/036_03.robot @@ -1,6 +1,7 @@ *** Settings *** Documentation Check that one can retrieve a Context Source Registration. Term to URI expansion of Attribute names shall be observed. +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextSourceDiscovery.resource Resource ${EXECDIR}/resources/ApiUtils/ContextSourceRegistration.resource Resource ${EXECDIR}/resources/AssertionUtils.resource @@ -11,7 +12,6 @@ Suite Teardown Delete Created Context Source Registration *** Variables *** -${context_source_registration_id_prefix}= urn:ngsi-ld:ContextSourceRegistration: ${context_source_registration_payload_file_path}= csourceRegistrations/context-source-registration.jsonld ${expectation_file_path}= csourceRegistrations/expectations/context-source-registration-expanded-format.json @@ -31,7 +31,7 @@ ${expectation_file_path}= csourceRegistrations/exp *** Keywords *** Setup Initial Context Source Registration - ${context_source_registration_id}= Generate Random Entity Id ${context_source_registration_id_prefix} + ${context_source_registration_id}= Generate Random CSR Id ${context_source_registration_payload}= Load Test Sample ... ${context_source_registration_payload_file_path} ... ${context_source_registration_id} diff --git a/TP/NGSI-LD/ContextSource/Discovery/RetrieveContextSourceRegistration/036_04.robot b/TP/NGSI-LD/ContextSource/Discovery/RetrieveContextSourceRegistration/036_04.robot index 8036b1f1f3bd691c2a3d69c02c5f6b6aa31566d5..ed20f05bdb40f2896520947590aebbe5d0ef9c7c 100644 --- a/TP/NGSI-LD/ContextSource/Discovery/RetrieveContextSourceRegistration/036_04.robot +++ b/TP/NGSI-LD/ContextSource/Discovery/RetrieveContextSourceRegistration/036_04.robot @@ -1,6 +1,7 @@ *** Settings *** Documentation Check that one can retrieve a Context Source Registration +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextSourceDiscovery.resource Resource ${EXECDIR}/resources/ApiUtils/ContextSourceRegistration.resource Resource ${EXECDIR}/resources/AssertionUtils.resource @@ -11,7 +12,6 @@ Suite Teardown Delete Created Context Source Registration *** Variables *** -${context_source_registration_id_prefix}= urn:ngsi-ld:ContextSourceRegistration: ${context_source_registration_payload_file_path}= csourceRegistrations/context-source-registration.jsonld ${expectation_file_path}= csourceRegistrations/expectations/context-source-registration.json @@ -32,7 +32,7 @@ ${expectation_file_path}= csourceRegistrations/exp *** Keywords *** Setup Initial Context Source Registration - ${context_source_registration_id}= Generate Random Entity Id ${context_source_registration_id_prefix} + ${context_source_registration_id}= Generate Random CSR Id ${context_source_registration_payload}= Load Test Sample ... ${context_source_registration_payload_file_path} ... ${context_source_registration_id} diff --git a/TP/NGSI-LD/ContextSource/Discovery/RetrieveContextSourceRegistration/036_05.robot b/TP/NGSI-LD/ContextSource/Discovery/RetrieveContextSourceRegistration/036_05.robot index 5b4f372e6cb996840a3ec925f5c6f3a5958a9671..d143f9f22d52583ee84959c861ad9215525f04b8 100644 --- a/TP/NGSI-LD/ContextSource/Discovery/RetrieveContextSourceRegistration/036_05.robot +++ b/TP/NGSI-LD/ContextSource/Discovery/RetrieveContextSourceRegistration/036_05.robot @@ -1,6 +1,7 @@ *** Settings *** Documentation Check that the JSON-LD @context is obtained from a Link header if present and that the default JSON-LD @context is used if not present +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextSourceDiscovery.resource Resource ${EXECDIR}/resources/ApiUtils/ContextSourceRegistration.resource Resource ${EXECDIR}/resources/AssertionUtils.resource @@ -12,7 +13,6 @@ Test Template Review JSON-LD resolution when retrieving a context source r *** Variables *** -${context_source_registration_id_prefix}= urn:ngsi-ld:ContextSourceRegistration: ${context_source_registration_payload_file_path}= csourceRegistrations/context-source-registration.jsonld ${expectation_file_path_compacted}= csourceRegistrations/expectations/context-source-registration.json ${expectation_file_path_expanded}= csourceRegistrations/expectations/context-source-registration-expanded-format.json @@ -41,7 +41,7 @@ Review JSON-LD resolution when retrieving a context source registration ... ${response.json()} Setup Initial Context Source Registration - ${context_source_registration_id}= Generate Random Entity Id ${context_source_registration_id_prefix} + ${context_source_registration_id}= Generate Random CSR Id ${context_source_registration_payload}= Load Test Sample ... ${context_source_registration_payload_file_path} ... ${context_source_registration_id} diff --git a/TP/NGSI-LD/ContextSource/Registration/DeleteContextSourceRegistration/035_01.robot b/TP/NGSI-LD/ContextSource/Registration/DeleteContextSourceRegistration/035_01.robot index 08bdca8a75727a95b8d6908b72ad471efcb2be06..4db4751a9fafb58577abe3cf4fb879adc7eeb44d 100644 --- a/TP/NGSI-LD/ContextSource/Registration/DeleteContextSourceRegistration/035_01.robot +++ b/TP/NGSI-LD/ContextSource/Registration/DeleteContextSourceRegistration/035_01.robot @@ -1,6 +1,7 @@ *** Settings *** Documentation Check that one can delete a context source registration by id +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextSourceDiscovery.resource Resource ${EXECDIR}/resources/ApiUtils/ContextSourceRegistration.resource Resource ${EXECDIR}/resources/AssertionUtils.resource @@ -11,7 +12,6 @@ Test Teardown Delete Created Context Source Registrations *** Variables *** -${registration_id_prefix}= urn:ngsi-ld:Registration: ${registration_payload_file_path}= context-source-registration.jsonld @@ -31,7 +31,7 @@ ${registration_payload_file_path}= context-source-registration.jsonld *** Keywords *** Setup Initial Context Source Registrations - ${registration_id}= Generate Random Entity Id ${registration_id_prefix} + ${registration_id}= Generate Random CSR Id ${payload}= Load JSON From File ${EXECDIR}/data/csourceRegistrations/${registration_payload_file_path} ${updated_payload}= Update Value To JSON ${payload} $..id ${registration_id} ${create_response}= Create Context Source Registration With Return ${updated_payload} diff --git a/TP/NGSI-LD/ContextSource/Registration/DeleteContextSourceRegistration/035_02.robot b/TP/NGSI-LD/ContextSource/Registration/DeleteContextSourceRegistration/035_02.robot index fef11c197e5c47aa2945edf2aa5d49252b461817..5c808ab2b0bf1ac0be440a39d4139232e4c70391 100644 --- a/TP/NGSI-LD/ContextSource/Registration/DeleteContextSourceRegistration/035_02.robot +++ b/TP/NGSI-LD/ContextSource/Registration/DeleteContextSourceRegistration/035_02.robot @@ -1,6 +1,7 @@ *** Settings *** Documentation Check that one cannot delete a context source registration under some conditions +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextSourceRegistration.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -11,8 +12,7 @@ Test Template Delete A Context Source *** Variables *** -${registration_id_prefix}= urn:ngsi-ld:Registration: -${filename}= context-source-registration.jsonld +${filename}= context-source-registration.jsonld *** Test Cases *** INVALID_REGISTRATION_ID EXPECTED_STATUS_CODE PROBLEM_TYPE @@ -41,7 +41,7 @@ Delete Created Context Source Registrations Delete Context Source Registration ${registration_id} Create Initial Context Source Registration - ${registration_id}= Generate Random Entity Id ${registration_id_prefix} + ${registration_id}= Generate Random CSR Id Set Test Variable ${registration_id} ${payload}= Load JSON From File ${EXECDIR}/data/csourceRegistrations/${filename} ${updated_payload}= Update Value To JSON ${payload} $..id ${registration_id} diff --git a/TP/NGSI-LD/ContextSource/Registration/DeleteContextSourceRegistration/035_03.robot b/TP/NGSI-LD/ContextSource/Registration/DeleteContextSourceRegistration/035_03.robot index 444f867b7a40babcde0a6ed29d5fa8530202b8db..83edff3ea4902bfc68a7d33b9e10bc2e5d24084c 100644 --- a/TP/NGSI-LD/ContextSource/Registration/DeleteContextSourceRegistration/035_03.robot +++ b/TP/NGSI-LD/ContextSource/Registration/DeleteContextSourceRegistration/035_03.robot @@ -1,13 +1,13 @@ *** Settings *** Documentation Check that one cannot delete a context source registration by id if the id is not known to the system +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextSourceRegistration.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource *** Variables *** -${registration_id_prefix}= urn:ngsi-ld:Registration: ${registration_payload_file_path}= context-source-registration-simple.jsonld @@ -15,7 +15,7 @@ ${registration_payload_file_path}= context-source-registration-simple.jsonl 035_03_01 Delete a context source registration by id [Documentation] Check that one cannot delete a context source registration by id if the id is not known to the system [Tags] csr-delete 5_9_4 - ${registration_id}= Generate Random Entity Id ${registration_id_prefix} + ${registration_id}= Generate Random CSR Id ${response}= Delete Context Source Registration With Return ${registration_id} Check Response Status Code 404 ${response.status_code} Check Response Body Containing ProblemDetails Element Containing Title Element ${response.json()} diff --git a/TP/NGSI-LD/ContextSource/Registration/RegisterContextSource/033_01_01.robot b/TP/NGSI-LD/ContextSource/Registration/RegisterContextSource/033_01_01.robot index ac196405b723df21776f3cccd23474387c00246c..7d8cd53182d03e0cd998faab47a8c6e00f388ccd 100644 --- a/TP/NGSI-LD/ContextSource/Registration/RegisterContextSource/033_01_01.robot +++ b/TP/NGSI-LD/ContextSource/Registration/RegisterContextSource/033_01_01.robot @@ -1,6 +1,7 @@ *** Settings *** Documentation Check that one can create a context source registration with specific ID and expiration date +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextSourceDiscovery.resource Resource ${EXECDIR}/resources/ApiUtils/ContextSourceRegistration.resource Resource ${EXECDIR}/resources/AssertionUtils.resource @@ -10,7 +11,6 @@ Suite Teardown Delete Created Context Source Registrations *** Variables *** -${registration_id_prefix}= urn:ngsi-ld:Registration: ${registration_payload_file_path}= csourceRegistrations/context-source-registration-with-expiration.jsonld @@ -18,7 +18,7 @@ ${registration_payload_file_path}= csourceRegistrations/context-source-regi 033_01_01 Create Context Source Registration With Specific Date Expiration Date [Documentation] Check that one can create a context source registration with specific ID and expiration date [Tags] csr-create 5_9_2 - ${registration_id}= Generate Random Entity Id ${registration_id_prefix} + ${registration_id}= Generate Random CSR Id Set Suite Variable ${registration_id} ${payload}= Load JSON From File ${EXECDIR}/data/${registration_payload_file_path} ${registration_payload}= Update Value To JSON ${payload} $..id ${registration_id} diff --git a/TP/NGSI-LD/ContextSource/Registration/RegisterContextSource/033_01_02.robot b/TP/NGSI-LD/ContextSource/Registration/RegisterContextSource/033_01_02.robot index 236dc7e6fa468d120524a2a222444af7ef9e9235..71ef3c4cd65b952ee3957706f114cc48d0043de5 100644 --- a/TP/NGSI-LD/ContextSource/Registration/RegisterContextSource/033_01_02.robot +++ b/TP/NGSI-LD/ContextSource/Registration/RegisterContextSource/033_01_02.robot @@ -1,8 +1,9 @@ *** Settings *** Documentation Check that one can create a context source registration that never expires -Resource ${EXECDIR}/resources/ApiUtils/ContextSourceRegistration.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextSourceDiscovery.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextSourceRegistration.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -10,7 +11,6 @@ Suite Teardown Delete Created Context Source Registrations *** Variables *** -${registration_id_prefix}= urn:ngsi-ld:Registration: ${registration_payload_file_path}= csourceRegistrations/context-source-registration.jsonld @@ -18,7 +18,7 @@ ${registration_payload_file_path}= csourceRegistrations/context-source-regi 033_01_02 Create Context Source Registration That Never Expires [Documentation] Check that one can create a context source registration that never expires [Tags] csr-create 5_9_2 - ${registration_id}= Generate Random Entity Id ${registration_id_prefix} + ${registration_id}= Generate Random CSR Id Set Suite Variable ${registration_id} ${payload}= Load JSON From File ${EXECDIR}/data/${registration_payload_file_path} ${registration_payload}= Update Value To JSON ${payload} $..id ${registration_id} diff --git a/TP/NGSI-LD/ContextSource/Registration/RegisterContextSource/033_01_03.robot b/TP/NGSI-LD/ContextSource/Registration/RegisterContextSource/033_01_03.robot index 55d7e7938949e53cc33d2a0f4277af045f4d2608..0f3974d159d1c2a68fb845839a413ffde1422943 100644 --- a/TP/NGSI-LD/ContextSource/Registration/RegisterContextSource/033_01_03.robot +++ b/TP/NGSI-LD/ContextSource/Registration/RegisterContextSource/033_01_03.robot @@ -1,8 +1,8 @@ *** Settings *** Documentation Check that one can create a context source registration without specifying an ID -Resource ${EXECDIR}/resources/ApiUtils/ContextSourceRegistration.resource Resource ${EXECDIR}/resources/ApiUtils/ContextSourceDiscovery.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextSourceRegistration.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -10,7 +10,6 @@ Suite Teardown Delete Created Context Source Registrations *** Variables *** -${registration_id_prefix}= urn:ngsi-ld:Registration: ${registration_payload_file_path}= csourceRegistrations/context-source-registration-no-id.jsonld diff --git a/TP/NGSI-LD/ContextSource/Registration/RegisterContextSource/033_02.robot b/TP/NGSI-LD/ContextSource/Registration/RegisterContextSource/033_02.robot index b68aee121b7218a3edacc68a84d0bd87037d5b23..03cfae80265def475e4619229ceb35a19614f1fb 100644 --- a/TP/NGSI-LD/ContextSource/Registration/RegisterContextSource/033_02.robot +++ b/TP/NGSI-LD/ContextSource/Registration/RegisterContextSource/033_02.robot @@ -8,7 +8,6 @@ Library OperatingSystem *** Variables *** -${registration_id_prefix}= urn:ngsi-ld:Registration: ${registration_payload_file_path}= csourceRegistrations/context-source-registration-invalid.jsonld diff --git a/TP/NGSI-LD/ContextSource/Registration/RegisterContextSource/033_03.robot b/TP/NGSI-LD/ContextSource/Registration/RegisterContextSource/033_03.robot index cc2b14ded168085cc8696c09a9bb79a8ab83d3ff..2be02a34ee6742a02c1966eb9ee657f37103cd0d 100644 --- a/TP/NGSI-LD/ContextSource/Registration/RegisterContextSource/033_03.robot +++ b/TP/NGSI-LD/ContextSource/Registration/RegisterContextSource/033_03.robot @@ -1,6 +1,7 @@ *** Settings *** Documentation Check that one cannot create a context source registration that already exists +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextSourceRegistration.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -10,8 +11,7 @@ Test Teardown Delete Created Context Source Registrations *** Variables *** -${registration_id_prefix}= urn:ngsi-ld:Registration: -${filename}= csourceRegistrations/context-source-registration.jsonld +${filename}= csourceRegistrations/context-source-registration.jsonld *** Test Cases *** @@ -28,7 +28,7 @@ Delete Created Context Source Registrations Delete Context Source Registration ${registration_id} Create New Context Source Registration - ${registration_id}= Generate Random Entity Id ${registration_id_prefix} + ${registration_id}= Generate Random CSR Id Set Test Variable ${registration_id} ${payload}= Load JSON From File ${EXECDIR}/data/${filename} ${updated_payload}= Update Value To JSON ${payload} $..id ${registration_id} diff --git a/TP/NGSI-LD/ContextSource/Registration/RegisterContextSource/033_04.robot b/TP/NGSI-LD/ContextSource/Registration/RegisterContextSource/033_04.robot index 57019f01edc80b65cf027356219706654034096f..764c9c518ec0c0208963db3ae4055a6dba356f7b 100644 --- a/TP/NGSI-LD/ContextSource/Registration/RegisterContextSource/033_04.robot +++ b/TP/NGSI-LD/ContextSource/Registration/RegisterContextSource/033_04.robot @@ -1,8 +1,9 @@ *** Settings *** Documentation Check that the @context is obtained from a Link Header if the Content-Type header is "application/json" -Resource ${EXECDIR}/resources/ApiUtils/ContextSourceRegistration.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextSourceDiscovery.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextSourceRegistration.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -10,7 +11,6 @@ Suite Teardown Delete Created Context Source Registrations *** Variables *** -${registration_id_prefix}= urn:ngsi-ld:Registration: ${registration_payload_file_path}= csourceRegistrations/context-source-registration.json @@ -18,7 +18,7 @@ ${registration_payload_file_path}= csourceRegistrations/context-source-regi 033_04_01 Create one context source registration using a provided Link header with JSON content type with Context [Documentation] Check that the @context is obtained from a Link Header if the Content-Type header is "application/json" [Tags] csr-create 6_3_5 - ${registration_id}= Generate Random Entity Id ${registration_id_prefix} + ${registration_id}= Generate Random CSR Id Set Suite Variable ${registration_id} ${payload}= Load JSON From File ${EXECDIR}/data/${registration_payload_file_path} ${updated_payload}= Update Value To JSON ${payload} $..id ${registration_id} @@ -38,7 +38,7 @@ ${registration_payload_file_path}= csourceRegistrations/context-source-regi 033_04_02 Create one context source registration using a provided Link header with JSON content type without Context [Documentation] Check that the @context is obtained from a Link Header if the Content-Type header is "application/json" [Tags] csr-create 6_3_5 - ${registration_id}= Generate Random Entity Id ${registration_id_prefix} + ${registration_id}= Generate Random CSR Id Set Suite Variable ${registration_id} ${payload}= Load JSON From File ${EXECDIR}/data/${registration_payload_file_path} ${updated_payload}= Update Value To JSON ${payload} $..id ${registration_id} diff --git a/TP/NGSI-LD/ContextSource/Registration/RegisterContextSource/033_05.robot b/TP/NGSI-LD/ContextSource/Registration/RegisterContextSource/033_05.robot index a53ca256c72970d58ae59cbc152793644412a42e..4732aea516c2ee3a9109a03e5f80f6dad83ab3ff 100644 --- a/TP/NGSI-LD/ContextSource/Registration/RegisterContextSource/033_05.robot +++ b/TP/NGSI-LD/ContextSource/Registration/RegisterContextSource/033_05.robot @@ -1,8 +1,9 @@ *** Settings *** Documentation Check that the default @context is used if the Content-Type header is "application/json" and the Link header does not contain a JSON-LD @context -Resource ${EXECDIR}/resources/ApiUtils/ContextSourceRegistration.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextSourceDiscovery.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextSourceRegistration.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -10,7 +11,6 @@ Suite Teardown Delete Created Context Source Registrations *** Variables *** -${registration_id_prefix}= urn:ngsi-ld:Registration: ${registration_payload_file_path}= csourceRegistrations/context-source-registration.json @@ -18,7 +18,7 @@ ${registration_payload_file_path}= csourceRegistrations/context-source-regi 033_05_01 Create one context source registration using the default context with JSON content type with Context [Documentation] Check that the default @context is used if the Content-Type header is "application/json" and the Link header does not contain a JSON-LD @context and retrieve the information with ngsild context [Tags] csr-create 6_3_5 - ${registration_id}= Generate Random Entity Id ${registration_id_prefix} + ${registration_id}= Generate Random CSR Id Set Suite Variable ${registration_id} ${payload}= Load JSON From File ${EXECDIR}/data/${registration_payload_file_path} ${updated_payload}= Update Value To JSON ${payload} $..id ${registration_id} @@ -37,7 +37,7 @@ ${registration_payload_file_path}= csourceRegistrations/context-source-regi 033_05_02 Create one context source registration using the default context with JSON content type without Context [Documentation] Check that the default @context is used if the Content-Type header is "application/json" and the Link header does not contain a JSON-LD @context and retrieve the information without ngsild context [Tags] csr-create 6_3_5 - ${registration_id}= Generate Random Entity Id ${registration_id_prefix} + ${registration_id}= Generate Random CSR Id Set Suite Variable ${registration_id} ${payload}= Load JSON From File ${EXECDIR}/data/${registration_payload_file_path} ${updated_payload}= Update Value To JSON ${payload} $..id ${registration_id} diff --git a/TP/NGSI-LD/ContextSource/Registration/RegisterContextSource/033_06.robot b/TP/NGSI-LD/ContextSource/Registration/RegisterContextSource/033_06.robot index 660538a5974907780c937bd233f65e69a77ef9fd..14068f2ef1e819eb2238d7e538fdd42bebe75fbe 100644 --- a/TP/NGSI-LD/ContextSource/Registration/RegisterContextSource/033_06.robot +++ b/TP/NGSI-LD/ContextSource/Registration/RegisterContextSource/033_06.robot @@ -1,13 +1,13 @@ *** Settings *** Documentation Check that an HTTP error response of type BadRequestData is raised if the Content-Type header is "application/json" and the request payload body (as JSON) contains a "@context" term +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextSourceRegistration.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource *** Variables *** -${registration_id_prefix}= urn:ngsi-ld:Registration: ${registration_payload_file_path}= csourceRegistrations/context-source-registration.jsonld @@ -15,7 +15,7 @@ ${registration_payload_file_path}= csourceRegistrations/context-source-regi 033_06_01 Create one context source registration containing a JSON-LD @context with a JSON content type [Documentation] Check that an HTTP error response of type BadRequestData is raised if the Content-Type header is "application/json" and the request payload body (as JSON) contains a "@context" term [Tags] csr-create 6_3_5 - ${registration_id}= Generate Random Entity Id ${registration_id_prefix} + ${registration_id}= Generate Random CSR Id ${payload}= Load JSON From File ${EXECDIR}/data/${registration_payload_file_path} ${updated_payload}= Update Value To JSON ${payload} $..id ${registration_id} ${response}= Create Context Source Registration With Return diff --git a/TP/NGSI-LD/ContextSource/Registration/RegisterContextSource/033_07.robot b/TP/NGSI-LD/ContextSource/Registration/RegisterContextSource/033_07.robot index 74754b15831935f123cdfdc7612d1597ca3fa7f0..ed0689e12527c280abc2f95913f059bca0d6a3d0 100644 --- a/TP/NGSI-LD/ContextSource/Registration/RegisterContextSource/033_07.robot +++ b/TP/NGSI-LD/ContextSource/Registration/RegisterContextSource/033_07.robot @@ -1,8 +1,9 @@ *** Settings *** Documentation Check that the @context is obtained from the request payload body itself if the Content-Type header is "application/ld+json" -Resource ${EXECDIR}/resources/ApiUtils/ContextSourceRegistration.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextSourceDiscovery.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextSourceRegistration.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -10,7 +11,6 @@ Suite Teardown Delete Created Context Source Registrations *** Variables *** -${registration_id_prefix}= urn:ngsi-ld:Registration: ${registration_payload_file_path}= csourceRegistrations/context-source-registration.jsonld @@ -18,7 +18,7 @@ ${registration_payload_file_path}= csourceRegistrations/context-source-regi 033_07_01 Create one context source registration using a JSON-LD @context obtained from the request payload with Context [Documentation] Check that the @context is obtained from the request payload body itself if the Content-Type header is "application/ld+json" and retrieve the information with ngsild context [Tags] csr-create 6_3_5 - ${registration_id}= Generate Random Entity Id ${registration_id_prefix} + ${registration_id}= Generate Random CSR Id Set Suite Variable ${registration_id} ${payload}= Load JSON From File ${EXECDIR}/data/${registration_payload_file_path} ${updated_payload}= Update Value To JSON ${payload} $.id ${registration_id} @@ -37,7 +37,7 @@ ${registration_payload_file_path}= csourceRegistrations/context-source-regi 033_07_02 Create one context source registration using a JSON-LD @context obtained from the request payload without Context [Documentation] Check that the @context is obtained from the request payload body itself if the Content-Type header is "application/ld+json" and retrieve the information without ngsild context [Tags] csr-create 6_3_5 - ${registration_id}= Generate Random Entity Id ${registration_id_prefix} + ${registration_id}= Generate Random CSR Id Set Suite Variable ${registration_id} ${payload}= Load JSON From File ${EXECDIR}/data/${registration_payload_file_path} ${updated_payload}= Update Value To JSON ${payload} $.id ${registration_id} diff --git a/TP/NGSI-LD/ContextSource/Registration/RegisterContextSource/033_08.robot b/TP/NGSI-LD/ContextSource/Registration/RegisterContextSource/033_08.robot index e1fda05567832616b678a66d0babb999d8454004..58e047144cad52434b56e6179506d1abe8fe7d66 100644 --- a/TP/NGSI-LD/ContextSource/Registration/RegisterContextSource/033_08.robot +++ b/TP/NGSI-LD/ContextSource/Registration/RegisterContextSource/033_08.robot @@ -1,13 +1,13 @@ *** Settings *** Documentation Check that an HTTP error response of type BadRequestData is raised if the Content-Type header is "application/ld+json" and the request payload body does not contain a @context term +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextSourceRegistration.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource *** Variables *** -${registration_id_prefix}= urn:ngsi-ld:Registration: ${registration_payload_file_path}= csourceRegistrations/context-source-registration.json @@ -15,7 +15,7 @@ ${registration_payload_file_path}= csourceRegistrations/context-source-regi 033_08_01 Create one context source registration not containing a JSON-LD @context with a JSON-LD content type [Documentation] Check that an HTTP error response of type BadRequestData is raised if the Content-Type header is "application/ld+json" and the request payload body does not contain a @context term [Tags] csr-create 6_3_5 - ${registration_id}= Generate Random Entity Id ${registration_id_prefix} + ${registration_id}= Generate Random CSR Id ${payload}= Load JSON From File ${EXECDIR}/data/${registration_payload_file_path} ${updated_payload}= Update Value To JSON ${payload} $..id ${registration_id} ${response}= Create Context Source Registration With Return diff --git a/TP/NGSI-LD/ContextSource/Registration/RegisterContextSource/033_09.robot b/TP/NGSI-LD/ContextSource/Registration/RegisterContextSource/033_09.robot index e7c14fc04b40725557eb2af70ff80a0a2f1cf6cf..fab0da5a7297cfcefaa952455cad49614df94fda 100644 --- a/TP/NGSI-LD/ContextSource/Registration/RegisterContextSource/033_09.robot +++ b/TP/NGSI-LD/ContextSource/Registration/RegisterContextSource/033_09.robot @@ -1,13 +1,13 @@ *** Settings *** Documentation Check that an HTTP error response of type BadRequestData is raised if the Content-Type header is "application/ld+json" and a JSON-LD Link header is present in the incoming HTTP request +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextSourceRegistration.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource *** Variables *** -${registration_id_prefix}= urn:ngsi-ld:Registration: ${registration_payload_file_path}= csourceRegistrations/context-source-registration.jsonld @@ -15,7 +15,7 @@ ${registration_payload_file_path}= csourceRegistrations/context-source-regi 033_09_01 Create one context source registration with a Link header and a JSON-LD content type [Documentation] Check that an HTTP error response of type BadRequestData is raised if the Content-Type header is "application/ld+json" and a JSON-LD Link header is present in the incoming HTTP request [Tags] csr-create 6_3_5 - ${registration_id}= Generate Random Entity Id ${registration_id_prefix} + ${registration_id}= Generate Random CSR Id ${payload}= Load JSON From File ${EXECDIR}/data/${registration_payload_file_path} ${updated_payload}= Update Value To JSON ${payload} $..id ${registration_id} ${response}= Create Context Source Registration With Return diff --git a/TP/NGSI-LD/ContextSource/Registration/RegisterContextSource/033_10.robot b/TP/NGSI-LD/ContextSource/Registration/RegisterContextSource/033_10.robot index 280fb4ddcca730bc65a891b9afbeac402869e853..cb68ada92a731d1046ce74f7e4620c9fe8d79a99 100644 --- a/TP/NGSI-LD/ContextSource/Registration/RegisterContextSource/033_10.robot +++ b/TP/NGSI-LD/ContextSource/Registration/RegisterContextSource/033_10.robot @@ -1,6 +1,7 @@ *** Settings *** Documentation Check that one cannot create a context source with invalid content +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextSourceRegistration.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -8,10 +9,6 @@ Resource ${EXECDIR}/resources/JsonUtils.resource Test Template Create Context Source With Invalid Content -*** Variables *** -${registration_id_prefix}= urn:ngsi-ld:Registration: - - *** Test Cases *** 033_10_01 Create a context source registration with a different data structure than CSourceRegistration data type csourceRegistrations/context-source-registration-invalid-structure.jsonld @@ -24,7 +21,7 @@ Create Context Source With Invalid Content [Documentation] Check that one cannot create a context source with invalid content [Tags] csr-create 6_3_5 [Arguments] ${filename} - ${registration_id}= Generate Random Entity Id ${registration_id_prefix} + ${registration_id}= Generate Random CSR Id ${payload}= Load JSON From File ${EXECDIR}/data/${filename} ${updated_payload}= Update Value To JSON ${payload} $..id ${registration_id} ${response}= Create Context Source Registration With Return ${updated_payload} diff --git a/TP/NGSI-LD/ContextSource/Registration/UpdateContextSourceRegistration/034_01.robot b/TP/NGSI-LD/ContextSource/Registration/UpdateContextSourceRegistration/034_01.robot index a28c07efd0cd33f3ab046a70e9c9abd454125d69..fb70435691a24b6e9268f4d9491a0c6e2d106484 100644 --- a/TP/NGSI-LD/ContextSource/Registration/UpdateContextSourceRegistration/034_01.robot +++ b/TP/NGSI-LD/ContextSource/Registration/UpdateContextSourceRegistration/034_01.robot @@ -1,8 +1,9 @@ *** Settings *** Documentation Check that one can update a context source registration by id -Resource ${EXECDIR}/resources/ApiUtils/ContextSourceRegistration.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextSourceDiscovery.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextSourceRegistration.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -11,10 +12,6 @@ Test Teardown Delete Updated Context Source Registration Test Template Update A Context Source -*** Variables *** -${registration_id_prefix}= urn:ngsi-ld:Registration: - - *** Test Cases *** FILENAME UPDATE_FILENAME 034_01_01 Update a context source registration by id [Tags] csr-update 5_9_3 @@ -44,7 +41,7 @@ Delete Updated Context Source Registration Delete Context Source Registration ${registration_id} Initialize the Test Case - ${registration_id}= Generate Random Entity Id ${registration_id_prefix} + ${registration_id}= Generate Random CSR Id Set Test Variable ${registration_id} ${payload}= Load JSON From File ... ${EXECDIR}/data/csourceRegistrations/context-source-registration.jsonld diff --git a/TP/NGSI-LD/ContextSource/Registration/UpdateContextSourceRegistration/034_02.robot b/TP/NGSI-LD/ContextSource/Registration/UpdateContextSourceRegistration/034_02.robot index 30f2a85a6788880c1baa8aba771a3842a59ea413..ea7c96136868ad20b572be246e5880ac0f2dc584 100644 --- a/TP/NGSI-LD/ContextSource/Registration/UpdateContextSourceRegistration/034_02.robot +++ b/TP/NGSI-LD/ContextSource/Registration/UpdateContextSourceRegistration/034_02.robot @@ -1,6 +1,7 @@ *** Settings *** Documentation Check that one cannot update a context source registration under some conditions +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextSourceRegistration.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -11,7 +12,6 @@ Test Template Update A Context Source *** Variables *** -${registration_id_prefix}= urn:ngsi-ld:Registration: ${filename}= context-source-registration.jsonld ${registration_payload_file_path}= context-source-registration-invalid.jsonld ${reason_400}= Bad Request @@ -42,7 +42,7 @@ Update A Context Source Check Response Body Containing ProblemDetails Element ${response.json()} ${problem_type} Create Initial Context Source Registration - ${valid_registration_id}= Generate Random Entity Id ${registration_id_prefix} + ${valid_registration_id}= Generate Random CSR Id Set Suite Variable ${valid_registration_id} ${payload}= Load JSON From File ${EXECDIR}/data/csourceRegistrations/${filename} ${updated_payload}= Update Value To JSON ${payload} $.id ${valid_registration_id} diff --git a/TP/NGSI-LD/ContextSource/Registration/UpdateContextSourceRegistration/034_03.robot b/TP/NGSI-LD/ContextSource/Registration/UpdateContextSourceRegistration/034_03.robot index 9505f6fa14ae0f1a9af4cb9f9cdcac4339a64bb8..bd0b6525822ecb66f9df42b5be5e8d957f47666d 100644 --- a/TP/NGSI-LD/ContextSource/Registration/UpdateContextSourceRegistration/034_03.robot +++ b/TP/NGSI-LD/ContextSource/Registration/UpdateContextSourceRegistration/034_03.robot @@ -1,22 +1,22 @@ *** Settings *** Documentation Check that one cannot update a context source registration by id if the id is not known to the system +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextSourceRegistration.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource *** Variables *** -${registration_id_prefix}= urn:ngsi-ld:Registration: -${filename}= context-source-registration.jsonld -${reason_404}= Not Found +${filename}= context-source-registration.jsonld +${reason_404}= Not Found *** Test Cases *** 034_03_01 Update a context source registration by id if the id is not known to the system [Documentation] Check that one cannot update a context source registration by id if the id is not known to the system [Tags] csr-update 5_9_3 - ${registration_id}= Generate Random Entity Id ${registration_id_prefix} + ${registration_id}= Generate Random CSR Id Set Suite Variable ${registration_id} ${fragment}= Load JSON From File ${EXECDIR}/data/csourceRegistrations/${filename} ${fragment_with_id}= Update Value To JSON ${fragment} $.id ${registration_id} diff --git a/TP/NGSI-LD/ContextSource/Registration/UpdateContextSourceRegistration/034_04.robot b/TP/NGSI-LD/ContextSource/Registration/UpdateContextSourceRegistration/034_04.robot index 7f71d98dd2d4f615d27975d701ed34c81acf0ba5..482aacd5524c0bc930916cfe268c71bb97ad36c1 100644 --- a/TP/NGSI-LD/ContextSource/Registration/UpdateContextSourceRegistration/034_04.robot +++ b/TP/NGSI-LD/ContextSource/Registration/UpdateContextSourceRegistration/034_04.robot @@ -1,6 +1,7 @@ *** Settings *** Documentation Check that one cannot update a context source registration under some conditions +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextSourceRegistration.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -10,7 +11,6 @@ Test Teardown Delete Initial Context Source Registration *** Variables *** -${registration_id_prefix}= urn:ngsi-ld:Registration: ${filename}= context-source-registration.jsonld ${registration_payload_file_path}= context-source-registration-invalid-json.json @@ -29,9 +29,9 @@ ${registration_payload_file_path}= context-source-registration-invalid-json *** Keywords *** Create Initial Context Source Registration - ${valid_registration_id}= Generate Random Entity Id ${registration_id_prefix} + ${valid_registration_id}= Generate Random CSR Id Set Test Variable ${valid_registration_id} - ${registration_id}= Generate Random Entity Id ${registration_id_prefix} + ${registration_id}= Generate Random CSR Id Set Test Variable ${registration_id} ${payload}= Load JSON From File ${EXECDIR}/data/csourceRegistrations/${filename} ${updated_payload}= Update Value To JSON ${payload} $.id ${registration_id} diff --git a/TP/NGSI-LD/ContextSource/Registration/UpdateContextSourceRegistration/034_05.robot b/TP/NGSI-LD/ContextSource/Registration/UpdateContextSourceRegistration/034_05.robot index 58a12db0bb467e31fc9fcbfcdcdc3c3e4464aa69..2d4b4e7f4def39b357ae31fcb9a1857bd135725f 100644 --- a/TP/NGSI-LD/ContextSource/Registration/UpdateContextSourceRegistration/034_05.robot +++ b/TP/NGSI-LD/ContextSource/Registration/UpdateContextSourceRegistration/034_05.robot @@ -1,8 +1,9 @@ *** Settings *** Documentation Check that one can update a context source registration by id -Resource ${EXECDIR}/resources/ApiUtils/ContextSourceRegistration.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextSourceDiscovery.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextSourceRegistration.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -11,10 +12,6 @@ Test Teardown Delete Updated Context Source Registration Test Template Update A Context Source -*** Variables *** -${registration_id_prefix}= urn:ngsi-ld:Registration: - - *** Test Cases *** FILENAME UPDATE_FILENAME 034_05_01 Update a context source registration to never expire [Tags] csr-update 5_9_3 @@ -43,7 +40,7 @@ Delete Updated Context Source Registration Delete Context Source Registration ${registration_id} Initialize the Test Case - ${registration_id}= Generate Random Entity Id ${registration_id_prefix} + ${registration_id}= Generate Random CSR Id Set Test Variable ${registration_id} ${payload}= Load JSON From File ... ${EXECDIR}/data/csourceRegistrations/context-source-registration.jsonld diff --git a/TP/NGSI-LD/ContextSource/Registration/UpdateContextSourceRegistration/034_06.robot b/TP/NGSI-LD/ContextSource/Registration/UpdateContextSourceRegistration/034_06.robot index e1383a393786918afbf62e6b104887a084bf2bdf..050817ac842f8b1f03ce432fc5f7b20b7af31183 100644 --- a/TP/NGSI-LD/ContextSource/Registration/UpdateContextSourceRegistration/034_06.robot +++ b/TP/NGSI-LD/ContextSource/Registration/UpdateContextSourceRegistration/034_06.robot @@ -1,6 +1,7 @@ *** Settings *** Documentation Check that one cannot update a context source registration if the Id is not present +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextSourceRegistration.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -11,7 +12,6 @@ Test Template Update A Context Source *** Variables *** -${registration_id_prefix}= urn:ngsi-ld:Registration: ${filename}= context-source-registration.jsonld ${registration_payload_file_path}= context-source-registration-invalid.jsonld ${reason_405}= Method Not Allowed @@ -38,7 +38,7 @@ Update A Context Source Check Response Does Not Contain Body ${response} Create Initial Context Source Registration - ${valid_registration_id}= Generate Random Entity Id ${registration_id_prefix} + ${valid_registration_id}= Generate Random CSR Id Set Suite Variable ${valid_registration_id} ${payload}= Load JSON From File ${EXECDIR}/data/csourceRegistrations/${filename} ${updated_payload}= Update Value To JSON ${payload} $.id ${valid_registration_id} diff --git a/TP/NGSI-LD/ContextSource/RegistrationSubscription/ContextSourceRegistrationSubscriptionNotificationBehaviour/047_01.robot b/TP/NGSI-LD/ContextSource/RegistrationSubscription/ContextSourceRegistrationSubscriptionNotificationBehaviour/047_01.robot index 60ec465938130dc9a73f9d9dddca56bb0325c982..8049e275a5a6aa88a729321daabdcc1dba053a0b 100644 --- a/TP/NGSI-LD/ContextSource/RegistrationSubscription/ContextSourceRegistrationSubscriptionNotificationBehaviour/047_01.robot +++ b/TP/NGSI-LD/ContextSource/RegistrationSubscription/ContextSourceRegistrationSubscriptionNotificationBehaviour/047_01.robot @@ -1,8 +1,9 @@ *** Settings *** Documentation Check that if the created context source registration subscription defines a timeInterval member, a cSourceNotification will be sent periodically, initially on subscription and when the time interval is reached -Resource ${EXECDIR}/resources/ApiUtils/ContextSourceRegistrationSubscription.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextSourceRegistration.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextSourceRegistrationSubscription.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource Resource ${EXECDIR}/resources/NotificationUtils.resource @@ -12,8 +13,6 @@ Suite Teardown Delete Created Context Source Registration And Subscription *** Variables *** -${context_source_registration_id_prefix}= urn:ngsi-ld:ContextSourceRegistration: -${subscription_id_prefix}= urn:ngsi-ld:Subscription: ${context_source_registration_payload_file_path}= csourceRegistrations/context-source-registration.jsonld ${subscription_payload_file_path}= csourceSubscriptions/subscription-timeInterval.jsonld @@ -22,7 +21,7 @@ ${subscription_payload_file_path}= csourceSubscriptions/sub 047_01_01 Receive cSourceNotification Periodically And Initially On Subscription [Documentation] Check that if the created context source registration subscription defines a timeInterval member, a cSourceNotification will be sent periodically, initially on subscription and when the time interval is reached [Tags] csrsub-notification 5_11_7 - ${subscription_id}= Generate Random Entity Id ${subscription_id_prefix} + ${subscription_id}= Generate Random Subscription Id ${subscription_payload}= Load Subscription Sample With Reachable Endpoint ... ${subscription_payload_file_path} ... ${subscription_id} @@ -35,7 +34,7 @@ ${subscription_payload_file_path}= csourceSubscriptions/sub *** Keywords *** Setup Initial Context Source Registration Start Local Server - ${context_source_registration_id}= Generate Random Entity Id ${context_source_registration_id_prefix} + ${context_source_registration_id}= Generate Random CSR Id ${context_source_registration_payload}= Load Test Sample ... ${context_source_registration_payload_file_path} ... ${context_source_registration_id} diff --git a/TP/NGSI-LD/ContextSource/RegistrationSubscription/ContextSourceRegistrationSubscriptionNotificationBehaviour/047_02.robot b/TP/NGSI-LD/ContextSource/RegistrationSubscription/ContextSourceRegistrationSubscriptionNotificationBehaviour/047_02.robot index 6b92474acecdda74718def87b72fb1e5ee1c1564..8b7866e0e0fa56aba910057a95a6590f9b035378 100644 --- a/TP/NGSI-LD/ContextSource/RegistrationSubscription/ContextSourceRegistrationSubscriptionNotificationBehaviour/047_02.robot +++ b/TP/NGSI-LD/ContextSource/RegistrationSubscription/ContextSourceRegistrationSubscriptionNotificationBehaviour/047_02.robot @@ -1,8 +1,9 @@ *** Settings *** Documentation Check that if the created context source registration subscription does not define a timeInterval member, a cSourceNotification, with the appropriate trigger reason in the "triggerReason" member, will be sent initially on subscription and whenever there is a change of a matching Context Source Registration -Resource ${EXECDIR}/resources/ApiUtils/ContextSourceRegistrationSubscription.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextSourceRegistration.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextSourceRegistrationSubscription.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource Resource ${EXECDIR}/resources/NotificationUtils.resource @@ -12,8 +13,6 @@ Test Teardown Delete Created Context Source Registration And Context Sourc *** Variables *** -${context_source_registration_id_prefix}= urn:ngsi-ld:ContextSourceRegistration: -${subscription_id_prefix}= urn:ngsi-ld:Subscription: ${context_source_registration_payload_file_path}= csourceRegistrations/context-source-registration.jsonld ${subscription_payload_file_path}= csourceSubscriptions/subscription.jsonld ${update_fragment_file_path}= csourceRegistrations/fragments/context-source-registration-update.json @@ -35,8 +34,8 @@ ${update_fragment_file_path}= csourceRegistrations/fra Create Initial Context Source Registration and Context Source Registration Subscription Start Local Server - ${context_source_registration_id}= Generate Random Entity Id ${context_source_registration_id_prefix} - ${subscription_id}= Generate Random Entity Id ${subscription_id_prefix} + ${context_source_registration_id}= Generate Random CSR Id + ${subscription_id}= Generate Random Subscription Id Set Suite Variable ${context_source_registration_id} Set Suite Variable ${subscription_id} diff --git a/TP/NGSI-LD/ContextSource/RegistrationSubscription/ContextSourceRegistrationSubscriptionNotificationBehaviour/047_03.robot b/TP/NGSI-LD/ContextSource/RegistrationSubscription/ContextSourceRegistrationSubscriptionNotificationBehaviour/047_03.robot index 748b0d27c51373ddce3a03423f431e3c2c286b7f..aba0140ad1ee1d5d801849c59126b76322de8e42 100644 --- a/TP/NGSI-LD/ContextSource/RegistrationSubscription/ContextSourceRegistrationSubscriptionNotificationBehaviour/047_03.robot +++ b/TP/NGSI-LD/ContextSource/RegistrationSubscription/ContextSourceRegistrationSubscriptionNotificationBehaviour/047_03.robot @@ -1,8 +1,9 @@ *** Settings *** Documentation Check that instead of providing the original context source registration, implementations should return context source registration information relevant for the subscription, in particular only matching RegistrationInfo elements -Resource ${EXECDIR}/resources/ApiUtils/ContextSourceRegistrationSubscription.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextSourceRegistration.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextSourceRegistrationSubscription.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource Resource ${EXECDIR}/resources/NotificationUtils.resource @@ -12,8 +13,6 @@ Test Teardown Delete Created Context Source Registration And Subscription *** Variables *** -${context_source_registration_id_prefix}= urn:ngsi-ld:ContextSourceRegistration: -${subscription_id_prefix}= urn:ngsi-ld:Subscription: ${context_source_registration_payload_file_path}= csourceRegistrations/context-source-registration-building-and-bus-entities.jsonld ${subscription_payload_file_path}= csourceSubscriptions/subscription.jsonld @@ -22,7 +21,7 @@ ${subscription_payload_file_path}= csourceSubscriptions/sub 047_03_01 Receive cSourceNotification With Relevant Information [Documentation] Check that instead of providing the original context source registration, implementations should return context source registration information relevant for the subscription, in particular only matching RegistrationInfo elements [Tags] csrsub-notification 5_11_7 - ${context_source_registration_id}= Generate Random Entity Id ${context_source_registration_id_prefix} + ${context_source_registration_id}= Generate Random CSR Id ${context_source_registration_payload}= Load Test Sample ... ${context_source_registration_payload_file_path} ... ${context_source_registration_id} @@ -40,7 +39,7 @@ ${subscription_payload_file_path}= csourceSubscriptions/sub *** Keywords *** Setup Initial Context Source Registration Subscription Start Local Server - ${subscription_id}= Generate Random Entity Id ${subscription_id_prefix} + ${subscription_id}= Generate Random Subscription Id ${subscription_payload}= Load Subscription Sample With Reachable Endpoint ... ${subscription_payload_file_path} ... ${subscription_id} diff --git a/TP/NGSI-LD/ContextSource/RegistrationSubscription/ContextSourceRegistrationSubscriptionNotificationBehaviour/047_04.robot b/TP/NGSI-LD/ContextSource/RegistrationSubscription/ContextSourceRegistrationSubscriptionNotificationBehaviour/047_04.robot index 4de52e9cae01e49cdf451a73ba4098dcd9a667e6..596b6123e9d45ddef7e1f45811d76ea8567e65a8 100644 --- a/TP/NGSI-LD/ContextSource/RegistrationSubscription/ContextSourceRegistrationSubscriptionNotificationBehaviour/047_04.robot +++ b/TP/NGSI-LD/ContextSource/RegistrationSubscription/ContextSourceRegistrationSubscriptionNotificationBehaviour/047_04.robot @@ -1,8 +1,9 @@ *** Settings *** Documentation The structure of the csource notification message shall be as mandated by clause 5.3.2 -Resource ${EXECDIR}/resources/ApiUtils/ContextSourceRegistrationSubscription.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextSourceRegistration.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextSourceRegistrationSubscription.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource Resource ${EXECDIR}/resources/NotificationUtils.resource @@ -12,8 +13,6 @@ Test Teardown Delete Created Context Source Registration And Subscription *** Variables *** -${context_source_registration_id_prefix}= urn:ngsi-ld:ContextSourceRegistration: -${subscription_id_prefix}= urn:ngsi-ld:Subscription: ${context_source_registration_payload_file_path}= csourceRegistrations/context-source-registration.jsonld ${subscription_payload_file_path}= csourceSubscriptions/subscription.jsonld @@ -22,7 +21,7 @@ ${subscription_payload_file_path}= csourceSubscriptions/sub 047_04_01 Receive cSourceNotification With Compliant Structure [Documentation] The structure of the csource notification message shall be as mandated by clause 5.3.2 [Tags] csrsub-notification 5_11_7 - ${context_source_registration_id}= Generate Random Entity Id ${context_source_registration_id_prefix} + ${context_source_registration_id}= Generate Random CSR Id ${context_source_registration_payload}= Load Test Sample ... ${context_source_registration_payload_file_path} ... ${context_source_registration_id} @@ -38,7 +37,7 @@ ${subscription_payload_file_path}= csourceSubscriptions/sub *** Keywords *** Setup Initial Context Source Registration Subscription Start Local Server - ${subscription_id}= Generate Random Entity Id ${subscription_id_prefix} + ${subscription_id}= Generate Random Subscription Id ${subscription_payload}= Load Subscription Sample With Reachable Endpoint ... ${subscription_payload_file_path} ... ${subscription_id} diff --git a/TP/NGSI-LD/ContextSource/RegistrationSubscription/ContextSourceRegistrationSubscriptionNotificationBehaviour/047_05.robot b/TP/NGSI-LD/ContextSource/RegistrationSubscription/ContextSourceRegistrationSubscriptionNotificationBehaviour/047_05.robot index 1c2af17a6b1607c668040fd47d7e62f59dcc74fe..59dedb8576a41bf5e5595a15c99afc33c34c2088 100644 --- a/TP/NGSI-LD/ContextSource/RegistrationSubscription/ContextSourceRegistrationSubscriptionNotificationBehaviour/047_05.robot +++ b/TP/NGSI-LD/ContextSource/RegistrationSubscription/ContextSourceRegistrationSubscriptionNotificationBehaviour/047_05.robot @@ -1,8 +1,9 @@ *** Settings *** Documentation Check that if a cSourceNotification is sent successfully to the "endpoint" member, the "notification.timesSent" member shall be incremented by one and the "notification.lastSuccess" and "notification.lastNotification" members shall be updated with the current timestamp and the status of the context source registration subscription shall be updated to "ok" -Resource ${EXECDIR}/resources/ApiUtils/ContextSourceRegistrationSubscription.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextSourceRegistration.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextSourceRegistrationSubscription.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource Resource ${EXECDIR}/resources/NotificationUtils.resource @@ -12,8 +13,6 @@ Test Teardown Delete Created Context Source Registration And Subscription *** Variables *** -${context_source_registration_id_prefix}= urn:ngsi-ld:ContextSourceRegistration: -${subscription_id_prefix}= urn:ngsi-ld:Subscription: ${context_source_registration_payload_file_path}= csourceRegistrations/context-source-registration.jsonld ${subscription_payload_file_path}= csourceSubscriptions/subscription.jsonld ${notification_expectation_file_path}= notifications/expectations/1-timesSent-ok.json @@ -23,7 +22,7 @@ ${notification_expectation_file_path}= notifications/expectatio 047_05_01 If A cSourceNotification Is Successfully Sent The Notification Member Shall Be Updated [Documentation] Check that if a cSourceNotification is sent successfully to the "endpoint" member, the "notification.timesSent" member shall be incremented by one and the "notification.lastSuccess" and "notification.lastNotification" members shall be updated with the current timestamp and the status of the context source registration subscription shall be updated to "ok" [Tags] csrsub-notification 5_11_7 - ${context_source_registration_id}= Generate Random Entity Id ${context_source_registration_id_prefix} + ${context_source_registration_id}= Generate Random CSR Id ${context_source_registration_payload}= Load Test Sample ... ${context_source_registration_payload_file_path} ... ${context_source_registration_id} @@ -42,7 +41,7 @@ ${notification_expectation_file_path}= notifications/expectatio *** Keywords *** Setup Initial Context Source Registration Subscription Start Local Server - ${subscription_id}= Generate Random Entity Id ${subscription_id_prefix} + ${subscription_id}= Generate Random Subscription Id ${subscription_payload}= Load Subscription Sample With Reachable Endpoint ... ${subscription_payload_file_path} ... ${subscription_id} diff --git a/TP/NGSI-LD/ContextSource/RegistrationSubscription/ContextSourceRegistrationSubscriptionNotificationBehaviour/047_06.robot b/TP/NGSI-LD/ContextSource/RegistrationSubscription/ContextSourceRegistrationSubscriptionNotificationBehaviour/047_06.robot index 48d4fcc0c55f5bbf37b152d1ccf57b5cdd435ba9..6cca67d9b77d8cec5f51dc361d8822d7ec86e27a 100644 --- a/TP/NGSI-LD/ContextSource/RegistrationSubscription/ContextSourceRegistrationSubscriptionNotificationBehaviour/047_06.robot +++ b/TP/NGSI-LD/ContextSource/RegistrationSubscription/ContextSourceRegistrationSubscriptionNotificationBehaviour/047_06.robot @@ -1,8 +1,9 @@ *** Settings *** Documentation Check that if a cSourceNotification is not sent successfully, the "notification.timesSent" member shall be incremented by one and the notification.lastFailure" and "notification.lastNotification" members shall be updated with the current timestamp and the status of the context source registration subscription shall be updated to "failed" -Resource ${EXECDIR}/resources/ApiUtils/ContextSourceRegistrationSubscription.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextSourceRegistration.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextSourceRegistrationSubscription.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource Resource ${EXECDIR}/resources/NotificationUtils.resource @@ -12,8 +13,6 @@ Test Teardown Delete Created Context Source Registration And Subscription *** Variables *** -${context_source_registration_id_prefix}= urn:ngsi-ld:ContextSourceRegistration: -${subscription_id_prefix}= urn:ngsi-ld:Subscription: ${context_source_registration_payload_file_path}= csourceRegistrations/context-source-registration.jsonld ${subscription_payload_file_path}= csourceSubscriptions/subscription-unreachable-endpoint.jsonld ${notification_expectation_file_path}= notifications/expectations/1-timesSent-failed.json @@ -23,7 +22,7 @@ ${notification_expectation_file_path}= notifications/expectatio 047_06_01 If A cSourceNotification Is Not Successfully Sent The Notification Member Shall Be Updated [Documentation] Check that if a cSourceNotification is not sent successfully, the "notification.timesSent" member shall be incremented by one and the notification.lastFailure" and "notification.lastNotification" members shall be updated with the current timestamp and the status of the context source registration subscription shall be updated to "failed" [Tags] csrsub-notification 5_11_7 - ${context_source_registration_id}= Generate Random Entity Id ${context_source_registration_id_prefix} + ${context_source_registration_id}= Generate Random CSR Id ${context_source_registration_payload}= Load Test Sample ... ${context_source_registration_payload_file_path} ... ${context_source_registration_id} @@ -42,7 +41,7 @@ ${notification_expectation_file_path}= notifications/expectatio *** Keywords *** Setup Initial Context Source Registration Subscription Start Local Server - ${subscription_id}= Generate Random Entity Id ${subscription_id_prefix} + ${subscription_id}= Generate Random Subscription Id ${subscription_payload}= Load Test Sample ${subscription_payload_file_path} ${subscription_id} ${create_response}= Create Context Source Registration Subscription ${subscription_payload} Check Response Status Code 201 ${create_response.status_code} diff --git a/TP/NGSI-LD/ContextSource/RegistrationSubscription/ContextSourceRegistrationSubscriptionNotificationBehaviour/047_07.robot b/TP/NGSI-LD/ContextSource/RegistrationSubscription/ContextSourceRegistrationSubscriptionNotificationBehaviour/047_07.robot index 5491a36ba7214c1d39b1cf2c1574e1bcb28d6d50..5a6ac9484b43bb86b6e472319525a8eb3baa355d 100644 --- a/TP/NGSI-LD/ContextSource/RegistrationSubscription/ContextSourceRegistrationSubscriptionNotificationBehaviour/047_07.robot +++ b/TP/NGSI-LD/ContextSource/RegistrationSubscription/ContextSourceRegistrationSubscriptionNotificationBehaviour/047_07.robot @@ -1,8 +1,9 @@ *** Settings *** Documentation Check that a cSourceNotification shall only be sent if and only if the status of the corresponding subscription is active, neither paused or expired -Resource ${EXECDIR}/resources/ApiUtils/ContextSourceRegistrationSubscription.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextSourceRegistration.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextSourceRegistrationSubscription.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource Resource ${EXECDIR}/resources/NotificationUtils.resource @@ -13,8 +14,6 @@ Test Template Do Not Receive cSourceNotification If Subscription Status Is *** Variables *** -${context_source_registration_id_prefix}= urn:ngsi-ld:ContextSourceRegistration: -${subscription_id_prefix}= urn:ngsi-ld:Subscription: ${context_source_registration_payload_file_path}= csourceRegistrations/context-source-registration.jsonld ${subscription_payload_file_path}= csourceSubscriptions/subscription.jsonld @@ -37,7 +36,7 @@ Do Not Receive cSourceNotification If Subscription Status Is Not Active ... ${subscription_id} ... ${subscription_update_fragment} - ${context_source_registration_id}= Generate Random Entity Id ${context_source_registration_id_prefix} + ${context_source_registration_id}= Generate Random CSR Id ${context_source_registration_payload}= Load Test Sample ... ${context_source_registration_payload_file_path} ... ${context_source_registration_id} @@ -47,7 +46,7 @@ Do Not Receive cSourceNotification If Subscription Status Is Not Active Setup Initial Context Source Registration Subscription Start Local Server - ${subscription_id}= Generate Random Entity Id ${subscription_id_prefix} + ${subscription_id}= Generate Random Subscription Id ${subscription_payload}= Load Subscription Sample With Reachable Endpoint ... ${subscription_payload_file_path} ... ${subscription_id} diff --git a/TP/NGSI-LD/ContextSource/RegistrationSubscription/ContextSourceRegistrationSubscriptionNotificationBehaviour/047_08.robot b/TP/NGSI-LD/ContextSource/RegistrationSubscription/ContextSourceRegistrationSubscriptionNotificationBehaviour/047_08.robot index 5beccbae571631f9762b59098d44f976b59085b1..339e067d6de0839c8a757b62133f7792c3462425 100644 --- a/TP/NGSI-LD/ContextSource/RegistrationSubscription/ContextSourceRegistrationSubscriptionNotificationBehaviour/047_08.robot +++ b/TP/NGSI-LD/ContextSource/RegistrationSubscription/ContextSourceRegistrationSubscriptionNotificationBehaviour/047_08.robot @@ -1,8 +1,9 @@ *** Settings *** Documentation Check if a context source registration subscription does not define a temporalQ member, a CsourceNotification will be triggered from matching context source registrations for context sources providing latest information -Resource ${EXECDIR}/resources/ApiUtils/ContextSourceRegistrationSubscription.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextSourceRegistration.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextSourceRegistrationSubscription.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource Resource ${EXECDIR}/resources/NotificationUtils.resource @@ -12,8 +13,6 @@ Test Teardown Delete Created Context Source Registration And Context Sourc *** Variables *** -${context_source_registration_id_prefix}= urn:ngsi-ld:ContextSourceRegistration: -${subscription_id_prefix}= urn:ngsi-ld:Subscription: ${context_source_registration_payload_file_path}= csourceRegistrations/context-source-registration.jsonld ${subscription_payload_file_path}= csourceSubscriptions/subscription.jsonld ${update_fragment_file_path}= csourceRegistrations/fragments/context-source-registration-update.json @@ -35,8 +34,8 @@ ${update_fragment_file_path}= csourceRegistrations/fra *** Keywords *** Create Initial Context Source Registration and Context Source Registration Subscription Start Local Server - ${context_source_registration_id}= Generate Random Entity Id ${context_source_registration_id_prefix} - ${subscription_id}= Generate Random Entity Id ${subscription_id_prefix} + ${context_source_registration_id}= Generate Random CSR Id + ${subscription_id}= Generate Random Subscription Id ${context_source_registration_payload}= Load Test Sample ... ${context_source_registration_payload_file_path} ... ${context_source_registration_id} diff --git a/TP/NGSI-LD/ContextSource/RegistrationSubscription/ContextSourceRegistrationSubscriptionNotificationBehaviour/047_09.robot b/TP/NGSI-LD/ContextSource/RegistrationSubscription/ContextSourceRegistrationSubscriptionNotificationBehaviour/047_09.robot index ef6575b161fd094cfba6acc4e4dac2a346fba2c1..40edd77fa6bf929ecdb033b8d4e739825c11cec6 100644 --- a/TP/NGSI-LD/ContextSource/RegistrationSubscription/ContextSourceRegistrationSubscriptionNotificationBehaviour/047_09.robot +++ b/TP/NGSI-LD/ContextSource/RegistrationSubscription/ContextSourceRegistrationSubscriptionNotificationBehaviour/047_09.robot @@ -1,8 +1,9 @@ *** Settings *** Documentation Check if a context source registration subscription defines an "entities" member, a CsourceNotification will be triggered from context source registrations with information member matching the described "entities" -Resource ${EXECDIR}/resources/ApiUtils/ContextSourceRegistrationSubscription.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextSourceRegistration.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextSourceRegistrationSubscription.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource Resource ${EXECDIR}/resources/NotificationUtils.resource @@ -12,8 +13,6 @@ Suite Teardown Delete Created Context Source Registration And Context Sourc *** Variables *** -${context_source_registration_id_prefix}= urn:ngsi-ld:ContextSourceRegistration: -${subscription_id_prefix}= urn:ngsi-ld:Subscription: ${context_source_registration_payload_file_path}= csourceRegistrations/context-source-registration.jsonld ${subscription_payload_file_path}= csourceSubscriptions/subscription.jsonld ${update_fragment_file_path}= csourceRegistrations/fragments/context-source-registration-update-information.json @@ -35,8 +34,8 @@ ${update_fragment_file_path}= csourceRegistrations/fra *** Keywords *** Create Initial Context Source Registration And Context Source Registration Subscription Start Local Server - ${context_source_registration_id}= Generate Random Entity Id ${context_source_registration_id_prefix} - ${subscription_id}= Generate Random Entity Id ${subscription_id_prefix} + ${context_source_registration_id}= Generate Random CSR Id + ${subscription_id}= Generate Random Subscription Id ${context_source_registration_payload}= Load Test Sample ... ${context_source_registration_payload_file_path} ... ${context_source_registration_id} diff --git a/TP/NGSI-LD/ContextSource/RegistrationSubscription/ContextSourceRegistrationSubscriptionNotificationBehaviour/047_10.robot b/TP/NGSI-LD/ContextSource/RegistrationSubscription/ContextSourceRegistrationSubscriptionNotificationBehaviour/047_10.robot index bb549e928893567a00f760582b0ff6328ee741e9..4d14cd60ae50bf07b9411f50bd73def87c3d8852 100644 --- a/TP/NGSI-LD/ContextSource/RegistrationSubscription/ContextSourceRegistrationSubscriptionNotificationBehaviour/047_10.robot +++ b/TP/NGSI-LD/ContextSource/RegistrationSubscription/ContextSourceRegistrationSubscriptionNotificationBehaviour/047_10.robot @@ -1,8 +1,9 @@ *** Settings *** Documentation Check if a context source registration subscription defines temporalQ member with timeproperty observedAt, the temporal query is matched against the observationInterval of matching context source registrations -Resource ${EXECDIR}/resources/ApiUtils/ContextSourceRegistrationSubscription.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextSourceRegistration.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextSourceRegistrationSubscription.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource Resource ${EXECDIR}/resources/NotificationUtils.resource @@ -12,8 +13,6 @@ Test Teardown Delete Created Context Source Registration And Subscription *** Variables *** -${context_source_registration_id_prefix}= urn:ngsi-ld:ContextSourceRegistration: -${subscription_id_prefix}= urn:ngsi-ld:Subscription: ${context_source_registration_payload_file_path}= csourceRegistrations/context-source-registration-observationInterval.jsonld ${subscription_payload_file_path}= csourceSubscriptions/subscription-temporalQ-observedAt.jsonld @@ -22,7 +21,7 @@ ${subscription_payload_file_path}= csourceSubscriptions/sub 047_10_01 Receive cSourceNotification For Matching Context Source Registrations On Observation Interval [Documentation] Check if a context source registration subscription defines temporalQ member with timeproperty observedAt, the temporal query is matched against the observationInterval of matching context source registrations [Tags] csrsub-notification 5_11_7 - ${context_source_registration_id}= Generate Random Entity Id ${context_source_registration_id_prefix} + ${context_source_registration_id}= Generate Random CSR Id ${context_source_registration_payload}= Load Test Sample ... ${context_source_registration_payload_file_path} ... ${context_source_registration_id} @@ -38,7 +37,7 @@ ${subscription_payload_file_path}= csourceSubscriptions/sub *** Keywords *** Setup Initial Context Source Registration Subscription Start Local Server - ${subscription_id}= Generate Random Entity Id ${subscription_id_prefix} + ${subscription_id}= Generate Random Subscription Id ${subscription_payload}= Load Subscription Sample With Reachable Endpoint ... ${subscription_payload_file_path} ... ${subscription_id} diff --git a/TP/NGSI-LD/ContextSource/RegistrationSubscription/ContextSourceRegistrationSubscriptionNotificationBehaviour/047_11.robot b/TP/NGSI-LD/ContextSource/RegistrationSubscription/ContextSourceRegistrationSubscriptionNotificationBehaviour/047_11.robot index b3d487d3e9b2dd7099537a6d10c8e3841e4136e5..f94d450fa90228268f43ce9c80fd65509638396d 100644 --- a/TP/NGSI-LD/ContextSource/RegistrationSubscription/ContextSourceRegistrationSubscriptionNotificationBehaviour/047_11.robot +++ b/TP/NGSI-LD/ContextSource/RegistrationSubscription/ContextSourceRegistrationSubscriptionNotificationBehaviour/047_11.robot @@ -1,8 +1,9 @@ *** Settings *** Documentation Check if a context source registration subscription defines temporalQ member with timeproperty createdAt or modifiedAt, the temporal query is matched against the managementInterval of matching context source registrations -Resource ${EXECDIR}/resources/ApiUtils/ContextSourceRegistrationSubscription.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextSourceRegistration.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextSourceRegistrationSubscription.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource Resource ${EXECDIR}/resources/NotificationUtils.resource @@ -14,8 +15,6 @@ Test Template Receive cSourceNotification For Matching Context Source Regi *** Variables *** -${context_source_registration_id_prefix}= urn:ngsi-ld:ContextSourceRegistration: -${subscription_id_prefix}= urn:ngsi-ld:Subscription: ${context_source_registration_payload_file_path}= csourceRegistrations/context-source-registration-managementInterval.jsonld @@ -30,12 +29,12 @@ ${context_source_registration_payload_file_path}= csourceRegistrations/con Receive cSourceNotification For Matching Context Source Registrations On Management Interval [Documentation] Check if a context source registration subscription defines temporalQ member with timeproperty createdAt or modifiedAt, the temporal query is matched against the managementInterval of matching context source registrations [Arguments] ${filepath} - ${subscription_id}= Generate Random Entity Id ${subscription_id_prefix} + ${subscription_id}= Generate Random Subscription Id Set Suite Variable ${subscription_id} ${subscription_payload}= Load Subscription Sample With Reachable Endpoint ${filepath} ${subscription_id} ${response}= Create Context Source Registration Subscription ${subscription_payload} Check Response Status Code 201 ${response.status_code} - ${context_source_registration_id}= Generate Random Entity Id ${context_source_registration_id_prefix} + ${context_source_registration_id}= Generate Random CSR Id Set Suite Variable ${context_source_registration_id} ${context_source_registration_payload}= Load Test Sample ... ${context_source_registration_payload_file_path} diff --git a/TP/NGSI-LD/ContextSource/RegistrationSubscription/ContextSourceRegistrationSubscriptionNotificationBehaviour/047_12.robot b/TP/NGSI-LD/ContextSource/RegistrationSubscription/ContextSourceRegistrationSubscriptionNotificationBehaviour/047_12.robot index e09fbf9bbae88b9d7686c8afe984c78ba8bdc6d8..b957620c152fd39faae92ae274a4f9c25f9ff4ef 100644 --- a/TP/NGSI-LD/ContextSource/RegistrationSubscription/ContextSourceRegistrationSubscriptionNotificationBehaviour/047_12.robot +++ b/TP/NGSI-LD/ContextSource/RegistrationSubscription/ContextSourceRegistrationSubscriptionNotificationBehaviour/047_12.robot @@ -1,8 +1,9 @@ *** Settings *** Documentation Check if a context source registrations subscription defines entities member and watchedAttributes member, a CsourceNotification will be triggered from context source registrations with information member matching the described "entities" and "attributes" -Resource ${EXECDIR}/resources/ApiUtils/ContextSourceRegistrationSubscription.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextSourceRegistration.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextSourceRegistrationSubscription.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource Resource ${EXECDIR}/resources/NotificationUtils.resource @@ -12,8 +13,6 @@ Test Teardown Delete Created Context Source Registration And Subscription *** Variables *** -${context_source_registration_id_prefix}= urn:ngsi-ld:ContextSourceRegistration: -${subscription_id_prefix}= urn:ngsi-ld:Subscription: ${context_source_registration_payload_file_path}= csourceRegistrations/context-source-registration-detailed-information.jsonld ${subscription_payload_file_path}= csourceSubscriptions/subscription-watchedAttributes.jsonld @@ -22,7 +21,7 @@ ${subscription_payload_file_path}= csourceSubscriptions/sub 047_12_01 Receive cSourceNotification For Matching Context Source Registrations On Watched Attributes [Documentation] Check if a context source registrations subscription defines entities member and watchedAttributes member, a CsourceNotification will be triggered from context source registrations with information member matching the described "entities" and "attributes" [Tags] csrsub-notification 5_11_7 - ${context_source_registration_id}= Generate Random Entity Id ${context_source_registration_id_prefix} + ${context_source_registration_id}= Generate Random CSR Id ${context_source_registration_payload}= Load Test Sample ... ${context_source_registration_payload_file_path} ... ${context_source_registration_id} @@ -38,7 +37,7 @@ ${subscription_payload_file_path}= csourceSubscriptions/sub *** Keywords *** Setup Initial Context Source Registration Subscription Start Local Server - ${subscription_id}= Generate Random Entity Id ${subscription_id_prefix} + ${subscription_id}= Generate Random Subscription Id ${subscription_payload}= Load Subscription Sample With Reachable Endpoint ... ${subscription_payload_file_path} ... ${subscription_id} diff --git a/TP/NGSI-LD/ContextSource/RegistrationSubscription/ContextSourceRegistrationSubscriptionNotificationBehaviour/047_13.robot b/TP/NGSI-LD/ContextSource/RegistrationSubscription/ContextSourceRegistrationSubscriptionNotificationBehaviour/047_13.robot index 1d8a232530f2ed05a36b9491c294cfb3bc5dfbb0..5645f358b37e81b5032280c5e9ebb91d8b1e5184 100644 --- a/TP/NGSI-LD/ContextSource/RegistrationSubscription/ContextSourceRegistrationSubscriptionNotificationBehaviour/047_13.robot +++ b/TP/NGSI-LD/ContextSource/RegistrationSubscription/ContextSourceRegistrationSubscriptionNotificationBehaviour/047_13.robot @@ -1,8 +1,9 @@ *** Settings *** Documentation Check if a context source registrations subscription does not define watchedAttributes member, a CsourceNotification will be triggered from context source registrations with information member matching all attributes of the described entities -Resource ${EXECDIR}/resources/ApiUtils/ContextSourceRegistrationSubscription.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextSourceRegistration.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextSourceRegistrationSubscription.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource Resource ${EXECDIR}/resources/NotificationUtils.resource @@ -12,8 +13,6 @@ Test Teardown Delete Created Context Source Registration And Subscription *** Variables *** -${context_source_registration_id_prefix}= urn:ngsi-ld:ContextSourceRegistration: -${subscription_id_prefix}= urn:ngsi-ld:Subscription: ${context_source_registration_payload_file_path}= csourceRegistrations/context-source-registration-detailed-information.jsonld ${subscription_payload_file_path}= csourceSubscriptions/subscription.jsonld @@ -22,7 +21,7 @@ ${subscription_payload_file_path}= csourceSubscriptions/sub 047_13_01 Receive cSourceNotification For Matching Context Source Registrations On Any watchedAttribute [Documentation] Check if a context source registrations subscription does not define watchedAttributes member, a CsourceNotification will be triggered from context source registrations with information member matching all attributes of the described entities [Tags] csrsub-notification 5_11_7 - ${context_source_registration_id}= Generate Random Entity Id ${context_source_registration_id_prefix} + ${context_source_registration_id}= Generate Random CSR Id ${context_source_registration_payload}= Load Test Sample ... ${context_source_registration_payload_file_path} ... ${context_source_registration_id} @@ -38,7 +37,7 @@ ${subscription_payload_file_path}= csourceSubscriptions/sub *** Keywords *** Setup Initial Context Source Registration Subscription Start Local Server - ${subscription_id}= Generate Random Entity Id ${subscription_id_prefix} + ${subscription_id}= Generate Random Subscription Id ${subscription_payload}= Load Subscription Sample With Reachable Endpoint ... ${subscription_payload_file_path} ... ${subscription_id} diff --git a/TP/NGSI-LD/ContextSource/RegistrationSubscription/ContextSourceRegistrationSubscriptionNotificationBehaviour/047_14.robot b/TP/NGSI-LD/ContextSource/RegistrationSubscription/ContextSourceRegistrationSubscriptionNotificationBehaviour/047_14.robot index 1334f778de1b140d21fbbed54bf9297f619969e4..4914bd29b504b0282255a86504788dfe2db55381 100644 --- a/TP/NGSI-LD/ContextSource/RegistrationSubscription/ContextSourceRegistrationSubscriptionNotificationBehaviour/047_14.robot +++ b/TP/NGSI-LD/ContextSource/RegistrationSubscription/ContextSourceRegistrationSubscriptionNotificationBehaviour/047_14.robot @@ -1,8 +1,9 @@ *** Settings *** Documentation Check if a context source registrations subscription defines a geoQ member, a CsourceNotification will be triggered from matching context source registrations with a matching location member -Resource ${EXECDIR}/resources/ApiUtils/ContextSourceRegistrationSubscription.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextSourceRegistration.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextSourceRegistrationSubscription.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource Resource ${EXECDIR}/resources/NotificationUtils.resource @@ -12,8 +13,6 @@ Test Teardown Delete Created Context Source Registration And Subscription *** Variables *** -${context_source_registration_id_prefix}= urn:ngsi-ld:ContextSourceRegistration: -${subscription_id_prefix}= urn:ngsi-ld:Subscription: ${context_source_registration_payload_file_path}= csourceRegistrations/context-source-registration-location.jsonld ${subscription_payload_file_path}= csourceSubscriptions/subscription-geoQ.jsonld @@ -22,7 +21,7 @@ ${subscription_payload_file_path}= csourceSubscriptions/sub 047_14_01 Receive cSourceNotification For Matching Context Source Registrations On Location [Documentation] Check if a context source registrations subscription defines a geoQ member, a CsourceNotification will be triggered from matching context source registrations with a matching location member [Tags] csrsub-notification 5_11_7 - ${context_source_registration_id}= Generate Random Entity Id ${context_source_registration_id_prefix} + ${context_source_registration_id}= Generate Random CSR Id ${context_source_registration_payload}= Load Test Sample ... ${context_source_registration_payload_file_path} ... ${context_source_registration_id} @@ -38,7 +37,7 @@ ${subscription_payload_file_path}= csourceSubscriptions/sub *** Keywords *** Setup Initial Context Source Registration Subscription Start Local Server - ${subscription_id}= Generate Random Entity Id ${subscription_id_prefix} + ${subscription_id}= Generate Random Subscription Id ${subscription_payload}= Load Subscription Sample With Reachable Endpoint ... ${subscription_payload_file_path} ... ${subscription_id} diff --git a/TP/NGSI-LD/ContextSource/RegistrationSubscription/ContextSourceRegistrationSubscriptionNotificationBehaviour/047_15.robot b/TP/NGSI-LD/ContextSource/RegistrationSubscription/ContextSourceRegistrationSubscriptionNotificationBehaviour/047_15.robot index b2d6176b0931cc8e4f4d0b1c8f0c6c6734e87ced..625b596526512130558fdc39546ef5971a4fa4a4 100644 --- a/TP/NGSI-LD/ContextSource/RegistrationSubscription/ContextSourceRegistrationSubscriptionNotificationBehaviour/047_15.robot +++ b/TP/NGSI-LD/ContextSource/RegistrationSubscription/ContextSourceRegistrationSubscriptionNotificationBehaviour/047_15.robot @@ -1,8 +1,9 @@ *** Settings *** Documentation Check if a context source registrations subscription does not define a geoproperty in the geoQ member, a CsourceNotification will be triggered from matching context source registrations with a matching location member -Resource ${EXECDIR}/resources/ApiUtils/ContextSourceRegistrationSubscription.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextSourceRegistration.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextSourceRegistrationSubscription.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource Resource ${EXECDIR}/resources/NotificationUtils.resource @@ -12,8 +13,6 @@ Test Teardown Delete Created Context Source Registration And Subscription *** Variables *** -${context_source_registration_id_prefix}= urn:ngsi-ld:ContextSourceRegistration: -${subscription_id_prefix}= urn:ngsi-ld:Subscription: ${context_source_registration_payload_file_path}= csourceRegistrations/context-source-registration-location.jsonld ${subscription_payload_file_path}= csourceSubscriptions/subscription-geoQ-without-geoproperty.jsonld @@ -22,7 +21,7 @@ ${subscription_payload_file_path}= csourceSubscriptions/sub 047_15_01 Receive cSourceNotification For Matching Context Source Registrations On Location As Default [Documentation] Check if a context source registrations subscription does not define a geoproperty in the geoQ member, a CsourceNotification will be triggered from matching context source registrations with a matching location member [Tags] csrsub-notification 5_11_7 - ${context_source_registration_id}= Generate Random Entity Id ${context_source_registration_id_prefix} + ${context_source_registration_id}= Generate Random CSR Id ${context_source_registration_payload}= Load Test Sample ... ${context_source_registration_payload_file_path} ... ${context_source_registration_id} @@ -38,7 +37,7 @@ ${subscription_payload_file_path}= csourceSubscriptions/sub *** Keywords *** Setup Initial Context Source Registration Subscription Start Local Server - ${subscription_id}= Generate Random Entity Id ${subscription_id_prefix} + ${subscription_id}= Generate Random Subscription Id ${subscription_payload}= Load Subscription Sample With Reachable Endpoint ... ${subscription_payload_file_path} ... ${subscription_id} diff --git a/TP/NGSI-LD/ContextSource/RegistrationSubscription/ContextSourceRegistrationSubscriptionNotificationBehaviour/047_16.robot b/TP/NGSI-LD/ContextSource/RegistrationSubscription/ContextSourceRegistrationSubscriptionNotificationBehaviour/047_16.robot index 435363dbb60641cb8aae0ec3c5360185c35a7f05..537b3319955c3e9f2005f95cb2743831b1264155 100644 --- a/TP/NGSI-LD/ContextSource/RegistrationSubscription/ContextSourceRegistrationSubscriptionNotificationBehaviour/047_16.robot +++ b/TP/NGSI-LD/ContextSource/RegistrationSubscription/ContextSourceRegistrationSubscriptionNotificationBehaviour/047_16.robot @@ -1,8 +1,9 @@ *** Settings *** Documentation Check if one updates a context source registration subscription, a CsourceNotification will be sent with all currently matching context source registrations -Resource ${EXECDIR}/resources/ApiUtils/ContextSourceRegistrationSubscription.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextSourceRegistration.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextSourceRegistrationSubscription.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource Resource ${EXECDIR}/resources/NotificationUtils.resource @@ -13,8 +14,6 @@ Test Template Receive cSourceNotification For Newly Matching Context Sourc *** Variables *** -${context_source_registration_id_prefix}= urn:ngsi-ld:ContextSourceRegistration: -${subscription_id_prefix}= urn:ngsi-ld:Subscription: ${first_context_source_registration_payload_file_path}= csourceRegistrations/context-source-registration-vehicle-entities.jsonld ${second_context_source_registration_payload_file_path}= csourceRegistrations/context-source-registration-bus-entities.jsonld ${subscription_payload_file_path}= csourceSubscriptions/subscription.jsonld @@ -47,9 +46,9 @@ Receive cSourceNotification For Newly Matching Context Source Registrations Create Initial Context Source Registrations And Context Source Registration Subscription Start Local Server - ${subscription_id}= Generate Random Entity Id ${subscription_id_prefix} - ${first_context_source_registration_id}= Generate Random Entity Id ${context_source_registration_id_prefix} - ${second_context_source_registration_id}= Generate Random Entity Id ${context_source_registration_id_prefix} + ${subscription_id}= Generate Random Subscription Id + ${first_context_source_registration_id}= Generate Random CSR Id + ${second_context_source_registration_id}= Generate Random CSR Id ${subscription_payload}= Load Subscription Sample With Reachable Endpoint ... ${subscription_payload_file_path} ... ${subscription_id} diff --git a/TP/NGSI-LD/ContextSource/RegistrationSubscription/CreateContextSourceRegistrationSubscription/038_01.robot b/TP/NGSI-LD/ContextSource/RegistrationSubscription/CreateContextSourceRegistrationSubscription/038_01.robot index d8e75e0b50b4e07f1949a3401718037f67c73afc..58762a26282b46ba35e804f42242819533496d5b 100644 --- a/TP/NGSI-LD/ContextSource/RegistrationSubscription/CreateContextSourceRegistrationSubscription/038_01.robot +++ b/TP/NGSI-LD/ContextSource/RegistrationSubscription/CreateContextSourceRegistrationSubscription/038_01.robot @@ -1,6 +1,7 @@ *** Settings *** Documentation Check that one can create a minimal context source registration subscription +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextSourceRegistrationSubscription.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -10,7 +11,6 @@ Suite Teardown Delete Created Context Source Registration Subscriptions *** Variables *** -${subscription_id_prefix}= urn:ngsi-ld:Subscription: ${subscription_payload_file_path}= csourceSubscriptions/subscription.jsonld @@ -51,8 +51,7 @@ ${subscription_payload_file_path}= csourceSubscriptions/subscription.jsonld *** Keywords *** Generate Random Ids For Context Source Registration Subscriptions - # TODO: Refactor Generate Random Entity Id to Generate Random Test Sample Id - ${subscription_id}= Generate Random Entity Id ${subscription_id_prefix} + ${subscription_id}= Generate Random Subscription Id Set Suite Variable ${subscription_id} Delete Created Context Source Registration Subscriptions diff --git a/TP/NGSI-LD/ContextSource/RegistrationSubscription/CreateContextSourceRegistrationSubscription/038_03.robot b/TP/NGSI-LD/ContextSource/RegistrationSubscription/CreateContextSourceRegistrationSubscription/038_03.robot index 9a933e4c12848c647a2c2c815a031d9d599b42a3..9019a2cd182b0d2e7a1dbd1b98ca0654afc71481 100644 --- a/TP/NGSI-LD/ContextSource/RegistrationSubscription/CreateContextSourceRegistrationSubscription/038_03.robot +++ b/TP/NGSI-LD/ContextSource/RegistrationSubscription/CreateContextSourceRegistrationSubscription/038_03.robot @@ -1,6 +1,7 @@ *** Settings *** Documentation Check that one can create a context source registration subscription without providing isActive member and will be active by default +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextSourceRegistrationSubscription.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -10,7 +11,6 @@ Suite Teardown Delete Created Context Source Registration Subscriptions *** Variables *** -${subscription_id_prefix}= urn:ngsi-ld:Subscription: ${subscription_payload_file_path}= csourceSubscriptions/subscription.jsonld @@ -32,7 +32,7 @@ ${subscription_payload_file_path}= csourceSubscriptions/subscription.jsonld *** Keywords *** Generate Random Ids For Context Source Registration Subscriptions - ${subscription_id}= Generate Random Entity Id ${subscription_id_prefix} + ${subscription_id}= Generate Random Subscription Id Set Suite Variable ${subscription_id} Delete Created Context Source Registration Subscriptions diff --git a/TP/NGSI-LD/ContextSource/RegistrationSubscription/CreateContextSourceRegistrationSubscription/038_04.robot b/TP/NGSI-LD/ContextSource/RegistrationSubscription/CreateContextSourceRegistrationSubscription/038_04.robot index 7f72e686438d04dc8af36c7096adcd45ea5f65c9..0a26912358d7e3e3714fcfe3e5565678e34d59d5 100644 --- a/TP/NGSI-LD/ContextSource/RegistrationSubscription/CreateContextSourceRegistrationSubscription/038_04.robot +++ b/TP/NGSI-LD/ContextSource/RegistrationSubscription/CreateContextSourceRegistrationSubscription/038_04.robot @@ -1,6 +1,7 @@ *** Settings *** Documentation Check that one can create a context source registration subscription with isActive member set to false and it's initial status will be set to "paused" +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextSourceRegistrationSubscription.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -10,7 +11,6 @@ Suite Teardown Delete Created Context Source Registration Subscriptions *** Variables *** -${subscription_id_prefix}= urn:ngsi-ld:Subscription: ${subscription_payload_file_path}= csourceSubscriptions/subscription-inactive.jsonld @@ -39,7 +39,7 @@ ${subscription_payload_file_path}= csourceSubscriptions/subscription-inacti *** Keywords *** Generate Random Ids For Context Source Registration Subscriptions - ${subscription_id}= Generate Random Entity Id ${subscription_id_prefix} + ${subscription_id}= Generate Random Subscription Id Set Suite Variable ${subscription_id} Delete Created Context Source Registration Subscriptions diff --git a/TP/NGSI-LD/ContextSource/RegistrationSubscription/CreateContextSourceRegistrationSubscription/038_05.robot b/TP/NGSI-LD/ContextSource/RegistrationSubscription/CreateContextSourceRegistrationSubscription/038_05.robot index 5a5107a4f5f35c35af94ad235fadb45d11b62368..9a251162a46cd137e9e17ccbc7e786c14cd66dda 100644 --- a/TP/NGSI-LD/ContextSource/RegistrationSubscription/CreateContextSourceRegistrationSubscription/038_05.robot +++ b/TP/NGSI-LD/ContextSource/RegistrationSubscription/CreateContextSourceRegistrationSubscription/038_05.robot @@ -1,6 +1,7 @@ *** Settings *** Documentation Check that one can create a context source registration subscription with an expiresAt member and when it is due the status of the subscription changes to "expired" +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextSourceRegistrationSubscription.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -10,7 +11,6 @@ Suite Teardown Delete Created Context Source Registration Subscriptions *** Variables *** -${subscription_id_prefix}= urn:ngsi-ld:Subscription: ${subscription_payload_file_path}= csourceSubscriptions/subscription-expiresAt.jsonld @@ -43,7 +43,7 @@ ${subscription_payload_file_path}= csourceSubscriptions/subscription-expire *** Keywords *** Generate Random Ids For Context Source Registration Subscriptions - ${subscription_id}= Generate Random Entity Id ${subscription_id_prefix} + ${subscription_id}= Generate Random Subscription Id Set Suite Variable ${subscription_id} Delete Created Context Source Registration Subscriptions diff --git a/TP/NGSI-LD/ContextSource/RegistrationSubscription/CreateContextSourceRegistrationSubscription/038_06.robot b/TP/NGSI-LD/ContextSource/RegistrationSubscription/CreateContextSourceRegistrationSubscription/038_06.robot index 43232eadc8fa05d96d17ef0a2c0ed0b85981acd2..1ce57412a1a3af0006ab1a1673d62b3d615d8290 100644 --- a/TP/NGSI-LD/ContextSource/RegistrationSubscription/CreateContextSourceRegistrationSubscription/038_06.robot +++ b/TP/NGSI-LD/ContextSource/RegistrationSubscription/CreateContextSourceRegistrationSubscription/038_06.robot @@ -1,6 +1,7 @@ *** Settings *** Documentation Check that one can create a context source registration subscription without an expiresAt member and it will be considered as perpetual +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextSourceRegistrationSubscription.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -10,7 +11,6 @@ Suite Teardown Delete Created Context Source Registration Subscriptions *** Variables *** -${subscription_id_prefix}= urn:ngsi-ld:Subscription: ${subscription_payload_file_path}= csourceSubscriptions/subscription.jsonld @@ -34,7 +34,7 @@ ${subscription_payload_file_path}= csourceSubscriptions/subscription.jsonld *** Keywords *** Generate Random Ids For Context Source Registration Subscriptions - ${subscription_id}= Generate Random Entity Id ${subscription_id_prefix} + ${subscription_id}= Generate Random Subscription Id Set Suite Variable ${subscription_id} Delete Created Context Source Registration Subscriptions diff --git a/TP/NGSI-LD/ContextSource/RegistrationSubscription/CreateContextSourceRegistrationSubscription/038_07.robot b/TP/NGSI-LD/ContextSource/RegistrationSubscription/CreateContextSourceRegistrationSubscription/038_07.robot index 6f23bf1b1cc939642557623727c5f560c2e9b018..e13bae568d851bc19b52d7adcf7e012a5668bea2 100644 --- a/TP/NGSI-LD/ContextSource/RegistrationSubscription/CreateContextSourceRegistrationSubscription/038_07.robot +++ b/TP/NGSI-LD/ContextSource/RegistrationSubscription/CreateContextSourceRegistrationSubscription/038_07.robot @@ -1,6 +1,7 @@ *** Settings *** Documentation Check that one cannot create a context source registration subscription where another context source registration subscription whose id is equivalent exists +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextSourceRegistrationSubscription.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -10,7 +11,6 @@ Test Teardown Delete Initial Context Source Registration Subscription *** Variables *** -${subscription_id_prefix}= urn:ngsi-ld:Subscription: ${subscription_payload_file_path}= csourceSubscriptions/subscription.jsonld @@ -28,7 +28,7 @@ ${subscription_payload_file_path}= csourceSubscriptions/subscription.jsonld *** Keywords *** Setup Initial Context Source Registration Subscription - ${subscription_id}= Generate Random Entity Id ${subscription_id_prefix} + ${subscription_id}= Generate Random Subscription Id ${subscription_payload}= Load Test Sample ${subscription_payload_file_path} ${subscription_id} ${create_csrsub_response}= Create Context Source Registration Subscription ${subscription_payload} Check Response Status Code 201 ${create_csrsub_response.status_code} diff --git a/TP/NGSI-LD/ContextSource/RegistrationSubscription/CreateContextSourceRegistrationSubscription/038_08.robot b/TP/NGSI-LD/ContextSource/RegistrationSubscription/CreateContextSourceRegistrationSubscription/038_08.robot index 32b69a6d658a1ddbfae33a06e807ec7d82d00108..07819a08cefc7510bc010a0473b7edf5391df680 100644 --- a/TP/NGSI-LD/ContextSource/RegistrationSubscription/CreateContextSourceRegistrationSubscription/038_08.robot +++ b/TP/NGSI-LD/ContextSource/RegistrationSubscription/CreateContextSourceRegistrationSubscription/038_08.robot @@ -1,6 +1,7 @@ *** Settings *** Documentation Check that one cannot create a context source registration subscription If the data types, cardinalities and restrictions expressed by clause 5.2.12 are not met +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextSourceRegistrationSubscription.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -9,7 +10,6 @@ Test Template Create Invalid Context Source Registration Subscription *** Variables *** -${subscription_id_prefix}= urn:ngsi-ld:Subscription: ${subscription_payload_file_path}= ${EMPTY} @@ -32,7 +32,7 @@ ${subscription_payload_file_path}= ${EMPTY} Create Invalid Context Source Registration Subscription [Documentation] Check that one cannot create a context source registration subscription If the data types, cardinalities and restrictions expressed by clause 5.2.12 are not met [Arguments] ${filepath} - ${subscription_id}= Generate Random Entity Id ${subscription_id_prefix} + ${subscription_id}= Generate Random Subscription Id ${subscription_payload}= Load Test Sample ${filepath} ${subscription_id} ${response}= Create Context Source Registration Subscription ${subscription_payload} Check Response Status Code 400 ${response.status_code} diff --git a/TP/NGSI-LD/ContextSource/RegistrationSubscription/CreateContextSourceRegistrationSubscription/038_09.robot b/TP/NGSI-LD/ContextSource/RegistrationSubscription/CreateContextSourceRegistrationSubscription/038_09.robot index dfc61917d667640cad080769286a3e6eb441f971..11cbd3d5b8ca34c2d0829a6b3b6993afd3b85dd2 100644 --- a/TP/NGSI-LD/ContextSource/RegistrationSubscription/CreateContextSourceRegistrationSubscription/038_09.robot +++ b/TP/NGSI-LD/ContextSource/RegistrationSubscription/CreateContextSourceRegistrationSubscription/038_09.robot @@ -1,13 +1,13 @@ *** Settings *** Documentation Check that one cannot create a context source registration subscription with an expiration timestamp representing a moment before the current date and time +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextSourceRegistrationSubscription.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource *** Variables *** -${subscription_id_prefix}= urn:ngsi-ld:Subscription: ${subscription_payload_file_path}= csourceSubscriptions/subscription-expired.jsonld @@ -15,7 +15,7 @@ ${subscription_payload_file_path}= csourceSubscriptions/subscription-expire 038_09_01 Create Expired Context Source Registration Subscription [Documentation] Check that one cannot create a context source registration subscription with an expiration timestamp representing a moment before the current date and time [Tags] csrsub-create 5_11_2 - ${subscription_id}= Generate Random Entity Id ${subscription_id_prefix} + ${subscription_id}= Generate Random Subscription Id ${subscription_payload}= Load Test Sample ${subscription_payload_file_path} ${subscription_id} ${response}= Create Context Source Registration Subscription ${subscription_payload} Check Response Status Code 400 ${response.status_code} diff --git a/TP/NGSI-LD/ContextSource/RegistrationSubscription/DeleteContextSourceRegistrationSubscription/042_01.robot b/TP/NGSI-LD/ContextSource/RegistrationSubscription/DeleteContextSourceRegistrationSubscription/042_01.robot index 9211f09774e4d2be9770d98528ed796e7421de8f..22580179fc5bbb975c2c1a9f46da9190d332da3f 100644 --- a/TP/NGSI-LD/ContextSource/RegistrationSubscription/DeleteContextSourceRegistrationSubscription/042_01.robot +++ b/TP/NGSI-LD/ContextSource/RegistrationSubscription/DeleteContextSourceRegistrationSubscription/042_01.robot @@ -1,6 +1,7 @@ *** Settings *** Documentation Check that one can delete a context source registration subscription +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextSourceRegistrationSubscription.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -9,7 +10,6 @@ Test Setup Setup Initial Context Source Registration Subscription *** Variables *** -${subscription_id_prefix}= urn:ngsi-ld:Subscription: ${subscription_payload_file_path}= csourceSubscriptions/subscription.jsonld @@ -27,7 +27,7 @@ ${subscription_payload_file_path}= csourceSubscriptions/subscription.jsonld *** Keywords *** Setup Initial Context Source Registration Subscription - ${subscription_id}= Generate Random Entity Id ${subscription_id_prefix} + ${subscription_id}= Generate Random Subscription Id ${subscription_payload}= Load Test Sample ${subscription_payload_file_path} ${subscription_id} ${create_csrsub_response}= Create Context Source Registration Subscription ${subscription_payload} Check Response Status Code 201 ${create_csrsub_response.status_code} diff --git a/TP/NGSI-LD/ContextSource/RegistrationSubscription/QueryContextSourceRegistrationSubscriptions/041_01.robot b/TP/NGSI-LD/ContextSource/RegistrationSubscription/QueryContextSourceRegistrationSubscriptions/041_01.robot index da7ef3929cff5411004324359c0a5e4b9a204178..ec42d77d7f16ec724a188b0b41d5607a7bec3710 100644 --- a/TP/NGSI-LD/ContextSource/RegistrationSubscription/QueryContextSourceRegistrationSubscriptions/041_01.robot +++ b/TP/NGSI-LD/ContextSource/RegistrationSubscription/QueryContextSourceRegistrationSubscriptions/041_01.robot @@ -1,6 +1,7 @@ *** Settings *** Documentation Check that one can query context source registration subscriptions +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextSourceRegistrationSubscription.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -10,7 +11,6 @@ Test Teardown Delete Created Context Source Registration Subscriptions *** Variables *** -${subscription_id_prefix}= urn:ngsi-ld:Subscription: ${first_subscription_payload_file_path}= csourceSubscriptions/subscription.jsonld ${second_subscription_payload_file_path}= csourceSubscriptions/subscription-watchedAttributes.jsonld ${expectation_file_path}= csourceSubscriptions/expectations/subscriptions-035-01.json @@ -31,8 +31,8 @@ ${expectation_file_path}= csourceSubscriptions/expectation *** Keywords *** Setup Initial Context Source Registration Subscriptions - ${first_subscription_id}= Generate Random Entity Id ${subscription_id_prefix} - ${second_subscription_id}= Generate Random Entity Id ${subscription_id_prefix} + ${first_subscription_id}= Generate Random Subscription Id + ${second_subscription_id}= Generate Random Subscription Id ${first_subscription_payload}= Load Test Sample ... ${first_subscription_payload_file_path} ... ${first_subscription_id} diff --git a/TP/NGSI-LD/ContextSource/RegistrationSubscription/QueryContextSourceRegistrationSubscriptions/041_02.robot b/TP/NGSI-LD/ContextSource/RegistrationSubscription/QueryContextSourceRegistrationSubscriptions/041_02.robot index 2a0c803e45d2241923ca557e163abe21721ee827..7b6f2b6a7514096c679d51002efeda79b0beb841 100644 --- a/TP/NGSI-LD/ContextSource/RegistrationSubscription/QueryContextSourceRegistrationSubscriptions/041_02.robot +++ b/TP/NGSI-LD/ContextSource/RegistrationSubscription/QueryContextSourceRegistrationSubscriptions/041_02.robot @@ -1,6 +1,7 @@ *** Settings *** Documentation Check that one can query context source registration subscriptions with a limit parameter and it will be the maximum number of subscriptions to be retrieved +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextSourceRegistrationSubscription.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -11,7 +12,6 @@ Test Template Query Context Source Registration Subscriptions With Limit P *** Variables *** -${subscription_id_prefix}= urn:ngsi-ld:Subscription: ${first_subscription_payload_file_path}= csourceSubscriptions/subscription.jsonld ${second_subscription_payload_file_path}= csourceSubscriptions/subscription-watchedAttributes.jsonld ${third_subscription_payload_file_path}= csourceSubscriptions/subscription-geoQ.jsonld @@ -44,9 +44,9 @@ Query Context Source Registration Subscriptions With Limit Parameter ... ${response.json()} Setup Initial Context Source Registration Subscriptions - ${first_subscription_id}= Generate Random Entity Id ${subscription_id_prefix} - ${second_subscription_id}= Generate Random Entity Id ${subscription_id_prefix} - ${third_subscription_id}= Generate Random Entity Id ${subscription_id_prefix} + ${first_subscription_id}= Generate Random Subscription Id + ${second_subscription_id}= Generate Random Subscription Id + ${third_subscription_id}= Generate Random Subscription Id ${first_subscription_payload}= Load Test Sample ... ${first_subscription_payload_file_path} ... ${first_subscription_id} diff --git a/TP/NGSI-LD/ContextSource/RegistrationSubscription/QueryContextSourceRegistrationSubscriptions/041_03.robot b/TP/NGSI-LD/ContextSource/RegistrationSubscription/QueryContextSourceRegistrationSubscriptions/041_03.robot index a239006b1b3949a086c97e5e6a784234d0ef96d4..b2bfbdcd50092e956ec2a86a345a4da2a7100a5c 100644 --- a/TP/NGSI-LD/ContextSource/RegistrationSubscription/QueryContextSourceRegistrationSubscriptions/041_03.robot +++ b/TP/NGSI-LD/ContextSource/RegistrationSubscription/QueryContextSourceRegistrationSubscriptions/041_03.robot @@ -1,6 +1,7 @@ *** Settings *** Documentation Check that one can query context source registration subscriptions with providing page and limit parameters for pagination +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextSourceRegistrationSubscription.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -11,7 +12,6 @@ Test Template Query Context Source Registration Subscriptions With Limit A *** Variables *** -${subscription_id_prefix}= urn:ngsi-ld:Subscription: ${first_subscription_payload_file_path}= csourceSubscriptions/subscription.jsonld ${second_subscription_payload_file_path}= csourceSubscriptions/subscription-watchedAttributes.jsonld ${third_subscription_payload_file_path}= csourceSubscriptions/subscription-geoQ.jsonld @@ -45,9 +45,9 @@ Query Context Source Registration Subscriptions With Limit And Page Parameters Check Pagination Prev And Next Headers ${prev_link} ${next_link} ${response.headers} Setup Initial Context Source Registration Subscriptions - ${first_subscription_id}= Generate Random Entity Id ${subscription_id_prefix} - ${second_subscription_id}= Generate Random Entity Id ${subscription_id_prefix} - ${third_subscription_id}= Generate Random Entity Id ${subscription_id_prefix} + ${first_subscription_id}= Generate Random Subscription Id + ${second_subscription_id}= Generate Random Subscription Id + ${third_subscription_id}= Generate Random Subscription Id ${first_subscription_payload}= Load Test Sample ... ${first_subscription_payload_file_path} ... ${first_subscription_id} diff --git a/TP/NGSI-LD/ContextSource/RegistrationSubscription/RetrieveContextSourceRegistrationSubscription/040_01.robot b/TP/NGSI-LD/ContextSource/RegistrationSubscription/RetrieveContextSourceRegistrationSubscription/040_01.robot index 060950e4f1ea1edba9e6418a30ae9e3be3a18f96..fff70391c5da3218c8a51ac2c43d5e4022cdbdf6 100644 --- a/TP/NGSI-LD/ContextSource/RegistrationSubscription/RetrieveContextSourceRegistrationSubscription/040_01.robot +++ b/TP/NGSI-LD/ContextSource/RegistrationSubscription/RetrieveContextSourceRegistrationSubscription/040_01.robot @@ -11,7 +11,6 @@ Test Teardown Delete Created Context Source Registration Subscription *** Variables *** -${subscription_id_prefix}= urn:ngsi-ld:Subscription: ${subscription_payload_file_path}= csourceSubscriptions/subscription.jsonld ${expectation_file_path}= csourceSubscriptions/expectations/subscriptions-040-01.json @@ -58,7 +57,7 @@ ${expectation_file_path}= csourceSubscriptions/expectations/subscr *** Keywords *** Setup Initial Context Source Registration Subscription - ${subscription_id}= Generate Random Entity Id ${subscription_id_prefix} + ${subscription_id}= Generate Random Subscription Id ${subscription_payload}= Load Test Sample ${subscription_payload_file_path} ${subscription_id} ${create_csrsub_response}= Create Context Source Registration Subscription ${subscription_payload} Check Response Status Code 201 ${create_csrsub_response.status_code} diff --git a/TP/NGSI-LD/ContextSource/RegistrationSubscription/UpdateContextSourceRegistrationSubscription/039_01.robot b/TP/NGSI-LD/ContextSource/RegistrationSubscription/UpdateContextSourceRegistrationSubscription/039_01.robot index 7f4e6e2195e7aff56f7e605c465ad70bbf1ce30d..21c60e73424163f9d77cc401c3bb5639d2b88234 100644 --- a/TP/NGSI-LD/ContextSource/RegistrationSubscription/UpdateContextSourceRegistrationSubscription/039_01.robot +++ b/TP/NGSI-LD/ContextSource/RegistrationSubscription/UpdateContextSourceRegistrationSubscription/039_01.robot @@ -1,6 +1,7 @@ *** Settings *** Documentation Check that one can update a context source registration subscription +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextSourceRegistrationSubscription.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -10,7 +11,6 @@ Test Teardown Delete Initial Context Source Registration Subscriptions *** Variables *** -${subscription_id_prefix}= urn:ngsi-ld:Subscription: ${subscription_payload_file_path}= csourceSubscriptions/subscription.jsonld ${subscription_update_fragment_file_path}= csourceSubscriptions/fragments/subscription-update.json @@ -39,7 +39,7 @@ ${subscription_update_fragment_file_path}= csourceSubscriptions/fragments/s *** Keywords *** Setup Initial Context Source Registration Subscriptions - ${subscription_id}= Generate Random Entity Id ${subscription_id_prefix} + ${subscription_id}= Generate Random Subscription Id ${subscription_payload}= Load Test Sample ${subscription_payload_file_path} ${subscription_id} ${create_csrsub_response}= Create Context Source Registration Subscription ${subscription_payload} Check Response Status Code 201 ${create_csrsub_response.status_code} diff --git a/TP/NGSI-LD/ContextSource/RegistrationSubscription/UpdateContextSourceRegistrationSubscription/039_04.robot b/TP/NGSI-LD/ContextSource/RegistrationSubscription/UpdateContextSourceRegistrationSubscription/039_04.robot index f3fdf28aaf98fbe4c1ad57ab8fd622c61eed75b1..60bd8fe49c946ee8cab5ce5af304081630b240e5 100644 --- a/TP/NGSI-LD/ContextSource/RegistrationSubscription/UpdateContextSourceRegistrationSubscription/039_04.robot +++ b/TP/NGSI-LD/ContextSource/RegistrationSubscription/UpdateContextSourceRegistrationSubscription/039_04.robot @@ -1,6 +1,7 @@ *** Settings *** Documentation Check that one cannot update a context source registration subscription with a fragment that does not meet the data types and restrictions expressed by clause 5.2.12 +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextSourceRegistrationSubscription.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -11,7 +12,6 @@ Test Template Update Context Source Registration Subscription With Invalid *** Variables *** -${subscription_id_prefix}= urn:ngsi-ld:Subscription: ${subscription_payload_file_path}= csourceSubscriptions/subscription.jsonld @@ -38,7 +38,7 @@ Update Context Source Registration Subscription With Invalid Fragment ... problem_type=${ERROR_TYPE_BAD_REQUEST_DATA} Setup Initial Context Source Registration Subscriptions - ${subscription_id}= Generate Random Entity Id ${subscription_id_prefix} + ${subscription_id}= Generate Random Subscription Id ${subscription_payload}= Load Test Sample ${subscription_payload_file_path} ${subscription_id} ${create_csrsub_response}= Create Context Source Registration Subscription ${subscription_payload} Check Response Status Code 201 ${create_csrsub_response.status_code} diff --git a/TP/NGSI-LD/ContextSource/RegistrationSubscription/UpdateContextSourceRegistrationSubscription/039_05.robot b/TP/NGSI-LD/ContextSource/RegistrationSubscription/UpdateContextSourceRegistrationSubscription/039_05.robot index 10f0799bba24100c980ecab16438b7fb497d6f0c..190741272545a78a0182710ecf9a99366b4641b6 100644 --- a/TP/NGSI-LD/ContextSource/RegistrationSubscription/UpdateContextSourceRegistrationSubscription/039_05.robot +++ b/TP/NGSI-LD/ContextSource/RegistrationSubscription/UpdateContextSourceRegistrationSubscription/039_05.robot @@ -1,6 +1,7 @@ *** Settings *** Documentation Check that one cannot update a context source registration subscription with an invalid request body (invalid JSON document) +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextSourceRegistrationSubscription.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -10,7 +11,6 @@ Test Teardown Delete Initial Context Source Registration Subscriptions *** Variables *** -${subscription_id_prefix}= urn:ngsi-ld:Subscription: ${subscription_payload_file_path}= csourceSubscriptions/subscription.jsonld ${subscription_update_fragment_file_path}= csourceSubscriptions/fragments/subscription-update-invalid-json.json @@ -30,7 +30,7 @@ ${subscription_update_fragment_file_path}= csourceSubscriptions/fragments/s *** Keywords *** Setup Initial Context Source Registration Subscriptions - ${subscription_id}= Generate Random Entity Id ${subscription_id_prefix} + ${subscription_id}= Generate Random Subscription Id ${subscription_payload}= Load Test Sample ${subscription_payload_file_path} ${subscription_id} Create Context Source Registration Subscription ${subscription_payload} Set Suite Variable ${subscription_id} diff --git a/TP/NGSI-LD/DistributedOperations/Consumption/Entity/QueryEntities/D011_01_01_inc.robot b/TP/NGSI-LD/DistributedOperations/Consumption/Entity/QueryEntities/D011_01_01_inc.robot index c3ac9e555e71c67e26fdd991203474a464c25dcf..9a0b6e1eb22d7b00b111e33ea8079df56aac3df4 100644 --- a/TP/NGSI-LD/DistributedOperations/Consumption/Entity/QueryEntities/D011_01_01_inc.robot +++ b/TP/NGSI-LD/DistributedOperations/Consumption/Entity/QueryEntities/D011_01_01_inc.robot @@ -1,10 +1,11 @@ *** Settings *** Documentation Verify that, when one has an inclusive registration on a Context Broker and an entity only on a Context Source, if one queries the Context Broker the query gets forwarded to the Context Source correctly -Resource ${EXECDIR}/resources/ApiUtils/ContextSourceRegistration.resource -Resource ${EXECDIR}/resources/ApiUtils/ContextSourceDiscovery.resource -Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationConsumption.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextSourceDiscovery.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextSourceRegistration.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -13,9 +14,7 @@ Test Teardown Delete Created Entity And Registration *** Variables *** -${entity_id_prefix} urn:ngsi-ld:Vehicle: ${entity_payload_filename} vehicle-simple-attributes.jsonld -${registration_id_prefix} urn:ngsi-ld:Registration: ${registration_payload_file_path} csourceRegistrations/context-source-registration-vehicle-complete.jsonld @@ -31,12 +30,12 @@ D011_01_01_inc Query The Context Broker With Type *** Keywords *** Setup Entity On Remote And Registration - ${entity_id}= Generate Random Entity Id ${entity_id_prefix} + ${entity_id}= Generate Random Vehicle Entity Id Set Suite Variable ${entity_id} ${response}= Create Entity ${entity_payload_filename} ${entity_id} base_url=${remote_url} Check Response Status Code 201 ${response.status_code} - ${registration_id}= Generate Random Entity Id ${registration_id_prefix} + ${registration_id}= Generate Random CSR Id Set Suite Variable ${registration_id} ${registration_payload}= Prepare Context Source Registration From File ... ${registration_id} diff --git a/TP/NGSI-LD/DistributedOperations/Consumption/Entity/QueryEntities/D011_01_02_inc.robot b/TP/NGSI-LD/DistributedOperations/Consumption/Entity/QueryEntities/D011_01_02_inc.robot index 89c5c9d2669254b015ae266104dd52152c97e04c..61e6adebf36242c584237b24e9505e1ab2bcb49f 100644 --- a/TP/NGSI-LD/DistributedOperations/Consumption/Entity/QueryEntities/D011_01_02_inc.robot +++ b/TP/NGSI-LD/DistributedOperations/Consumption/Entity/QueryEntities/D011_01_02_inc.robot @@ -1,10 +1,11 @@ *** Settings *** Documentation Verify that, when one has an inclusive registration on a Context Broker and an entity only on a Context Source, if one queries the Context Broker the query gets forwarded to the Context Source correctly -Resource ${EXECDIR}/resources/ApiUtils/ContextSourceRegistration.resource -Resource ${EXECDIR}/resources/ApiUtils/ContextSourceDiscovery.resource -Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationConsumption.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextSourceDiscovery.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextSourceRegistration.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -13,9 +14,7 @@ Test Teardown Delete Created Entity And Registration *** Variables *** -${entity_id_prefix} urn:ngsi-ld:Vehicle: ${entity_payload_filename} vehicle-simple-attributes.jsonld -${registration_id_prefix} urn:ngsi-ld:Registration: ${registration_payload_file_path} csourceRegistrations/context-source-registration-vehicle-complete.jsonld @@ -30,12 +29,12 @@ D011_01_02_inc Query The Context Broker With Type And Missing Attribute *** Keywords *** Setup Entity On Remote And Registration - ${entity_id}= Generate Random Entity Id ${entity_id_prefix} + ${entity_id}= Generate Random Vehicle Entity Id Set Suite Variable ${entity_id} ${response}= Create Entity ${entity_payload_filename} ${entity_id} base_url=${remote_url} Check Response Status Code 201 ${response.status_code} - ${registration_id}= Generate Random Entity Id ${registration_id_prefix} + ${registration_id}= Generate Random CSR Id Set Suite Variable ${registration_id} ${registration_payload}= Prepare Context Source Registration From File ... ${registration_id} diff --git a/TP/NGSI-LD/DistributedOperations/Consumption/Entity/QueryEntities/D011_01_03_inc.robot b/TP/NGSI-LD/DistributedOperations/Consumption/Entity/QueryEntities/D011_01_03_inc.robot index b412909369df75e6e7c0058f2b893583e7dc184d..66fecce4ea3175aa0fb7372c54efdc06ae0c9c06 100644 --- a/TP/NGSI-LD/DistributedOperations/Consumption/Entity/QueryEntities/D011_01_03_inc.robot +++ b/TP/NGSI-LD/DistributedOperations/Consumption/Entity/QueryEntities/D011_01_03_inc.robot @@ -1,10 +1,11 @@ *** Settings *** Documentation Verify that, when one has an inclusive registration on a Context Broker, one entity on it and another on a Context Source, if one queries the Context Broker the query gets forwarded to the Context Source correctly -Resource ${EXECDIR}/resources/ApiUtils/ContextSourceRegistration.resource -Resource ${EXECDIR}/resources/ApiUtils/ContextSourceDiscovery.resource -Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationConsumption.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextSourceDiscovery.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextSourceRegistration.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -13,10 +14,8 @@ Test Teardown Delete Created Entities And Registration *** Variables *** -${entity_id_prefix} urn:ngsi-ld:Vehicle: ${entity_payload_filename} vehicle-simple-attributes.jsonld ${entity_payload_filename2} vehicle-simple-attributes-second.jsonld -${registration_id_prefix} urn:ngsi-ld:Registration: ${registration_payload_file_path} csourceRegistrations/context-source-registration-vehicle-complete.jsonld @@ -32,17 +31,17 @@ D011_01_03_inc Query The Context Broker With Type and Attribute *** Keywords *** Create Entities With Different Payloads And Registration - ${first_entity_id}= Generate Random Entity Id ${entity_id_prefix} + ${first_entity_id}= Generate Random Vehicle Entity Id Set Suite Variable ${first_entity_id} ${response}= Create Entity ${entity_payload_filename} ${first_entity_id} Check Response Status Code 201 ${response.status_code} - ${second_entity_id}= Generate Random Entity Id ${entity_id_prefix} + ${second_entity_id}= Generate Random Vehicle Entity Id Set Suite Variable ${second_entity_id} ${response1}= Create Entity ${entity_payload_filename2} ${second_entity_id} base_url=${remote_url} Check Response Status Code 201 ${response1.status_code} - ${registration_id}= Generate Random Entity Id ${registration_id_prefix} + ${registration_id}= Generate Random CSR Id Set Suite Variable ${registration_id} ${registration_payload}= Prepare Context Source Registration From File ... ${registration_id} diff --git a/TP/NGSI-LD/DistributedOperations/Consumption/Entity/QueryEntities/D011_01_04_inc.robot b/TP/NGSI-LD/DistributedOperations/Consumption/Entity/QueryEntities/D011_01_04_inc.robot index 4a9fd8caca8927ffd40c84c39db5509dd9628227..005cd4881dc6d322500ec8f3732393da2d1850cd 100644 --- a/TP/NGSI-LD/DistributedOperations/Consumption/Entity/QueryEntities/D011_01_04_inc.robot +++ b/TP/NGSI-LD/DistributedOperations/Consumption/Entity/QueryEntities/D011_01_04_inc.robot @@ -1,10 +1,11 @@ *** Settings *** Documentation Verify that, when one has an inclusive registration on a Context Broker, one entity on it and another on a Context Source, if one queries the Context Broker the query gets forwarded to the Context Source correctly -Resource ${EXECDIR}/resources/ApiUtils/ContextSourceRegistration.resource -Resource ${EXECDIR}/resources/ApiUtils/ContextSourceDiscovery.resource -Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationConsumption.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextSourceDiscovery.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextSourceRegistration.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -13,10 +14,8 @@ Test Teardown Delete Created Entities And Registration *** Variables *** -${entity_id_prefix} urn:ngsi-ld:Vehicle: ${entity_payload_filename} vehicle-simple-attributes.jsonld ${entity_payload_filename2} vehicle-simple-attributes-second.jsonld -${registration_id_prefix} urn:ngsi-ld:Registration: ${registration_payload_file_path} csourceRegistrations/context-source-registration-vehicle-complete.jsonld @@ -31,17 +30,17 @@ D011_01_04_inc Query The Context Broker With Type and Attribute In Neither *** Keywords *** Create Entities With Different Payloads And Registration - ${first_entity_id}= Generate Random Entity Id ${entity_id_prefix} + ${first_entity_id}= Generate Random Vehicle Entity Id Set Suite Variable ${first_entity_id} ${response}= Create Entity ${entity_payload_filename} ${first_entity_id} base_url=${remote_url} Check Response Status Code 201 ${response.status_code} - ${second_entity_id}= Generate Random Entity Id ${entity_id_prefix} + ${second_entity_id}= Generate Random Vehicle Entity Id Set Suite Variable ${second_entity_id} ${response1}= Create Entity ${entity_payload_filename2} ${second_entity_id} Check Response Status Code 201 ${response1.status_code} - ${registration_id}= Generate Random Entity Id ${registration_id_prefix} + ${registration_id}= Generate Random CSR Id Set Suite Variable ${registration_id} ${registration_payload}= Prepare Context Source Registration From File ... ${registration_id} diff --git a/TP/NGSI-LD/DistributedOperations/Consumption/Entity/QueryEntities/D011_01_05_inc.robot b/TP/NGSI-LD/DistributedOperations/Consumption/Entity/QueryEntities/D011_01_05_inc.robot index ce4f5539f9a39b911dcf0e8467a8f7fff23d06ff..857d349dd8c5d3b88c59dfdaac7962d3c660fb3e 100644 --- a/TP/NGSI-LD/DistributedOperations/Consumption/Entity/QueryEntities/D011_01_05_inc.robot +++ b/TP/NGSI-LD/DistributedOperations/Consumption/Entity/QueryEntities/D011_01_05_inc.robot @@ -1,10 +1,11 @@ *** Settings *** Documentation Verify that, when one has an inclusive registration on a Context Broker, entities with same id on the Context Broker and on a Context Source, if one queries the Context Broker the query gets forwarded to the Context Source correctly -Resource ${EXECDIR}/resources/ApiUtils/ContextSourceRegistration.resource -Resource ${EXECDIR}/resources/ApiUtils/ContextSourceDiscovery.resource -Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationConsumption.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextSourceDiscovery.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextSourceRegistration.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -13,10 +14,8 @@ Test Teardown Delete Created Entities And Registration *** Variables *** -${entity_id_prefix} urn:ngsi-ld:Vehicle: ${entity_payload_filename} vehicle-simple-attributes.jsonld ${entity_payload_filename2} vehicle-simple-different-attributes.jsonld -${registration_id_prefix} urn:ngsi-ld:Registration: ${registration_payload_file_path} csourceRegistrations/context-source-registration-vehicle-complete.jsonld @@ -38,7 +37,7 @@ D011_01_05_inc Query The Context Broker With Type *** Keywords *** Create Entities With Different Payloads And Registration - ${entity_id}= Generate Random Entity Id ${entity_id_prefix} + ${entity_id}= Generate Random Vehicle Entity Id Set Suite Variable ${entity_id} ${response}= Create Entity ${entity_payload_filename} ${entity_id} base_url=${remote_url} Check Response Status Code 201 ${response.status_code} @@ -46,7 +45,7 @@ Create Entities With Different Payloads And Registration ${response}= Create Entity ${entity_payload_filename2} ${entity_id} Check Response Status Code 201 ${response.status_code} - ${registration_id}= Generate Random Entity Id ${registration_id_prefix} + ${registration_id}= Generate Random CSR Id Set Suite Variable ${registration_id} ${registration_payload}= Prepare Context Source Registration From File ... ${registration_id} diff --git a/TP/NGSI-LD/DistributedOperations/Consumption/Entity/QueryEntities/D011_02_inc.robot b/TP/NGSI-LD/DistributedOperations/Consumption/Entity/QueryEntities/D011_02_inc.robot index 1bf3a5c2ae2363a5b8ddae918f3ba9e65097fab2..16e71d60570e72a1685034f8998f0d4bb45cdb80 100644 --- a/TP/NGSI-LD/DistributedOperations/Consumption/Entity/QueryEntities/D011_02_inc.robot +++ b/TP/NGSI-LD/DistributedOperations/Consumption/Entity/QueryEntities/D011_02_inc.robot @@ -1,10 +1,11 @@ *** Settings *** Documentation Verify that, when one has an inclusive registration on a Context Broker and an entity only on a Context Source, if one queries the Context Broker with local flag entity not found error is raised -Resource ${EXECDIR}/resources/ApiUtils/ContextSourceRegistration.resource -Resource ${EXECDIR}/resources/ApiUtils/ContextSourceDiscovery.resource -Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationConsumption.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextSourceDiscovery.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextSourceRegistration.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -13,9 +14,7 @@ Test Teardown Delete Created Entity And Registration *** Variables *** -${entity_id_prefix} urn:ngsi-ld:Vehicle: ${entity_payload_filename} vehicle-simple-attributes.jsonld -${registration_id_prefix} urn:ngsi-ld:Registration: ${registration_payload_file_path} csourceRegistrations/context-source-registration-vehicle-complete.jsonld @@ -30,12 +29,12 @@ D011_02_inc Query The Context Broker With Local Flag *** Keywords *** Setup Entity On Remote And Registration - ${entity_id}= Generate Random Entity Id ${entity_id_prefix} + ${entity_id}= Generate Random Vehicle Entity Id Set Suite Variable ${entity_id} ${response}= Create Entity ${entity_payload_filename} ${entity_id} base_url=${remote_url} Check Response Status Code 201 ${response.status_code} - ${registration_id}= Generate Random Entity Id ${registration_id_prefix} + ${registration_id}= Generate Random CSR Id Set Suite Variable ${registration_id} ${registration_payload}= Prepare Context Source Registration From File ... ${registration_id} diff --git a/TP/NGSI-LD/DistributedOperations/Consumption/Entity/RetrieveEntity/D010_01_inc.robot b/TP/NGSI-LD/DistributedOperations/Consumption/Entity/RetrieveEntity/D010_01_inc.robot index 4905c505bc675d3b9d6119e7aa363f90f6ab2aa4..3e33837ee4d28adbc3ca7cc302f9b95ecd6f54f5 100644 --- a/TP/NGSI-LD/DistributedOperations/Consumption/Entity/RetrieveEntity/D010_01_inc.robot +++ b/TP/NGSI-LD/DistributedOperations/Consumption/Entity/RetrieveEntity/D010_01_inc.robot @@ -1,10 +1,11 @@ *** Settings *** Documentation Verify that, when one has an inclusive registration on a Context Broker and an entity only on a Context Source, if one retrieves entity from the Context Broker the request gets forwarded to the Context Source correctly -Resource ${EXECDIR}/resources/ApiUtils/ContextSourceRegistration.resource -Resource ${EXECDIR}/resources/ApiUtils/ContextSourceDiscovery.resource -Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationConsumption.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextSourceDiscovery.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextSourceRegistration.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -13,9 +14,7 @@ Test Teardown Delete Created Entity And Registration *** Variables *** -${entity_id_prefix} urn:ngsi-ld:Vehicle: ${entity_payload_filename} vehicle-simple-attributes.jsonld -${registration_id_prefix} urn:ngsi-ld:Registration: ${registration_payload_file_path} csourceRegistrations/context-source-registration-vehicle-complete.jsonld @@ -30,12 +29,12 @@ D010_01_inc Retrieve entity on a Context Source from the Context Broker *** Keywords *** Setup Entity On Remote And Registration - ${entity_id}= Generate Random Entity Id ${entity_id_prefix} + ${entity_id}= Generate Random Vehicle Entity Id Set Suite Variable ${entity_id} ${response}= Create Entity ${entity_payload_filename} ${entity_id} base_url=${remote_url} Check Response Status Code 201 ${response.status_code} - ${registration_id}= Generate Random Entity Id ${registration_id_prefix} + ${registration_id}= Generate Random CSR Id Set Suite Variable ${registration_id} ${registration_payload}= Prepare Context Source Registration From File ... ${registration_id} diff --git a/TP/NGSI-LD/DistributedOperations/Consumption/Entity/RetrieveEntity/D010_02_inc.robot b/TP/NGSI-LD/DistributedOperations/Consumption/Entity/RetrieveEntity/D010_02_inc.robot index 6f0a6add6010e36823777ba708d6fc576d8612b7..240c05c55adb64981165d50efb96c4b7ae74e3a7 100644 --- a/TP/NGSI-LD/DistributedOperations/Consumption/Entity/RetrieveEntity/D010_02_inc.robot +++ b/TP/NGSI-LD/DistributedOperations/Consumption/Entity/RetrieveEntity/D010_02_inc.robot @@ -1,10 +1,11 @@ *** Settings *** Documentation Verify that, when one has an inclusive registration on a Context Broker and an entity only on a Context Source, if one retrieves entity from the Context Broker with local flag entity not found error is raised -Resource ${EXECDIR}/resources/ApiUtils/ContextSourceRegistration.resource -Resource ${EXECDIR}/resources/ApiUtils/ContextSourceDiscovery.resource -Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationConsumption.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextSourceDiscovery.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextSourceRegistration.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -13,9 +14,7 @@ Test Teardown Delete Created Entity And Registration *** Variables *** -${entity_id_prefix} urn:ngsi-ld:Vehicle: ${entity_payload_filename} vehicle-simple-attributes.jsonld -${registration_id_prefix} urn:ngsi-ld:Registration: ${registration_payload_file_path} csourceRegistrations/context-source-registration-vehicle-complete.jsonld @@ -29,12 +28,12 @@ D010_02_inc Retrieve entity on a Context Source from the Context Broker with loc *** Keywords *** Setup Entity On Remote And Registration - ${entity_id}= Generate Random Entity Id ${entity_id_prefix} + ${entity_id}= Generate Random Vehicle Entity Id Set Suite Variable ${entity_id} ${response}= Create Entity ${entity_payload_filename} ${entity_id} base_url=${remote_url} Check Response Status Code 201 ${response.status_code} - ${registration_id}= Generate Random Entity Id ${registration_id_prefix} + ${registration_id}= Generate Random CSR Id Set Suite Variable ${registration_id} ${registration_payload}= Prepare Context Source Registration From File ... ${registration_id} diff --git a/TP/NGSI-LD/DistributedOperations/Provision/Entities/CreateEntity/D001_01_inc.robot b/TP/NGSI-LD/DistributedOperations/Provision/Entities/CreateEntity/D001_01_inc.robot index c6af44fac782d1db7cc6fc4743bd2840717964e4..9c242aaf4c433ae784bf65ca9859ee5f2b2781c6 100644 --- a/TP/NGSI-LD/DistributedOperations/Provision/Entities/CreateEntity/D001_01_inc.robot +++ b/TP/NGSI-LD/DistributedOperations/Provision/Entities/CreateEntity/D001_01_inc.robot @@ -1,10 +1,11 @@ *** Settings *** Documentation Verify that, when one has an inclusive registration on a Context Broker, one is able to create entities on both Context Broker and Context Source -Resource ${EXECDIR}/resources/ApiUtils/ContextSourceRegistration.resource -Resource ${EXECDIR}/resources/ApiUtils/ContextSourceDiscovery.resource -Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationConsumption.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextSourceDiscovery.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextSourceRegistration.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -13,9 +14,7 @@ Test Teardown Delete Created Entities And Registration *** Variables *** -${entity_id_prefix} urn:ngsi-ld:Vehicle: ${entity_payload_filename} vehicle-simple-attributes.jsonld -${registration_id_prefix} urn:ngsi-ld:Registration: ${registration_payload_file_path} csourceRegistrations/context-source-registration-vehicle-redirection-ops.jsonld @@ -36,10 +35,10 @@ D001_01_inc Create Entity On Both Context Broker and Context Source *** Keywords *** Setup Entity Id And Registration - ${entity_id}= Generate Random Entity Id ${entity_id_prefix} + ${entity_id}= Generate Random Vehicle Entity Id Set Suite Variable ${entity_id} - ${registration_id}= Generate Random Entity Id ${registration_id_prefix} + ${registration_id}= Generate Random CSR Id Set Suite Variable ${registration_id} ${registration_payload}= Prepare Context Source Registration From File ... ${registration_id} diff --git a/TP/NGSI-LD/DistributedOperations/Provision/Entities/CreateEntity/D001_02_inc.robot b/TP/NGSI-LD/DistributedOperations/Provision/Entities/CreateEntity/D001_02_inc.robot index 6e34b123d243e174be0aaf364fab220462c19a04..aa6822582d408aef24721c435da2b314d37a6d39 100644 --- a/TP/NGSI-LD/DistributedOperations/Provision/Entities/CreateEntity/D001_02_inc.robot +++ b/TP/NGSI-LD/DistributedOperations/Provision/Entities/CreateEntity/D001_02_inc.robot @@ -1,10 +1,11 @@ *** Settings *** Documentation Check that if one requests the Context Broker to create an entity that matches an inclusive registration but is malformed, this is created neither on the Context Broker nor on the Context Source -Resource ${EXECDIR}/resources/ApiUtils/ContextSourceRegistration.resource -Resource ${EXECDIR}/resources/ApiUtils/ContextSourceDiscovery.resource -Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationConsumption.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextSourceDiscovery.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextSourceRegistration.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -14,9 +15,7 @@ Test Teardown Delete Created Registration *** Variables *** ${entity_id} InvalidUriExample -${entity_id_prefix} urn:ngsi-ld:Vehicle: ${entity_payload_filename} vehicle-simple-attributes.jsonld -${registration_id_prefix} urn:ngsi-ld:Registration: ${context_source_registration_payload_file_path} csourceRegistrations/context-source-registration-vehicle-redirection-ops.jsonld @@ -37,7 +36,7 @@ D001_02_inc Request to create an entity with a malformed id on both Context Brok *** Keywords *** Setup Initial Context Source Registration - ${context_source_registration_id}= Generate Random Entity Id ${registration_id_prefix} + ${context_source_registration_id}= Generate Random CSR Id Set Suite Variable ${context_source_registration_id} ${registration_payload}= Prepare Context Source Registration From File ... ${context_source_registration_id} diff --git a/TP/NGSI-LD/DistributedOperations/Provision/Entities/CreateEntity/D001_03_01_inc.robot b/TP/NGSI-LD/DistributedOperations/Provision/Entities/CreateEntity/D001_03_01_inc.robot index b6278f521b5372c176f3865820c97166212a5a79..3a46a3e7a7bedfd3e582cd1f3468db327e802c31 100644 --- a/TP/NGSI-LD/DistributedOperations/Provision/Entities/CreateEntity/D001_03_01_inc.robot +++ b/TP/NGSI-LD/DistributedOperations/Provision/Entities/CreateEntity/D001_03_01_inc.robot @@ -1,10 +1,11 @@ *** Settings *** Documentation Verify that, when one has an entity and an inclusive registration on a Context Broker, one is able to create that entity on a Context Source from the Context Broker but gets an error for the Context Broker -Resource ${EXECDIR}/resources/ApiUtils/ContextSourceRegistration.resource -Resource ${EXECDIR}/resources/ApiUtils/ContextSourceDiscovery.resource -Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationConsumption.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextSourceDiscovery.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextSourceRegistration.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -13,9 +14,7 @@ Test Teardown Delete Created Entities And Registration *** Variables *** -${entity_id_prefix} urn:ngsi-ld:Vehicle: ${entity_payload_filename} vehicle-simple-attributes.jsonld -${registration_id_prefix} urn:ngsi-ld:Registration: ${registration_payload_file_path} csourceRegistrations/context-source-registration-vehicle-redirection-ops.jsonld @@ -35,12 +34,12 @@ D001_03_01_inc Create entity already existing locally on a Context Source *** Keywords *** Setup Entity On Local And Registration - ${entity_id}= Generate Random Entity Id ${entity_id_prefix} + ${entity_id}= Generate Random Vehicle Entity Id Set Suite Variable ${entity_id} ${response}= Create Entity ${entity_payload_filename} ${entity_id} Check Response Status Code 201 ${response.status_code} - ${registration_id}= Generate Random Entity Id ${registration_id_prefix} + ${registration_id}= Generate Random CSR Id Set Suite Variable ${registration_id} ${registration_payload}= Prepare Context Source Registration From File ... ${registration_id} diff --git a/TP/NGSI-LD/DistributedOperations/Provision/Entities/CreateEntity/D001_03_02_inc.robot b/TP/NGSI-LD/DistributedOperations/Provision/Entities/CreateEntity/D001_03_02_inc.robot index d403306c180a9c0e1888c672739555bba655f713..8df22d6fa4edecb36abd65081ffcf8117cdb224f 100644 --- a/TP/NGSI-LD/DistributedOperations/Provision/Entities/CreateEntity/D001_03_02_inc.robot +++ b/TP/NGSI-LD/DistributedOperations/Provision/Entities/CreateEntity/D001_03_02_inc.robot @@ -1,10 +1,11 @@ *** Settings *** Documentation Verify that, when one has an entity on a Context Broker and on a Context Source and an inclusive registration on the Context Broker, one is not able to create that entity on the Context Source from the Context Broker -Resource ${EXECDIR}/resources/ApiUtils/ContextSourceRegistration.resource -Resource ${EXECDIR}/resources/ApiUtils/ContextSourceDiscovery.resource -Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationConsumption.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextSourceDiscovery.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextSourceRegistration.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -13,9 +14,7 @@ Test Teardown Delete Created Entities And Registration *** Variables *** -${entity_id_prefix} urn:ngsi-ld:Vehicle: ${entity_payload_filename} vehicle-simple-attributes.jsonld -${registration_id_prefix} urn:ngsi-ld:Registration: ${registration_payload_file_path} csourceRegistrations/context-source-registration-vehicle-redirection-ops.jsonld @@ -33,14 +32,14 @@ D001_03_02_inc Create entity already existing on both Context Broker and Context *** Keywords *** Setup Entities And Registration - ${entity_id}= Generate Random Entity Id ${entity_id_prefix} + ${entity_id}= Generate Random Vehicle Entity Id Set Suite Variable ${entity_id} ${response}= Create Entity ${entity_payload_filename} ${entity_id} Check Response Status Code 201 ${response.status_code} ${response}= Create Entity ${entity_payload_filename} ${entity_id} base_url=${remote_url} Check Response Status Code 201 ${response.status_code} - ${registration_id}= Generate Random Entity Id ${registration_id_prefix} + ${registration_id}= Generate Random CSR Id Set Suite Variable ${registration_id} ${registration_payload}= Prepare Context Source Registration From File ... ${registration_id} diff --git a/TP/NGSI-LD/DistributedOperations/Provision/Entities/CreateEntity/D001_03_03_inc.robot b/TP/NGSI-LD/DistributedOperations/Provision/Entities/CreateEntity/D001_03_03_inc.robot index 3fcc270e3284dd6375acf275d1627e5a6f4eface..44f6b4d6fa3208ce8e05b622f2992ff54b2a27de 100644 --- a/TP/NGSI-LD/DistributedOperations/Provision/Entities/CreateEntity/D001_03_03_inc.robot +++ b/TP/NGSI-LD/DistributedOperations/Provision/Entities/CreateEntity/D001_03_03_inc.robot @@ -1,10 +1,11 @@ *** Settings *** Documentation Verify that, when one has an entity on a Context Source and an inclusive registration on a Context Broker, one is not able to create that entity on the Context Source from the Context Broker but one is able to create it on the Context Broker -Resource ${EXECDIR}/resources/ApiUtils/ContextSourceRegistration.resource -Resource ${EXECDIR}/resources/ApiUtils/ContextSourceDiscovery.resource -Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationConsumption.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextSourceDiscovery.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextSourceRegistration.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -13,9 +14,7 @@ Test Teardown Delete Created Entities And Registration *** Variables *** -${entity_id_prefix} urn:ngsi-ld:Vehicle: ${entity_payload_filename} vehicle-simple-attributes.jsonld -${registration_id_prefix} urn:ngsi-ld:Registration: ${registration_payload_file_path} csourceRegistrations/context-source-registration-vehicle-redirection-ops.jsonld @@ -35,12 +34,12 @@ D001_03_03_inc Create entity already existing remotely on the Context Broker *** Keywords *** Setup Entity On Remote And Registration - ${entity_id}= Generate Random Entity Id ${entity_id_prefix} + ${entity_id}= Generate Random Vehicle Entity Id Set Suite Variable ${entity_id} ${response}= Create Entity ${entity_payload_filename} ${entity_id} base_url=${remote_url} Check Response Status Code 201 ${response.status_code} - ${registration_id}= Generate Random Entity Id ${registration_id_prefix} + ${registration_id}= Generate Random CSR Id Set Suite Variable ${registration_id} ${registration_payload}= Prepare Context Source Registration From File ... ${registration_id} diff --git a/TP/NGSI-LD/DistributedOperations/Provision/Entities/DeleteEntity/D002_01_inc.robot b/TP/NGSI-LD/DistributedOperations/Provision/Entities/DeleteEntity/D002_01_inc.robot index 16431571774be4d3dac36b07f30f7b42aca351d4..afe32c1492406215b58f62cd29813fd089196e0e 100644 --- a/TP/NGSI-LD/DistributedOperations/Provision/Entities/DeleteEntity/D002_01_inc.robot +++ b/TP/NGSI-LD/DistributedOperations/Provision/Entities/DeleteEntity/D002_01_inc.robot @@ -1,10 +1,11 @@ *** Settings *** Documentation Verify that, when one has an inclusive registration on a Context Broker, one is able to delete entities on both Context Broker and Context Source -Resource ${EXECDIR}/resources/ApiUtils/ContextSourceRegistration.resource -Resource ${EXECDIR}/resources/ApiUtils/ContextSourceDiscovery.resource -Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationConsumption.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextSourceDiscovery.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextSourceRegistration.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -13,9 +14,7 @@ Test Teardown Delete Created Entities And Registration *** Variables *** -${entity_id_prefix} urn:ngsi-ld:Vehicle: ${entity_payload_filename} vehicle-simple-attributes.jsonld -${registration_id_prefix} urn:ngsi-ld:Registration: ${registration_payload_file_path} csourceRegistrations/context-source-registration-vehicle-redirection-ops.jsonld @@ -32,14 +31,14 @@ D002_01_inc Delete Entities On Both Context Broker and Context Source *** Keywords *** Setup Entities And Registration - ${entity_id}= Generate Random Entity Id ${entity_id_prefix} + ${entity_id}= Generate Random Vehicle Entity Id Set Suite Variable ${entity_id} ${response}= Create Entity ${entity_payload_filename} ${entity_id} Check Response Status Code 201 ${response.status_code} ${response}= Create Entity ${entity_payload_filename} ${entity_id} base_url=${remote_url} Check Response Status Code 201 ${response.status_code} - ${registration_id}= Generate Random Entity Id ${registration_id_prefix} + ${registration_id}= Generate Random CSR Id Set Suite Variable ${registration_id} ${registration_payload}= Prepare Context Source Registration From File ... ${registration_id} diff --git a/TP/NGSI-LD/DistributedOperations/Provision/Entities/DeleteEntity/D002_02_01_inc.robot b/TP/NGSI-LD/DistributedOperations/Provision/Entities/DeleteEntity/D002_02_01_inc.robot index 9b25cf1ab0cc3454cc16f23fd0c5e79469fe0539..788314e82ceb487d57add49d5c4a3a6fee714c5e 100644 --- a/TP/NGSI-LD/DistributedOperations/Provision/Entities/DeleteEntity/D002_02_01_inc.robot +++ b/TP/NGSI-LD/DistributedOperations/Provision/Entities/DeleteEntity/D002_02_01_inc.robot @@ -1,10 +1,11 @@ *** Settings *** Documentation Verify that, when one has an inclusive registration on a Context Broker, one is able to delete entities locally and should get a BatchOperationResult structure -Resource ${EXECDIR}/resources/ApiUtils/ContextSourceRegistration.resource -Resource ${EXECDIR}/resources/ApiUtils/ContextSourceDiscovery.resource -Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationConsumption.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextSourceDiscovery.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextSourceRegistration.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -13,9 +14,7 @@ Test Teardown Delete Created Entity And Registration *** Variables *** -${entity_id_prefix} urn:ngsi-ld:Vehicle: ${entity_payload_filename} vehicle-simple-attributes.jsonld -${registration_id_prefix} urn:ngsi-ld:Registration: ${registration_payload_file_path} csourceRegistrations/context-source-registration-vehicle-redirection-ops.jsonld @@ -30,12 +29,12 @@ D002_02_01_inc Delete Entity On The Context Broker *** Keywords *** Setup Entity On Local And Registration - ${entity_id}= Generate Random Entity Id ${entity_id_prefix} + ${entity_id}= Generate Random Vehicle Entity Id Set Suite Variable ${entity_id} ${response}= Create Entity ${entity_payload_filename} ${entity_id} Check Response Status Code 201 ${response.status_code} - ${registration_id}= Generate Random Entity Id ${registration_id_prefix} + ${registration_id}= Generate Random CSR Id Set Suite Variable ${registration_id} ${registration_payload}= Prepare Context Source Registration From File ... ${registration_id} diff --git a/TP/NGSI-LD/DistributedOperations/Provision/Entities/DeleteEntity/D002_02_02_inc.robot b/TP/NGSI-LD/DistributedOperations/Provision/Entities/DeleteEntity/D002_02_02_inc.robot index aa00071a86c1be4921b4c823041f2985cbc0eaed..4bb8865961cf56cf5df609e48a8e47c9cc540d3c 100644 --- a/TP/NGSI-LD/DistributedOperations/Provision/Entities/DeleteEntity/D002_02_02_inc.robot +++ b/TP/NGSI-LD/DistributedOperations/Provision/Entities/DeleteEntity/D002_02_02_inc.robot @@ -1,10 +1,11 @@ *** Settings *** Documentation Verify that, when one has an inclusive registration on a Context Broker, one is able to delete entities on a Context Source and should get a BatchOperationResult structure -Resource ${EXECDIR}/resources/ApiUtils/ContextSourceRegistration.resource -Resource ${EXECDIR}/resources/ApiUtils/ContextSourceDiscovery.resource -Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationConsumption.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextSourceDiscovery.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextSourceRegistration.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -13,9 +14,7 @@ Test Teardown Delete Created Entity And Registration *** Variables *** -${entity_id_prefix} urn:ngsi-ld:Vehicle: ${entity_payload_filename} vehicle-simple-attributes.jsonld -${registration_id_prefix} urn:ngsi-ld:Registration: ${registration_payload_file_path} csourceRegistrations/context-source-registration-vehicle-redirection-ops.jsonld @@ -30,12 +29,12 @@ D002_02_02_inc Delete Entity On a Context Source *** Keywords *** Setup Entity On Remote And Registration - ${entity_id}= Generate Random Entity Id ${entity_id_prefix} + ${entity_id}= Generate Random Vehicle Entity Id Set Suite Variable ${entity_id} ${response}= Create Entity ${entity_payload_filename} ${entity_id} base_url=${remote_url} Check Response Status Code 201 ${response.status_code} - ${registration_id}= Generate Random Entity Id ${registration_id_prefix} + ${registration_id}= Generate Random CSR Id Set Suite Variable ${registration_id} ${registration_payload}= Prepare Context Source Registration From File ... ${registration_id} diff --git a/TP/NGSI-LD/DistributedOperations/Provision/EntityAttributes/UpdateEntityAttributes/D004_01_inc.robot b/TP/NGSI-LD/DistributedOperations/Provision/EntityAttributes/UpdateEntityAttributes/D004_01_inc.robot index 22997bd0365bf2f1b4fce5eca8d40b24ae610d25..f92d7d7c5bf521d95e5229eec1a2e9cfc4b35a80 100644 --- a/TP/NGSI-LD/DistributedOperations/Provision/EntityAttributes/UpdateEntityAttributes/D004_01_inc.robot +++ b/TP/NGSI-LD/DistributedOperations/Provision/EntityAttributes/UpdateEntityAttributes/D004_01_inc.robot @@ -1,10 +1,11 @@ *** Settings *** Documentation Verify that, when one has an inclusive registration on a Context Broker with redirectionOps, one is able to update entities on a Context Source -Resource ${EXECDIR}/resources/ApiUtils/ContextSourceRegistration.resource -Resource ${EXECDIR}/resources/ApiUtils/ContextSourceDiscovery.resource -Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationConsumption.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextSourceDiscovery.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextSourceRegistration.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -13,9 +14,7 @@ Test Teardown Delete Created Entity And Registration *** Variables *** -${entity_id_prefix} urn:ngsi-ld:Vehicle: ${entity_payload_filename} vehicle-simple-attributes.jsonld -${registration_id_prefix} urn:ngsi-ld:Registration: ${registration_payload_file_path} csourceRegistrations/context-source-registration-vehicle-redirection-ops.jsonld ${fragment_filename} vehicle-brandname-fragment.jsonld @@ -39,12 +38,12 @@ D004_01_inc Query The Context Broker With Type *** Keywords *** Setup Entity On Remote And Registration - ${entity_id}= Generate Random Entity Id ${entity_id_prefix} + ${entity_id}= Generate Random Vehicle Entity Id Set Suite Variable ${entity_id} ${response}= Create Entity ${entity_payload_filename} ${entity_id} base_url=${remote_url} Check Response Status Code 201 ${response.status_code} - ${registration_id}= Generate Random Entity Id ${registration_id_prefix} + ${registration_id}= Generate Random CSR Id Set Suite Variable ${registration_id} ${registration_payload}= Prepare Context Source Registration From File ... ${registration_id} diff --git a/TP/NGSI-LD/jsonldContext/Consumption/ListContexts/052_06.robot b/TP/NGSI-LD/jsonldContext/Consumption/ListContexts/052_06.robot index 0c4e0db5c7ecb4b806e186fe188ecd1f31e64c60..6a865899200a136ec3f717861d2088fca7bfc3b8 100644 --- a/TP/NGSI-LD/jsonldContext/Consumption/ListContexts/052_06.robot +++ b/TP/NGSI-LD/jsonldContext/Consumption/ListContexts/052_06.robot @@ -1,9 +1,9 @@ *** Settings *** Documentation Check that one can list all the @context available in the broker with no previous add @context +Resource ${EXECDIR}/resources/ApiUtils/ContextInformationSubscription.resource Resource ${EXECDIR}/resources/ApiUtils/jsonldContext.resource Resource ${EXECDIR}/resources/AssertionUtils.resource -Resource ${EXECDIR}/resources/ApiUtils/ContextInformationSubscription.resource Test Setup Create initial ImplicitlyCreated @context Test Teardown Delete Initial @context Data diff --git a/TP/NGSI-LD/jsonldContext/Consumption/ListContexts/052_07.robot b/TP/NGSI-LD/jsonldContext/Consumption/ListContexts/052_07.robot index 61993134ca071cb2920f370c0c70f2c0de9425cb..da5ca903a566697cce2fd226d3207f8c7ab8a744 100644 --- a/TP/NGSI-LD/jsonldContext/Consumption/ListContexts/052_07.robot +++ b/TP/NGSI-LD/jsonldContext/Consumption/ListContexts/052_07.robot @@ -1,8 +1,9 @@ *** Settings *** Documentation Check that one can list all the cached @context entries -Resource ${EXECDIR}/resources/ApiUtils/jsonldContext.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/jsonldContext.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/HttpUtils.resource @@ -12,12 +13,11 @@ Test Template List @contexts with several previous created @context *** Variables *** -${entity_filename}= building-simple-attributes.json -${contextUri}= https://forge.etsi.org/rep/cim/ngsi-ld-test-suite/-/raw/develop/resources/jsonld-contexts/ngsi-ld-test-suite.jsonld -${reason_200}= OK -${reason_204}= No Content -${building_id_prefix}= urn:ngsi-ld:Building: -${content_type}= application/json +${entity_filename}= building-simple-attributes.json +${contextUri}= https://forge.etsi.org/rep/cim/ngsi-ld-test-suite/-/raw/develop/resources/jsonld-contexts/ngsi-ld-test-suite.jsonld +${reason_200}= OK +${reason_204}= No Content +${content_type}= application/json *** Test Cases *** DETAILS KIND @@ -31,7 +31,7 @@ ${content_type}= application/json *** Keywords *** Create Initial Cached @context from entity - ${entity_id}= Generate Random Entity Id ${building_id_prefix} + ${entity_id}= Generate Random Building Entity Id Set Test Variable ${entity_id} ${response}= Create Entity Selecting Content Type ... ${entity_filename} diff --git a/TP/NGSI-LD/jsonldContext/Consumption/ServeContext/053_04.robot b/TP/NGSI-LD/jsonldContext/Consumption/ServeContext/053_04.robot index ff52723b7a8eabae5765fd41493f613a55fc944d..3df4ab4344956b8376194eaac887f70518b48882 100644 --- a/TP/NGSI-LD/jsonldContext/Consumption/ServeContext/053_04.robot +++ b/TP/NGSI-LD/jsonldContext/Consumption/ServeContext/053_04.robot @@ -1,9 +1,9 @@ *** Settings *** Documentation Check that one can get an increase numberOfHits after creation of a Hosted @context and using it +Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource Resource ${EXECDIR}/resources/ApiUtils/jsonldContext.resource Resource ${EXECDIR}/resources/AssertionUtils.resource -Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource Resource ${EXECDIR}/resources/HttpUtils.resource Test Setup Create Initial @context condition from an external server diff --git a/TP/NGSI-LD/jsonldContext/Consumption/ServeContext/053_05.robot b/TP/NGSI-LD/jsonldContext/Consumption/ServeContext/053_05.robot index 45bf249cdc8e2cd7df1dd853da0d53f78d09575c..1105951ee4f1af47d79cf2c9227c6787b8235188 100644 --- a/TP/NGSI-LD/jsonldContext/Consumption/ServeContext/053_05.robot +++ b/TP/NGSI-LD/jsonldContext/Consumption/ServeContext/053_05.robot @@ -1,12 +1,12 @@ *** Settings *** Documentation Check that the context served by a context server is still in the broker after a ERROR_TYPE_LD_CONTEXT_NOT_AVAILABLE with details=true -Resource ${EXECDIR}/resources/ApiUtils/jsonldContext.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/jsonldContext.resource Resource ${EXECDIR}/resources/AssertionUtils.resource -Resource ${EXECDIR}/resources/JsonUtils.resource -Resource ${EXECDIR}/resources/HttpUtils.resource Resource ${EXECDIR}/resources/ContextServerUtils.resource +Resource ${EXECDIR}/resources/HttpUtils.resource +Resource ${EXECDIR}/resources/JsonUtils.resource Library Collections Library String Variables ${EXECDIR}/resources/variables.py diff --git a/TP/NGSI-LD/jsonldContext/Consumption/ServeContext/053_06.robot b/TP/NGSI-LD/jsonldContext/Consumption/ServeContext/053_06.robot index d93da46232afc6ac174208a8ea1b073393d303b1..1ab2148846a1dede7a69738e71c97a6f34555ecd 100644 --- a/TP/NGSI-LD/jsonldContext/Consumption/ServeContext/053_06.robot +++ b/TP/NGSI-LD/jsonldContext/Consumption/ServeContext/053_06.robot @@ -1,12 +1,13 @@ *** Settings *** Documentation Check that the numberOfHits is increased after using a Cached context -Resource ${EXECDIR}/resources/ApiUtils/jsonldContext.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/jsonldContext.resource Resource ${EXECDIR}/resources/AssertionUtils.resource -Resource ${EXECDIR}/resources/JsonUtils.resource -Resource ${EXECDIR}/resources/HttpUtils.resource Resource ${EXECDIR}/resources/ContextServerUtils.resource +Resource ${EXECDIR}/resources/HttpUtils.resource +Resource ${EXECDIR}/resources/JsonUtils.resource Library Collections Library String Variables ${EXECDIR}/resources/variables.py @@ -30,7 +31,7 @@ ${testing_id_prefix}= urn:ngsi-ld:Testing: [Documentation] Check that the numberOfHits is increased after using a Cached context [Tags] ctx-serve 5_13_4 since_v1.5.1 - ${second_existing_entity_id}= Generate Random Entity Id ${testing_id_prefix} + ${second_existing_entity_id}= Generate Random Id ${testing_id_prefix} Set Global Variable ${first_existing_entity_id} Create Entity selecting @context ${entityfile} ${uri} ${second_existing_entity_id} @@ -47,7 +48,7 @@ ${testing_id_prefix}= urn:ngsi-ld:Testing: Create Initial @context condition from an external server Start @context Local Server - ${first_existing_entity_id}= Generate Random Entity Id ${testing_id_prefix} + ${first_existing_entity_id}= Generate Random Id ${testing_id_prefix} Set Global Variable ${first_existing_entity_id} # ${uri}= Catenate http://${context_server_host}:${context_server_port}${uri} diff --git a/TP/NGSI-LD/jsonldContext/Consumption/ServeContext/053_08.robot b/TP/NGSI-LD/jsonldContext/Consumption/ServeContext/053_08.robot index 07555bc585ac87815c4abc545ff83dbb666eb30e..db51b16f0ae55a0d579df3ba3ddd50c47b82054e 100644 --- a/TP/NGSI-LD/jsonldContext/Consumption/ServeContext/053_08.robot +++ b/TP/NGSI-LD/jsonldContext/Consumption/ServeContext/053_08.robot @@ -1,8 +1,9 @@ *** Settings *** Documentation Check that the numberOfHits is increased after using a ImplicitlyCreated context -Resource ${EXECDIR}/resources/ApiUtils/ContextInformationSubscription.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/ContextInformationSubscription.resource Resource ${EXECDIR}/resources/ApiUtils/jsonldContext.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/JsonUtils.resource @@ -22,7 +23,7 @@ ${entityfile}= minimal-entity-using-@context.jsonld [Documentation] Check that the numberOfHits is increased after using a ImplicitlyCreated context [Tags] ctx-serve 5_13_4 since_v1.5.1 - ${entity_id}= Generate Random Entity Id ${testing_id_prefix} + ${entity_id}= Generate Random Id ${testing_id_prefix} Set Global Variable ${entity_id} Create Entity selecting @context ${entityfile} ${implicit_id_full} ${entity_id} diff --git a/TP/NGSI-LD/jsonldContext/Provision/AddContext/050_04.robot b/TP/NGSI-LD/jsonldContext/Provision/AddContext/050_04.robot index b6f2132c8aaeb836af62fd9e85ceaa2d3fe95db7..8de4524a3dff15bc1e7fa0eda4f55c0773c93d31 100644 --- a/TP/NGSI-LD/jsonldContext/Provision/AddContext/050_04.robot +++ b/TP/NGSI-LD/jsonldContext/Provision/AddContext/050_04.robot @@ -1,22 +1,22 @@ *** Settings *** Documentation Check that one can add a hosted @context with list of URIs and each of them are cached @coxtexts -Variables ${EXECDIR}/resources/variables.py -Resource ${EXECDIR}/resources/ApiUtils/jsonldContext.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/jsonldContext.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/HttpUtils.resource +Variables ${EXECDIR}/resources/variables.py Test Teardown Delete Initial @context *** Variables *** -${filename_list}= @context-cached-valid.json -${entity_filename}= building-simple-attributes.json -${reason_201}= Created -${reason_204}= No Content -${building_id_prefix}= urn:ngsi-ld:Building: -${content_type}= application/json +${filename_list}= @context-cached-valid.json +${entity_filename}= building-simple-attributes.json +${reason_201}= Created +${reason_204}= No Content +${content_type}= application/json *** Test Cases *** @@ -39,7 +39,7 @@ ${content_type}= application/json # Need to check that the kind value of the created context is "hosted" ${response_serve}= Serve a @context ${uri} true Check Response Kind set to ${response_serve.json()} Hosted - ${entity_id}= Generate Random Entity Id ${building_id_prefix} + ${entity_id}= Generate Random Building Entity Id Create Entity Selecting Content Type ... ${entity_filename} ... ${entity_id} diff --git a/TP/NGSI-LD/jsonldContext/Provision/DeleteContext/051_03.robot b/TP/NGSI-LD/jsonldContext/Provision/DeleteContext/051_03.robot index 1e7ab985ea71b2aab03a89eb60dd2d0434414191..5de3ac093df3f7dbe64dd1655865aedcb3257bcb 100644 --- a/TP/NGSI-LD/jsonldContext/Provision/DeleteContext/051_03.robot +++ b/TP/NGSI-LD/jsonldContext/Provision/DeleteContext/051_03.robot @@ -1,22 +1,22 @@ *** Settings *** Documentation Check that one can delete a previous created cached @context without reload param -Variables ${EXECDIR}/resources/variables.py -Resource ${EXECDIR}/resources/ApiUtils/jsonldContext.resource +Resource ${EXECDIR}/resources/ApiUtils/Common.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/jsonldContext.resource Resource ${EXECDIR}/resources/AssertionUtils.resource Resource ${EXECDIR}/resources/HttpUtils.resource +Variables ${EXECDIR}/resources/variables.py Test Setup Create Initial cached @context Test Teardown Delete Initial @context *** Variables *** -${filename}= @context-cached-one-valid.json -${entity_filename}= building-simple-attributes.json -${building_id_prefix}= urn:ngsi-ld:Building: -${content_type}= application/json -${reason_204}= No Content +${filename}= @context-cached-one-valid.json +${entity_filename}= building-simple-attributes.json +${content_type}= application/json +${reason_204}= No Content *** Test Cases *** @@ -40,7 +40,7 @@ Create Initial cached @context ${response}= Add a new @context ${filename} Check Response Status Code 201 ${response.status_code} ${uri}= Fetch Id From Response Location Header ${response.headers} - ${entity_id}= Generate Random Entity Id ${building_id_prefix} + ${entity_id}= Generate Random Building Entity Id ${response}= Create Entity Selecting Content Type ... ${entity_filename} ... ${entity_id} diff --git a/TP/NGSI-LD/jsonldContext/Provision/DeleteContext/051_05.robot b/TP/NGSI-LD/jsonldContext/Provision/DeleteContext/051_05.robot index c63d2aff0900b1b91db7b6097ffdc25c13d8dbc0..9cc8910b49e0dbd21247aafe254ece217a2b2973 100644 --- a/TP/NGSI-LD/jsonldContext/Provision/DeleteContext/051_05.robot +++ b/TP/NGSI-LD/jsonldContext/Provision/DeleteContext/051_05.robot @@ -1,12 +1,12 @@ *** Settings *** Documentation Check that one gets an error if one created an entity with a context (Cached context) and one tries to delete it with reload=true -Resource ${EXECDIR}/resources/ApiUtils/jsonldContext.resource Resource ${EXECDIR}/resources/ApiUtils/ContextInformationProvision.resource +Resource ${EXECDIR}/resources/ApiUtils/jsonldContext.resource Resource ${EXECDIR}/resources/AssertionUtils.resource -Resource ${EXECDIR}/resources/JsonUtils.resource -Resource ${EXECDIR}/resources/HttpUtils.resource Resource ${EXECDIR}/resources/ContextServerUtils.resource +Resource ${EXECDIR}/resources/HttpUtils.resource +Resource ${EXECDIR}/resources/JsonUtils.resource Library Collections Library String Variables ${EXECDIR}/resources/variables.py diff --git a/TP/NGSI-LD/jsonldContext/Provision/DeleteContext/051_06.robot b/TP/NGSI-LD/jsonldContext/Provision/DeleteContext/051_06.robot index 9545f14ae43dae15a6fcd2fd023dff7dbf45d942..f9df65d8b5c53fe61d6f051159172de59d742e17 100644 --- a/TP/NGSI-LD/jsonldContext/Provision/DeleteContext/051_06.robot +++ b/TP/NGSI-LD/jsonldContext/Provision/DeleteContext/051_06.robot @@ -1,9 +1,9 @@ *** Settings *** Documentation Delete a @context whose kind is ImplicitlyCreated without reload param +Resource ${EXECDIR}/resources/ApiUtils/ContextInformationSubscription.resource Resource ${EXECDIR}/resources/ApiUtils/jsonldContext.resource Resource ${EXECDIR}/resources/AssertionUtils.resource -Resource ${EXECDIR}/resources/ApiUtils/ContextInformationSubscription.resource Resource ${EXECDIR}/resources/HttpUtils.resource Test Setup Create initial ImplicitlyCreated @context diff --git a/TP/NGSI-LD/jsonldContext/Provision/DeleteContext/051_07.robot b/TP/NGSI-LD/jsonldContext/Provision/DeleteContext/051_07.robot index bef55e677e7df7d3d6ef918cd27c5bfdb87a5327..d5e72752aff2029b7ffed9758b9944db20054dca 100644 --- a/TP/NGSI-LD/jsonldContext/Provision/DeleteContext/051_07.robot +++ b/TP/NGSI-LD/jsonldContext/Provision/DeleteContext/051_07.robot @@ -1,9 +1,9 @@ *** Settings *** Documentation Check that one cannot delete a ImplicitlyCreated @context with reload set to true +Resource ${EXECDIR}/resources/ApiUtils/ContextInformationSubscription.resource Resource ${EXECDIR}/resources/ApiUtils/jsonldContext.resource Resource ${EXECDIR}/resources/AssertionUtils.resource -Resource ${EXECDIR}/resources/ApiUtils/ContextInformationSubscription.resource Test Setup Create initial ImplicitlyCreated @context Test Teardown Delete Initial @context Data diff --git a/resources/ApiUtils/Common.resource b/resources/ApiUtils/Common.resource index 0626613ef17efaf226cbe9b10220feb6ffa0abfb..2ce37ff882aabb608f0dbb9920fdf0f237d27499 100644 --- a/resources/ApiUtils/Common.resource +++ b/resources/ApiUtils/Common.resource @@ -1,11 +1,53 @@ +*** Settings *** +Library String + + *** Variables *** -${BUILDING_ID_PREFIX} urn:ngsi-ld:Building: -${BUS_ID_PREFIX} urn:ngsi-ld:Bus: -${CITY_ID_PREFIX} urn:ngsi-ld:City: -${VEHICLE_ID_PREFIX} urn:ngsi-ld:Vehicle: +${BUILDING_ID_PREFIX} urn:ngsi-ld:Building: +${BUS_ID_PREFIX} urn:ngsi-ld:Bus: +${CITY_ID_PREFIX} urn:ngsi-ld:City: +${PARKING_ID_PREFIX} urn:ngsi-ld:OffStreetParking: +${VEHICLE_ID_PREFIX} urn:ngsi-ld:Vehicle: + +${SUBSCRIPTION_ID_PREFIX}= urn:ngsi-ld:Subscription: + +${CSR_ID_PREFIX}= urn:ngsi-ld:ContextSourceRegistration: *** Keywords *** Build Context Link [Arguments] ${context} RETURN <${context}>; rel="http://www.w3.org/ns/json-ld#context"; type="application/ld+json" + +Generate Random Id + [Arguments] ${id_prefix} + + ${random_id}= Generate Random String 16 [NUMBERS] + ${entity_id}= Catenate ${id_prefix}${random_id} + RETURN ${entity_id} + +Generate Random Building Entity Id + ${entity_id}= Generate Random Id ${BUILDING_ID_PREFIX} + RETURN ${entity_id} + +Generate Bus Entity Id + [Arguments] ${id_suffix} + + ${entity_id}= Catenate ${BUS_ID_PREFIX}${id_suffix} + RETURN ${entity_id} + +Generate Random Parking Entity Id + ${entity_id}= Generate Random Id ${VEHICLE_ID_PREFIX} + RETURN ${entity_id} + +Generate Random Vehicle Entity Id + ${entity_id}= Generate Random Id ${PARKING_ID_PREFIX} + RETURN ${entity_id} + +Generate Random Subscription Id + ${entity_id}= Generate Random Id ${SUBSCRIPTION_ID_PREFIX} + RETURN ${entity_id} + +Generate Random CSR Id + ${entity_id}= Generate Random Id ${CSR_ID_PREFIX} + RETURN ${entity_id} diff --git a/resources/JsonUtils.resource b/resources/JsonUtils.resource index 10f4d2759e9f0dc2c652347eef2175f55244967e..3f3f332e67681aab60647e6efbc6413ce9341108 100644 --- a/resources/JsonUtils.resource +++ b/resources/JsonUtils.resource @@ -15,19 +15,17 @@ ${context_source_url}= http://${context_source_host}:${context_source_p Load Entity [Arguments] ${entity_file_name} ${entity_id} - ${entity_payload}= Load JSON From File ${EXECDIR}/data/entities/${entity_file_name} - ${entity}= Update Value To JSON ${entity_payload} $.id ${entity_id} + ${entity}= Load Test Sample entities/${entity_file_name} ${entity_id} RETURN ${entity} Load Test Sample [Arguments] ${test_sample_file_path} ${test_sample_id}=${EMPTY} - ${test_sample_payload}= Load JSON From File ${EXECDIR}/data/${test_sample_file_path} - ${test_sample}= Update Value To JSON ${test_sample_payload} $.id ${test_sample_id} - - IF '${test_sample_id}'=='' - Delete Object From JSON ${test_sample} $.id + ${test_sample}= Load JSON From File ${EXECDIR}/data/${test_sample_file_path} + IF '${test_sample_id}'!='' + ${test_sample}= Update Value To JSON ${test_sample} $.id ${test_sample_id} END + RETURN ${test_sample} Load Subscription Sample With Reachable Endpoint @@ -46,7 +44,7 @@ Load Subscription Sample With Reachable Endpoint Set Entity Id In Subscription [Arguments] ${subscription_payload} ${entity_id} ${dict}= Create Dictionary id=${entity_id} - ${subscription}= Add Object To JSON ${subscription_payload} $..entities[0] ${dict} + ${subscription}= Add Object To JSON ${subscription_payload} $.entities[0] ${dict} RETURN ${subscription} Load Context Source Registration Sample With Reachable Context Source @@ -60,23 +58,10 @@ Load Context Source Registration Sample With Reachable Context Source ... ${context_source_registration_id} ${context_source_registration}= Update Value To JSON ... ${context_source_registration_payload} - ... $..endpoint + ... $.endpoint ... ${context_source_endpoint_uri} RETURN ${context_source_registration} -Remove Entity Type - [Arguments] ${entity} - - ${invalid_entity}= Delete Object From JSON ${entity} $..type - RETURN ${invalid_entity} - -Generate Random Entity Id - [Arguments] ${id_prefix} - - ${random_id}= Generate Random String 16 [NUMBERS] - ${entity_id}= Catenate ${id_prefix}${random_id} - RETURN ${entity_id} - Create Batch Operation Result [Arguments] ${success} ${errors} diff --git a/resources/SubscriptionUtils.resource b/resources/SubscriptionUtils.resource index 84bba3cf9f30af816711a30e8ea2e6b25c9c7d5d..d38d55a19d61ca8f59e1ce4696230ec686312af6 100644 --- a/resources/SubscriptionUtils.resource +++ b/resources/SubscriptionUtils.resource @@ -12,7 +12,7 @@ Resource ${EXECDIR}/resources/JsonUtils.resource Create Subscription And Entity [Arguments] ${subscription_payload_file_path} ${building_filename} - ${entity_id}= Generate Random Entity Id ${BUILDING_ID_PREFIX} + ${entity_id}= Generate Random Building Entity Id Set Suite Variable ${entity_id} ${create_entity_response}= Create Entity Selecting Content Type ... ${building_filename} @@ -20,7 +20,7 @@ Create Subscription And Entity ... ${CONTENT_TYPE_LD_JSON} Check Response Status Code 201 ${create_entity_response.status_code} - ${subscription_id}= Generate Random Entity Id ${SUBSCRIPTION_ID_PREFIX} + ${subscription_id}= Generate Random Subscription Id Set Suite Variable ${subscription_id} ${subscription_payload}= Load Subscription Sample With Reachable Endpoint ... ${subscription_payload_file_path}