...Test objective: The objective is to test that POST method creates a subscription
...Pre-conditions: none
...Reference: Clause 8.5.3.3.1 - ETSI GS NFV-SOL 011 [6] v3.3.1
...Config ID: Config_prod_NFVO
...Applicability: none
...Post-Conditions: Subscription is created in the NFVO
POST subscriptions
Check HTTP Response Status Code Is201
Check HTTP Response Header ContainsLocation
Check HTTP Response Body Json Schema Issubscription
Check Resource URI
POST Create a new Subscription - DUPLICATION
[Documentation]Test ID: 9.3.4.1.2
...Test title: POST Create a new subscription - DUPLICATION
...Test objective: The objective is to test that POST method creates a duplicate subscription
...Pre-conditions: A subscription shall already exist
...Reference: Clause 8.5.3.3.1 - ETSI GS NFV-SOL 011 [6] v3.3.1
...Config ID: Config_prod_NFVO
...Applicability: Duplication supported by NFVO-C
...Post-Conditions: Duplicate subscription is created in the NFVO
Check Subscription Existence
POST subscriptions DUPLICATION
Check HTTP Response Status Code Is201
Check HTTP Response Header ContainsLocation
Check HTTP Response Body Json Schema Issubscription
POST Create a new Subscription - NO-DUPLICATION
[Documentation]Test ID: 9.3.4.1.3
...Test title: POST Create a new subscription - NO-DUPLICATION
...Test objective: The objective is to test that POST method cannot create a duplicate subscription
...Pre-conditions: A subscription shall already exist
...Reference: Clause 8.5.3.3.1 - ETSI GS NFV-SOL 011 [6] v3.3.1
...Config ID: Config_prod_NFVO
...Applicability: Duplication NOT supported by NFVO-C
...Post-Conditions: Duplicate subscription is not created in the NFVO
Check Subscription Existence
POST subscriptions NO DUPLICATION
Check HTTP Response Status Code Is303
Check HTTP Response Header ContainsLocation
GET Subscriptions
[Documentation]Test ID: 9.3.4.1.4
...Test title: GET Subscriptions
...Test objective: The objective is to test that GET method retrieves the list of existing subscriptions
...Pre-conditions: none
...Reference: Clause 8.5.3.3.2 - ETSI GS NFV-SOL 011 [6] v3.3.1
...Config ID: Config_prod_NFVO
...Applicability: none
...Post-Conditions: none
GET Subscriptions
Check HTTP Response Status Code Is200
Check HTTP Response Body Json Schema Issubscriptions
GET Subscription - Filter
[Documentation]Test ID: 9.3.4.1.5
...Test title: GET Subscription - Filter
...Test objective: The objective is GET the list of active subscriptions using a filter
...Pre-conditions: none
...Reference: Clause 8.5.3.3.2 - ETSI GS NFV-SOL 011 [6] v3.3.1
...Config ID: Config_prod_NFVO
...Applicability: none
...Post-Conditions: none
GET Subscriptions with filter
Check HTTP Response Status Code Is200
Check HTTP Response Body Json Schema Issubscriptions
GET subscriptions - Bad Request Invalid attribute-based filtering parameters
[Documentation]Test ID: 9.3.4.1.6
...Test title: GET subscriptions - Bad Request Invalid attribute-based filtering parameters
...Test objective: The objective is GET the list of active subscriptions using an invalid filter
...Pre-conditions: none
...Reference: Clause 8.5.3.3.2 - ETSI GS NFV-SOL 011 [6] v3.3.1
...Config ID: Config_prod_NFVO
...Applicability: none
...Post-Conditions: none
Get subscriptions - invalid filter
Check HTTP Response Status Code Is400
Check HTTP Response Body Json Schema IsProblemDetails
GET subscriptions - Bad Request Response too Big
[Documentation]Test ID: 9.3.4.1.7
...Test title: GET subscriptions - Bad Request Response too Big
...Test objective: The objective is test that the retrieval of active subscriptions list fails because response is too big, and perform the JSON schema validation of the failed operation HTTP response.
...Pre-conditions: none
...Reference: Clause 8.5.3.3.2 - ETSI GS NFV-SOL 011 [6] v3.3.1
...Config ID: Config_prod_NFVO
...Applicability: none
...Post-Conditions: none
GET Subscriptions
Check HTTP Response Status Code Is400
Check HTTP Response Body Json Schema IsProblemDetails
GET subscriptions with "all_fields" attribute selector
[Documentation]Test ID: 9.3.4.1.8
...Test title: GET subscriptions with "all_fields" attribute selector
...Test objective: The objective is to retrieve the list of active subscriptions with "all_fields" attribute selector
...Pre-conditions:
...Reference: Clause 8.5.3.3.2 - ETSI GS NFV-SOL 011 [6] v3.3.1
...Config ID: Config_prod_NFVO
...Applicability:
...Post-Conditions:
Get subscriptions with all_fields attribute selector
Check HTTP Response Status Code Is200
Check HTTP Response Body Json Schema Issubscriptions
GET subscriptions with "exclude_default" attribute selector
[Documentation]Test ID: 9.3.4.1.9
...Test title: GET subscriptions with "exclude_default" attribute selector
...Test objective: The objective is to retrieve the list of active subscriptions with "exclude_default"s attribute selector
...Pre-conditions:
...Reference: Clause 8.5.3.3.2 - ETSI GS NFV-SOL 011 [6] v3.3.1
...Config ID: Config_prod_NFVO
...Applicability:
...Post-Conditions:
Get subscriptions with exclude_default attribute selector
Check HTTP Response Status Code Is200
Check HTTP Response Body Json Schema Issubscriptions
GET subscriptions with "fields" attribute selector
[Documentation]Test ID: 9.3.4.1.10
...Test title: GET subscriptions with "fields" attribute selector
...Test objective: The objective is to retrieve the list of active subscriptions with "fields" attribute selector
...Pre-conditions:
...Reference: Clause 8.5.3.3.2 - ETSI GS NFV-SOL 011 [6] v3.3.1
...Config ID: Config_prod_NFVO
...Applicability:
...Post-Conditions:
Get subscriptions with fields attribute selector
Check HTTP Response Status Code Is200
Check HTTP Response Body Json Schema Issubscriptions
GET subscriptions with "exclude_fields" attribute selector
[Documentation]Test ID: 9.3.4.1.11
...Test title: GET subscriptions with "exclude_fields" attribute selector
...Test objective: The objective is to retrieve the list of active subscriptions with "exclude_fields" attribute selector
...Pre-conditions:
...Reference: Clause 8.5.3.3.2 - ETSI GS NFV-SOL 011 [6] v3.3.1
...Config ID: Config_prod_NFVO
...Applicability:
...Post-Conditions:
Get subscriptions with exclude_fields attribute selector
Check HTTP Response Status Code Is200
Check HTTP Response Body Json Schema Issubscriptions
GET Subscriptions as Paged Response
[Documentation]Test ID: 9.3.4.1.12
...Test title: GET Subscriptions as Paged Response
...Test objective: The objective is to test that GET methodretrieve the list of existing subscriptions as paged response.
...Pre-conditions: none
...Reference: Clause 8.5.3.3.2 - ETSI GS NFV-SOL 011 [6] v3.3.1
...Config ID: Config_prod_NFVO
...Applicability: none
...Post-Conditions: none
GET Subscriptions
Check HTTP Response Status Code Is200
Check LINK in Header
PUT subscriptions - Method not implemented
[Documentation]Test ID: 9.3.4.1.13
...Test title: PUT subscriptions - Method not implemented
...Test objective: The objective is to test that PUT method cannot modify a NS instance usage subscription
...Pre-conditions: none
...Reference: Clause 8.5.3.3.3 - ETSI GS NFV-SOL 011 [6] v3.3.1
...Config ID: Config_prod_NFVO
...Applicability: none
...Post-Conditions: none
PUT subscriptions
Check HTTP Response Status Code Is405
PATCH subscriptions - Method not implemented
[Documentation]Test ID: 9.3.4.1.14
...Test title: PATCH subscriptions - Method not implemented
...Test objective: The objective is to test that PUT method cannot modify a NS instance usage subscription
...Pre-conditions: none
...Reference: Clause 8.5.3.3.4 - ETSI GS NFV-SOL 011 [6] v3.3.1
...Config ID: Config_prod_NFVO
...Applicability: none
...Post-Conditions: none
PATCH subscriptions
Check HTTP Response Status Code Is405
DELETE subscriptions - Method not implemented
[Documentation]Test ID: 9.3.4.1.15
...Test title: DELETE subscriptions - Method not implemented
...Test objective: The objective is to test that DELETE method cannot delete a NS instance usage subscription
...Pre-conditions: none
...Reference: Clause 8.5.3.3.5 - ETSI GS NFV-SOL 011 [6] v3.3.1
...Config ID: Config_prod_NFVO
...Applicability: none
...Post-Conditions: Subscription is not deleted
DELETE subscriptions
Check HTTP Response Status Code Is405
*** Keywords ***
Check HTTP Response Status Code Is
[Arguments]${expected_status}
Should Be Equal As Strings${response['status']}${expected_status}
LogStatus code validated
Check HTTP Response Header Contains
[Arguments]${CONTENT_TYPE}
Should Contain${response['headers']}${CONTENT_TYPE}
LogHeader is present
Check Resource URI
${uri}=Get Value From Json${response['headers']}$..Location
Should Not Be Empty${uri}
LogURI is present
Check subscription existence
Set Headers{"Accept":"${ACCEPT}"}
Set Headers{"Content-Type": "${CONTENT_TYPE}"}
Run Keyword If${AUTH_USAGE}== 1Set Headers{"Authorization":"${AUTHORIZATION}"}
"description":"The definition of the general \"ProblemDetails\" data structure from IETF RFC 7807 [19] is reproduced inthis structure. Compared to the general framework defined in IETF RFC 7807 [19], the \"status\" and \"detail\" attributes are mandated to be included by the present document, to ensure that the response contains additional textual information about an error. IETF RFC 7807 [19] foresees extensibility of the \"ProblemDetails\" type. It is possible that particular APIs in the present document, or particular implementations, define extensions to define additional attributes that provide more information about the error. The description column only provides some explanation of the meaning to Facilitate understanding of the design. For a full description, see IETF RFC 7807 [19].\n",
"properties":{
"type":{
"type":"string",
"description":"A URI reference according to IETF RFC 3986 [5] that identifies the problem type. It is encouraged that the URI provides human-readable documentation for the problem (e.g. using HTML) when dereferenced. When this member is not present, its value is assumed to be \"about:blank\".\n",
"format":"URI"
},
"title":{
"type":"string",
"description":"A short, human-readable summary of the problem type. It should not change from occurrence to occurrence of the problem, except for purposes of localization. If type is given and other than \"about:blank\", this attribute shall also be provided. A short, human-readable summary of the problem type. It SHOULD NOT change from occurrence to occurrence of the problem, except for purposes of localization (e.g., using proactive content negotiation; see [RFC7231], Section 3.4).\n"
},
"status":{
"type":"integer",
"description":"The HTTP status code for this occurrence of the problem. The HTTP status code ([RFC7231], Section 6) generated by the origin server for this occurrence of the problem.\n"
},
"detail":{
"type":"string",
"description":"A human-readable explanation specific to this occurrence of the problem.\n"
},
"instance":{
"type":"string",
"description":"A URI reference that identifies the specific occurrence of the problem. It may yield further information if dereferenced.\n",
"description":"This type represents a subscription related to notifications about NS instance usage. It shall comply with the provisions defined in table 8.6.2.3-1.",
"type":"object",
"required":[
"id",
"callbackUri",
"_links"
],
"properties":{
"id":{
"description":"Identifier that identifies the subscription.",
"description":"Filter settings for this subscription, to define the subset of all notifications this subscription relates to. A particular notification is sent to the subscriber if the filter matches, or if there is no filter.",