Skip to content
Snippets Groups Projects
Commit aa04d0dc authored by Najam UI Hassan's avatar Najam UI Hassan
Browse files

missing and new test cases added for subscription

parent 3950867d
No related branches found
No related tags found
3 merge requests!199Merge "3.3.1 dev" into "release 3" master,!193Merge 2.7.1 dev into Master, for TST010ed271 publication,!117SOL002 VNF Indicator - Implementation of deltas between v2.7.1 and v2.6.1
......@@ -139,8 +139,47 @@ GET VNF Indicators Subscriptions - Bad Request Response too Big
... Post-Conditions: none
Get VNF Indicators Subscriptions
Check HTTP Response Status Code Is 400
Check HTTP Response Body Json Schema Is ProblemDetails
Check HTTP Response Body Json Schema Is ProblemDetails
POST Create a new Subscription - Unprocessable Entity
[Documentation] Test ID: 6.3.2.4.11
... Test title: POST Create a new Subscription - Unprocessable Entity
... Test objective: The objective is to test that content type of the payload body is supported and the payload body of a request contains syntactically correct data but the data cannot be processed.
... re-conditions: none
... Reference: Clause 8.4.5.3.1 - ETSI GS NFV-SOL 002 [2] v2.6.1
... Config ID: Config_prod_VE
... Applicability: none
... Post-Conditions: none
Send Post Request for VNF Indicator Subscription
Check HTTP Response Status Code Is 422
Check HTTP Response Body Json Schema Is ProblemDetails
Create new VNF indicator Subscription - DUPLICATION
[Documentation] Test ID: 6.3.2.4.12
... Test title: POST Create a new subscription - DUPLICATION
... Test objective: The POST method creates a new subscription even if an existing subscription to same content exist
... Pre-conditions: none
... Reference: Clause 8.4.5.3.1 - ETSI GS NFV-SOL 002 [2] v2.6.1
... Config ID: Config_prod_VE
... Applicability: SUT should support duplication of subscription creation
... Post-Conditions: in response header Location shall not be null
Post Create subscription - DUPLICATION
Check HTTP Response Status Code Is 201
Check HTTP Response Body Json Schema Is VnfIndicatorSubscription
Create new VNF indicator Subscription - NO-DUPLICATION
[Documentation] Test ID: 6.3.2.4.13
... Test title: POST Create a new subscription - NO-DUPLICATION
... Test objective: The POST method creates a new subscription even if an existing subscription to same content exist
... Pre-conditions: none
... Reference: Clause 8.4.5.3.1 - ETSI GS NFV-SOL 002 [2] v2.6.1
... Config ID: Config_prod_VE
... Applicability: SUT should not support duplication of subscription creation
... Post-Conditions: in response header Location shall not be null
Post Create subscription - NO-DUPLICATION
Check HTTP Response Status Code Is 303
Check Operation Occurrence Id
*** Keywords ***
Get VNF Indicators Subscriptions
Log Trying to get the list of subscriptions
......@@ -265,4 +304,30 @@ Check Notification Endpoint
Check LINK in Header
${linkURL}= Get Value From Json ${response['headers']} $..Link
Should Not Be Empty ${linkURL}
\ No newline at end of file
Should Not Be Empty ${linkURL}
Post Create subscription - DUPLICATION
Log Trying to create a subscription with an already created content
Pass Execution If ${VNFM_CHECKS_NOTIF_ENDPOINT} == 0 VNFM is not permitting duplication. Skipping the test
Set Headers {"Accept": "${ACCEPT_JSON}"}
Set Headers {"Content-Type": "${CONTENT_TYPE_JSON}"}
Run Keyword If ${AUTH_USAGE} == 1 Set Headers {"Authorization": "${AUTHORIZATION}"}
${body}= Get File jsons/subscriptions.json
Post ${apiRoot}/${apiName}/${apiVersion}/subscriptions ${body}
${outputResponse}= Output response
Set Global Variable ${response} ${outputResponse}
Post Create subscription - NO-DUPLICATION
Log Trying to create a subscription with an already created content
Pass Execution If ${VNFM_CHECKS_NOTIF_ENDPOINT} == 1 VNFM permits duplication. Skipping the test
Set Headers {"Accept": "${ACCEPT_JSON}"}
Set Headers {"Content-Type": "${CONTENT_TYPE_JSON}"}
Run Keyword If ${AUTH_USAGE} == 1 Set Headers {"Authorization": "${AUTHORIZATION}"}
${body}= Get File jsons/subscriptions.json
Post ${apiRoot}/${apiName}/${apiVersion}/subscriptions ${body}
${outputResponse}= Output response
Set Global Variable ${response} ${outputResponse}
Check Operation Occurrence Id
${vnfLcmOpOccId}= Get Value From Json ${response['headers']} $..Location
Should Not Be Empty ${vnfLcmOpOccId}
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