Skip to content
Snippets Groups Projects
Commit 40eb3a88 authored by Giacomo Bernini's avatar Giacomo Bernini
Browse files

fixes to NSInstanceUsageNotification-API

parent 6c270925
No related branches found
No related tags found
2 merge requests!199Merge "3.3.1 dev" into "release 3" master,!1733.3.1 dev sol011 final
......@@ -67,6 +67,7 @@ DELETE an individual subscription
... Post-Conditions: The NS instance usage notification subscription is not available anymore on NFVO
DELETE Individual Subscription
Check HTTP Response Status Code Is 204
Check Postcondition Individual Subscription is Deleted
GET Information about an individual subscription - NOT FOUND
[Documentation] Test ID: 9.3.4.2.6
......
......@@ -225,3 +225,38 @@ Get subscriptions with exclude_default and fields attribute selector
GET ${apiRoot}/${apiName}/${apiVersion}/subscriptions?fields=${fields}&exclude_default
${output}= Output response
Set Suite Variable ${response} ${output}
Check Postcondition Individual Subscription is Deleted
Log Check Postcondition Subscription is deleted
GET individual Subscription
Check HTTP Response Status Code Is 404
Check Postcondition Subscription Is Set
Log Check Postcondition subscription exist
Log Trying to get the subscription
Set Headers {"Accept": "${ACCEPT_JSON}"}
Run Keyword If ${AUTH_USAGE} == 1 Set Headers {"Authorization": "${AUTHORIZATION}"}
GET ${apiRoot}/${apiName}/${apiVersion}/subscriptions/${response['body']['id']}
${output}= Output response
Set Suite Variable ${response} ${output}
Check HTTP Response Status Code Is 200
Check Postcondition Subscription Resource Returned in Location Header Is Available
Log Going to check postcondition
Run Keyword If ${AUTH_USAGE} == 1 Set Headers {"Authorization": "${AUTHORIZATION}"}
GET ${response['headers']['Location']}
Integer response status 200
Log Received a 200 OK as expected
${contentType}= Output response headers Content-Type
Should Contain ${contentType} application/json
${result}= Output response body
Validate Json NsdmSubscription.schema.json ${result}
Log Validated NsdmSubscription schema
${body}= Get File jsons/subscriptions.json
${subscription}= evaluate json.loads('''${body}''') json
Should Be Equal ${result['callbackUri']} ${subscription['callbackUri']}
Log Validated Issued subscription is same as original
Check Postcondition Subscriptions Exist
Log Checking that subscriptions exists
Get Subscriptions
\ No newline at end of file
......@@ -21,6 +21,7 @@ POST Create a new subscription
Check HTTP Response Header Contains Location
Check HTTP Response Body Json Schema Is subscription
Check HTTP Response Header Contains Resource URI
Check Postcondition Subscription Is Set
POST Create a new Subscription - DUPLICATION
[Documentation] Test ID: 9.3.4.1.2
......@@ -36,6 +37,7 @@ POST Create a new Subscription - DUPLICATION
Check HTTP Response Status Code Is 201
Check HTTP Response Header Contains Location
Check HTTP Response Body Json Schema Is subscription
Check Postcondition Subscription Resource Returned in Location Header Is Available
POST Create a new Subscription - NO-DUPLICATION
[Documentation] Test ID: 9.3.4.1.3
......@@ -50,6 +52,7 @@ POST Create a new Subscription - NO-DUPLICATION
Check Subscription Existence
Check HTTP Response Status Code Is 303
Check HTTP Response Header Contains Location
Check Postcondition Subscription Is Set
GET Subscriptions
[Documentation] Test ID: 9.3.4.1.4
......@@ -203,6 +206,7 @@ DELETE subscriptions - Method not implemented
... Post-Conditions: Subscriptions are not deleted
DELETE subscriptions
Check HTTP Response Status Code Is 405
Check Postcondition Subscriptions Exist
GET subscriptions with "exclude_default" and "fields" attribute selector
[Documentation] Test ID: 9.3.4.1.16
......@@ -211,8 +215,8 @@ GET subscriptions with "exclude_default" and "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:
... Applicability: none
... Post-Conditions: none
Get subscriptions with exclude_default and fields attribute selector
Check HTTP Response Status Code Is 200
Check HTTP Response Body Json Schema Is subscriptions
\ No newline at end of file
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment