Commit 7e28b22d authored by Elian Kraja's avatar Elian Kraja
Browse files

Fix on issues: 66, 69, 73 (NXW endpoints), 74, 76, 78, 79, 80, 81, 85, 87, 88

parent d03f349e
*** Settings *** *** Settings ***
Resource environment/variables.txt Resource environment/variables.txt
Library REST ${EM-VNF_SCHEMA}://${EM-VNF_HOST}:${EM-VNF_PORT} Library REST ${EM-VNF_SCHEMA}://${EM-VNF_HOST}:${EM-VNF_PORT} ssl_verify=false
Library JSONLibrary Library JSONLibrary
Library JSONSchemaLibrary schemas/ Library JSONSchemaLibrary schemas/
Library OperatingSystem Library OperatingSystem
...@@ -121,14 +121,13 @@ Send VNF configuration ...@@ -121,14 +121,13 @@ Send VNF configuration
Run Keyword If ${AUTH_USAGE} == 1 Set Headers {"Authorization":"${AUTHORIZATION}"} Run Keyword If ${AUTH_USAGE} == 1 Set Headers {"Authorization":"${AUTHORIZATION}"}
${body}= Get File jsons/vnfConfigModifications.json ${body}= Get File jsons/vnfConfigModifications.json
Patch ${apiRoot}/${apiName}/${apiVersion}/configuration ${body} Patch ${apiRoot}/${apiName}/${apiVersion}/configuration ${body}
Set Suite Variable &{etag} ${response['headers']['ETag']}
${output}= Output response ${output}= Output response
Set Suite Variable ${response} ${output} Set Suite Variable ${response} ${output}
Check HTTP Response Status Code Is Check HTTP Response Status Code Is
[Arguments] ${expected_status} [Arguments] ${expected_status}
${status}= Convert To Integer ${expected_status} ${status}= Convert To Integer ${expected_status}
Should Be Equal ${response['status']} ${status} Should Be Equal As Strings ${response['status']} ${status}
Log Status code validated Log Status code validated
Check HTTP Response Header Contains Check HTTP Response Header Contains
...@@ -139,8 +138,8 @@ Check HTTP Response Header Contains ...@@ -139,8 +138,8 @@ Check HTTP Response Header Contains
Check HTTP Response Body Json Schema Is Check HTTP Response Body Json Schema Is
[Arguments] ${input} [Arguments] ${input}
Should Contain ${response['headers']['Content-Type']} application/json Should Contain ${response['headers']['Content-Type']} application/problem+json
${schema} = Catenate ${input} .schema.json ${schema}= Catenate SEPARATOR= ${input} .schema.json
Validate Json ${schema} ${response['body']} Validate Json ${schema} ${response['body']}
Log Json Schema Validation OK Log Json Schema Validation OK
...@@ -157,14 +156,14 @@ Check Postcondition VNF Is Configured ...@@ -157,14 +156,14 @@ Check Postcondition VNF Is Configured
Get VNF configuration Get VNF configuration
${input_file}= Get File jsons/vnfConfigModifications.json ${input_file}= Get File jsons/vnfConfigModifications.json
${input}= evaluate json.loads('''${input_file}''') json ${input}= evaluate json.loads('''${input_file}''') json
Should Be Equal ${response['body']} ${input} Should Be Equal As Strings ${response['body']} ${input}
Send Duplicated VNF configuration Send Duplicated VNF configuration
Depends On Test Send VNF configuration # If the previous test scceeded, it means that Etag has been modified Depends On Test Send VNF configuration # If the previous test scceeded, it means that Etag has been modified
log Trying to perform a PATCH. This method modifies an individual alarm resource log Trying to perform a PATCH. This method modifies an individual alarm resource
Set Headers {"Accept":"${ACCEPT}"} Set Headers {"Accept":"${ACCEPT}"}
Set Headers {"Content-Type": "${CONTENT_TYPE}"} Set Headers {"Content-Type": "${CONTENT_TYPE}"}
Set Headers {"If-Match": "${etag[0]}"} Set Headers {"If-Match": "${etag}"}
Run Keyword If ${AUTH_USAGE} == 1 Set Headers {"Authorization":"${AUTHORIZATION}"} Run Keyword If ${AUTH_USAGE} == 1 Set Headers {"Authorization":"${AUTHORIZATION}"}
${body}= Get File jsons/vnfConfigModifications.json ${body}= Get File jsons/vnfConfigModifications.json
Patch ${apiRoot}/${apiName}/${apiVersion}/configuration ${body} Patch ${apiRoot}/${apiName}/${apiVersion}/configuration ${body}
......
...@@ -11,13 +11,15 @@ ${EM-VNF_SCHEMA} https ...@@ -11,13 +11,15 @@ ${EM-VNF_SCHEMA} https
${ACCEPT} application/json ${ACCEPT} application/json
${AUTH_USAGE} 1 ${AUTH_USAGE} 1
${AUTHORIZATION} Bearer QWxhZGRpbjpvcGVuIHNlc2FtZQ== ${AUTHORIZATION} Bearer QWxhZGRpbjpvcGVuIHNlc2FtZQ==
${CONTENT_TYPE} application/json ${CONTENT_TYPE} application/json
${apiRoot} / ${apiRoot} /
${apiName} vnfconfig ${apiName} vnfconfig
${apiVersion} v1 ${apiVersion} v1
${WRONG_AUTHORIZATION} Bearer XXXXXWRONGXXXXX ${WRONG_AUTHORIZATION} Bearer XXXXXWRONGXXXXX
${alarm_filter} managedObjectId
${managedObjectId} 007c111c-38a1-42c0-a666-7475ecb1567c
${invalid_alarm_filter} badFilter
${alarmId} 6fc3539c-e602-4afa-8e13-962fb5a7d81d
...@@ -41,7 +41,7 @@ Create a new Subscription - DUPLICATION ...@@ -41,7 +41,7 @@ Create a new Subscription - DUPLICATION
... Applicability: the VNFM allows creating a subscription resource if another subscription resource with the same filter and callbackUri already exists ... Applicability: the VNFM allows creating a subscription resource if another subscription resource with the same filter and callbackUri already exists
... Post-Conditions: ... Post-Conditions:
Log Trying to create a subscription with an already created content Log Trying to create a subscription with an already created content
Pass Execution If ${VNFM_DUPLICATION} == 0 NVFO is not permitting duplication. Skipping the test Pass Execution If ${VNFM_ALLOWS_DUPLICATE_SUBS} == 0 NVFO is not permitting duplication. Skipping the test
Set Headers {"Accept": "${ACCEPT}"} Set Headers {"Accept": "${ACCEPT}"}
Set Headers {"Content-Type": "${CONTENT_TYPE}"} Set Headers {"Content-Type": "${CONTENT_TYPE}"}
Run Keyword If ${AUTH_USAGE} == 1 Set Headers {"Authorization": "${AUTHORIZATION}"} Run Keyword If ${AUTH_USAGE} == 1 Set Headers {"Authorization": "${AUTHORIZATION}"}
...@@ -65,7 +65,7 @@ Create a new Subscription - NO-DUPLICATION ...@@ -65,7 +65,7 @@ Create a new Subscription - NO-DUPLICATION
... Applicability: the VNFM decides to not create a duplicate subscription resource ... Applicability: the VNFM decides to not create a duplicate subscription resource
... Post-Conditions: ... Post-Conditions:
Log Trying to create a subscription with an already created content Log Trying to create a subscription with an already created content
Pass Execution If ${VNFM_DUPLICATION} == 1 VNFM permits duplication. Skipping the test Pass Execution If ${VNFM_ALLOWS_DUPLICATE_SUBS} == 1 VNFM permits duplication. Skipping the test
Set Headers {"Accept": "${ACCEPT}"} Set Headers {"Accept": "${ACCEPT}"}
Set Headers {"Content-Type": "${CONTENT_TYPE}"} Set Headers {"Content-Type": "${CONTENT_TYPE}"}
Run Keyword If ${AUTH_USAGE} == 1 Set Headers {"Authorization": "${AUTHORIZATION}"} Run Keyword If ${AUTH_USAGE} == 1 Set Headers {"Authorization": "${AUTHORIZATION}"}
......
...@@ -13,7 +13,7 @@ ${apiName} vnffm ...@@ -13,7 +13,7 @@ ${apiName} vnffm
${apiVersion} v1 ${apiVersion} v1
${CONTENT_TYPE} application/json ${CONTENT_TYPE} application/json
${VNFM_DUPLICATION} 0 ${VNFM_ALLOWS_DUPLICATE_SUBS} 0
${alarmId} 6fc3539c-e602-4afa-8e13-962fb5a7d81d ${alarmId} 6fc3539c-e602-4afa-8e13-962fb5a7d81d
${etags} a modified etag ${etags} a modified etag
......
...@@ -3,7 +3,7 @@ Library JSONSchemaLibrary schemas/ ...@@ -3,7 +3,7 @@ Library JSONSchemaLibrary schemas/
Resource environment/variables.txt # Generic Parameters Resource environment/variables.txt # Generic Parameters
Resource environment/individualSubscription.txt Resource environment/individualSubscription.txt
Library OperatingSystem Library OperatingSystem
Library REST ${EM-VNF_SCHEMA}://${EM-VNF_HOST}:${EM-VNF_PORT} Library REST ${EM-VNF_SCHEMA}://${EM-VNF_HOST}:${EM-VNF_PORT} ssl_verify=false
*** Test Cases *** *** Test Cases ***
GET Individual VNF Indicator Subscription GET Individual VNF Indicator Subscription
...@@ -32,32 +32,6 @@ GET Individual VNF Indicator Subscription with invalid resource identifier ...@@ -32,32 +32,6 @@ GET Individual VNF Indicator Subscription with invalid resource identifier
Check HTTP Response Status Code Is 404 Check HTTP Response Status Code Is 404
Check HTTP Response Body Json Schema Is ProblemDetails Check HTTP Response Body Json Schema Is ProblemDetails
DELETE Individual VNF Indicator Subscription
[Documentation] Test ID: 6.3.2.5.3
... Test title: Delete individual subscription to VNF performance indicators
... Test objective: The objective is to test the deletion of an individual VNF performance indicator subscription.
... Pre-conditions: A VNF instance is instantiated. At least one VNF indicator subscription is available in the VNF.
... Reference: section 8.4.6.3.5 - SOL002 v2.4.1
... Config ID: Config_prod_VE
... Applicability: The VNF supports the generation and maintenance of performance indicators
... Post-Conditions: The subscription to VNF performance indicators is deleted
Send Delete Request for Individual VNF Indicator Subscription
Check HTTP Response Status Code Is 204
Check Postcondition Individual VNF Indicator Subscription is Deleted
DELETE Individual VNF Indicator Subscription with invalid resource identifier
[Documentation] Test ID: 6.3.2.5.4
... Test title: Delete individual subscription to VNF performance indicators
... Test objective: The objective is to test that the deletion of an individual VNF performance indicator subscription fails when using an invalid resource identifier. The test also checks the JSON schema of the unsuccessful operation HTTP response.
... Pre-conditions: A VNF instance is instantiated. At least one VNF indicator subscription is available in the VNF.
... Reference: section 8.4.6.3.5 - SOL002 v2.4.1
... Config ID: Config_prod_VE
... Applicability: The VNF supports the generation and maintenance of performance indicators
... Post-Conditions: none
Send Delete Request for Individual VNF Indicator Subscription with invalid resource identifier
Check HTTP Response Status Code Is 404
Check HTTP Response Body Json Schema Is ProblemDetails
PUT Individual VNF Indicator Subscription - Method not implemented PUT Individual VNF Indicator Subscription - Method not implemented
[Documentation] Test ID 6.3.2.5.5 [Documentation] Test ID 6.3.2.5.5
... Test title: PUT individual VNF indicator subscription - Method not implemented ... Test title: PUT individual VNF indicator subscription - Method not implemented
...@@ -97,7 +71,33 @@ POST Individual VNF Indicator Subscription - Method not implemented ...@@ -97,7 +71,33 @@ POST Individual VNF Indicator Subscription - Method not implemented
Check HTTP Response Status Code Is 405 Check HTTP Response Status Code Is 405
Check Postcondition VNF individual subscription is not created Check Postcondition VNF individual subscription is not created
*** Keywords *** DELETE Individual VNF Indicator Subscription
[Documentation] Test ID: 6.3.2.5.3
... Test title: Delete individual subscription to VNF performance indicators
... Test objective: The objective is to test the deletion of an individual VNF performance indicator subscription.
... Pre-conditions: A VNF instance is instantiated. At least one VNF indicator subscription is available in the VNF.
... Reference: section 8.4.6.3.5 - SOL002 v2.4.1
... Config ID: Config_prod_VE
... Applicability: The VNF supports the generation and maintenance of performance indicators
... Post-Conditions: The subscription to VNF performance indicators is deleted
Send Delete Request for Individual VNF Indicator Subscription
Check HTTP Response Status Code Is 204
Check Postcondition Individual VNF Indicator Subscription is Deleted
DELETE Individual VNF Indicator Subscription with invalid resource identifier
[Documentation] Test ID: 6.3.2.5.4
... Test title: Delete individual subscription to VNF performance indicators
... Test objective: The objective is to test that the deletion of an individual VNF performance indicator subscription fails when using an invalid resource identifier. The test also checks the JSON schema of the unsuccessful operation HTTP response.
... Pre-conditions: A VNF instance is instantiated. At least one VNF indicator subscription is available in the VNF.
... Reference: section 8.4.6.3.5 - SOL002 v2.4.1
... Config ID: Config_prod_VE
... Applicability: The VNF supports the generation and maintenance of performance indicators
... Post-Conditions: none
Send Delete Request for Individual VNF Indicator Subscription with invalid resource identifier
Check HTTP Response Status Code Is 404
Check HTTP Response Body Json Schema Is ProblemDetails
*** Keywords ***
Get Individual VNF Indicator Subscription Get Individual VNF Indicator Subscription
Log Trying to get a given subscription identified by subscriptionId Log Trying to get a given subscription identified by subscriptionId
Set Headers {"Accept": "${ACCEPT_JSON}"} Set Headers {"Accept": "${ACCEPT_JSON}"}
...@@ -173,7 +173,7 @@ Check HTTP Response Header Contains ...@@ -173,7 +173,7 @@ Check HTTP Response Header Contains
Check HTTP Response Body Json Schema Is Check HTTP Response Body Json Schema Is
[Arguments] ${input} [Arguments] ${input}
Should Contain ${response['headers']['Content-Type']} application/json Should Contain ${response['headers']['Content-Type']} application/json
${schema} = Catenate ${input} .schema.json ${schema} = Catenate SEPARATOR= ${input} .schema.json
Validate Json ${schema} ${response['body']} Validate Json ${schema} ${response['body']}
Log Json Schema Validation OK Log Json Schema Validation OK
...@@ -186,8 +186,7 @@ Check Postcondition VNF individual subscription Unmodified (Implicit) ...@@ -186,8 +186,7 @@ Check Postcondition VNF individual subscription Unmodified (Implicit)
Log Check Postcondition subscription is not modified Log Check Postcondition subscription is not modified
GET Individual VNF Indicator Subscription GET Individual VNF Indicator Subscription
Log Check Response matches original subscription Log Check Response matches original subscription
${subscription}= evaluate json.loads('''${response['body']}''') json Should Be Equal As Strings ${origResponse['body']['callbackUri']} ${response['body']['callbackUri']}
Should Be Equal ${origResponse['body']['callbackUri']} ${subscription.callbackUri}
Check Postcondition VNF individual subscription is not created Check Postcondition VNF individual subscription is not created
Log Check Postcondition subscription is not created Log Check Postcondition subscription is not created
......
...@@ -146,20 +146,20 @@ Check HTTP Response Header Contains ...@@ -146,20 +146,20 @@ Check HTTP Response Header Contains
Check HTTP Response Body Json Schema Is Check HTTP Response Body Json Schema Is
[Arguments] ${input} [Arguments] ${input}
Should Contain ${response['headers']['Content-Type']} application/json Should Contain ${response['headers']['Content-Type']} application/json
${schema} = Catenate ${input} .schema.json ${schema} = Catenate SEPARATOR= ${input} .schema.json
Validate Json ${schema} ${response['body']} Validate Json ${schema} ${response['body']}
Log Json Schema Validation OK Log Json Schema Validation OK
Check HTTP Response Body Includes Requested Indicator ID Check HTTP Response Body Includes Requested Indicator ID
Log Check Response includes propoer VNF instance and Indicator identifiers Log Check Response includes propoer VNF instance and Indicator identifiers
Should Be Equal ${response['body']['id']} ${indicatorId} Should Be Equal As Strings ${response['body']['id']} ${indicatorId}
Check HTTP Response Body Includes Requested VNF Instance ID Check HTTP Response Body Includes Requested VNF Instance ID
Log Check Response includes propoer VNF instance and Indicator identifiers Log Check Response includes propoer VNF instance and Indicator identifiers
Should Be Equal ${response['body']['vnfInstanceId']} ${vnfInstanceId} Should Be Equal As Strings ${response['body']['vnfInstanceId']} ${vnfInstanceId}
Check Postcondition Indicator for VNF instance Exist Check Postcondition Indicator for VNF instance Exist
Log Check Response includes VNF Indicator Log Check Response includes VNF Indicator
Get Individual Indicator for a VNF instance Get Individual Indicator for a VNF instance
Should Be Equal ${response['body']['vnfInstanceId']} ${vnfInstanceId} Should Be Equal As Strings ${response['body']['vnfInstanceId']} ${vnfInstanceId}
Should Be Equal ${response['body']['id']} ${indicatorId} Should Be Equal As Strings ${response['body']['id']} ${indicatorId}
...@@ -198,7 +198,7 @@ Check HTTP Response Header Contains ...@@ -198,7 +198,7 @@ Check HTTP Response Header Contains
Check HTTP Response Body Json Schema Is Check HTTP Response Body Json Schema Is
[Arguments] ${input} [Arguments] ${input}
Should Contain ${response['headers']['Content-Type']} application/json Should Contain ${response['headers']['Content-Type']} application/json
${schema} = Catenate ${input} .schema.json ${schema} = Catenate SEPARATOR= ${input} .schema.json
Validate Json ${schema} ${response['body']} Validate Json ${schema} ${response['body']}
Log Json Schema Validation OK Log Json Schema Validation OK
...@@ -206,7 +206,7 @@ Check HTTP Response Body Matches the Subscription ...@@ -206,7 +206,7 @@ Check HTTP Response Body Matches the Subscription
Log Check Response matches subscription Log Check Response matches subscription
${body}= Get File jsons/subscriptions.json ${body}= Get File jsons/subscriptions.json
${subscription}= evaluate json.loads('''${body}''') json ${subscription}= evaluate json.loads('''${body}''') json
Should Be Equal ${response['body']['callbackUri']} ${subscription.callbackUri} Should Be Equal ${response['body']['callbackUri']} ${subscription['callbackUri']}
Check Postcondition VNF Indicator Subscription Is Set Check Postcondition VNF Indicator Subscription Is Set
Log Check Postcondition subscription exist Log Check Postcondition subscription exist
......
...@@ -4,7 +4,7 @@ Library JSONSchemaLibrary schemas/ ...@@ -4,7 +4,7 @@ Library JSONSchemaLibrary schemas/
Resource environment/variables.txt # Generic Parameters Resource environment/variables.txt # Generic Parameters
Library JSONLibrary Library JSONLibrary
Resource environment/vnfIndicators.txt Resource environment/vnfIndicators.txt
Library REST ${EM-VNF_SCHEMA}://${EM-VNF_HOST}:${EM-VNF_PORT} Library REST ${EM-VNF_SCHEMA}://${EM-VNF_HOST}:${EM-VNF_PORT} ssl_verify=false
*** Test Cases *** *** Test Cases ***
Get all VNF Indicators Get all VNF Indicators
...@@ -153,8 +153,6 @@ Get all VNF indicators ...@@ -153,8 +153,6 @@ Get all VNF indicators
Get ${apiRoot}/${apiName}/${apiVersion}/indicators Get ${apiRoot}/${apiName}/${apiVersion}/indicators
${output}= Output response ${output}= Output response
Set Suite Variable ${response} ${output} Set Suite Variable ${response} ${output}
${body}= evaluate json.loads('''${response.body}''') json
Set Suite Variable @{vnfIndicators} ${body}
Get VNF indicators with filter Get VNF indicators with filter
Log The GET method queries multiple VNF indicators using Attribute-based filtering parameters Log The GET method queries multiple VNF indicators using Attribute-based filtering parameters
...@@ -208,7 +206,7 @@ Get all VNF indicators with invalid resource endpoint ...@@ -208,7 +206,7 @@ Get all VNF indicators with invalid resource endpoint
Set Headers {"Accept": "${ACCEPT_JSON}"} Set Headers {"Accept": "${ACCEPT_JSON}"}
Run Keyword If ${AUTH_USAGE} == 1 Set Headers {"Authorization": "${AUTHORIZATION}"} Run Keyword If ${AUTH_USAGE} == 1 Set Headers {"Authorization": "${AUTHORIZATION}"}
Log Execute Query and validate response Log Execute Query and validate response
Get ${apiRoot}/${apiName}/${apiVersion}/indicators Get ${apiRoot}/${apiName}/${apiVersion}/indicator
${output}= Output response ${output}= Output response
Set Suite Variable ${response} ${output} Set Suite Variable ${response} ${output}
...@@ -249,6 +247,8 @@ Check HTTP Response Status Code Is ...@@ -249,6 +247,8 @@ Check HTTP Response Status Code Is
${status}= Convert To Integer ${expected_status} ${status}= Convert To Integer ${expected_status}
Should Be Equal ${response['status']} ${status} Should Be Equal ${response['status']} ${status}
Log Status code validated Log Status code validated
Run Keyword If ${status} == 401
... Check HTTP Response Header Contains "WWW-Authenticate"
Check HTTP Response Header Contains Check HTTP Response Header Contains
[Arguments] ${CONTENT_TYPE} [Arguments] ${CONTENT_TYPE}
...@@ -258,11 +258,12 @@ Check HTTP Response Header Contains ...@@ -258,11 +258,12 @@ Check HTTP Response Header Contains
Check HTTP Response Body Json Schema Is Check HTTP Response Body Json Schema Is
[Arguments] ${schema} [Arguments] ${schema}
Should Contain ${response['headers']['Content-Type']} application/json Should Contain ${response['headers']['Content-Type']} application/json
Validate Json ${schema} ${response['body']} ${jsonSchema}= Catenate SEPARATOR= ${schema} .schema.json
Validate Json ${jsonSchema} ${response['body']}
Log Json Schema Validation OK Log Json Schema Validation OK
Check Postcondition VNF Indicators Exist Check Postcondition VNF Indicators Exist
Log Check Postcondition indicators exist Log Check Postcondition indicators exist
Get all VNF indicators Get all VNF indicators
Check HTTP Response Status Code Is 200 Check HTTP Response Status Code Is 200
......
...@@ -190,7 +190,7 @@ Check HTTP Response Header Contains ...@@ -190,7 +190,7 @@ Check HTTP Response Header Contains
Check HTTP Response Body Json Schema Is Check HTTP Response Body Json Schema Is
[Arguments] ${input} [Arguments] ${input}
Should Contain ${response['headers']['Content-Type']} application/json Should Contain ${response['headers']['Content-Type']} application/json
${schema} = Catenate ${input} .schema.json ${schema} = Catenate SEPARATOR= ${input} .schema.json
Validate Json ${schema} ${response['body']} Validate Json ${schema} ${response['body']}
Log Json Schema Validation OK Log Json Schema Validation OK
......
...@@ -2,4 +2,4 @@ ...@@ -2,4 +2,4 @@
${POS_FIELDS} name=vnfIndicator&vnfInstanceId=80b0deba-c398-445b-bef0-ac0fe733e3d0 ${POS_FIELDS} name=vnfIndicator&vnfInstanceId=80b0deba-c398-445b-bef0-ac0fe733e3d0
${NEG_FIELDS} wrongName=wrongValue ${NEG_FIELDS} wrongName=wrongValue
${response} some_response_object ${response} some_response_object
${vnfIndicators} original_vnf_indicators ${vnfIndicators}
...@@ -200,7 +200,7 @@ Check HTTP Response Header Contains ...@@ -200,7 +200,7 @@ Check HTTP Response Header Contains
Check HTTP Response Body Json Schema Is Check HTTP Response Body Json Schema Is
[Arguments] ${input} [Arguments] ${input}
Should Contain ${response['headers']['Content-Type']} application/json Should Contain ${response['headers']['Content-Type']} application/json
${schema} = Catenate ${input} .schema.json ${schema} = Catenate SEPARATOR= ${input} .schema.json
Validate Json ${schema} ${response['body']} Validate Json ${schema} ${response['body']}
Log Json Schema Validation OK Log Json Schema Validation OK
...@@ -168,7 +168,7 @@ Check HTTP Response Header Contains ...@@ -168,7 +168,7 @@ Check HTTP Response Header Contains
Check HTTP Response Body Json Schema Is Check HTTP Response Body Json Schema Is
[Arguments] ${input} [Arguments] ${input}
Should Contain ${response['headers']['Content-Type']} application/json Should Contain ${response['headers']['Content-Type']} application/json
${schema} = Catenate ${input} .schema.json ${schema} = Catenate SEPARATOR= ${input} .schema.json
Validate Json ${schema} ${response['body']} Validate Json ${schema} ${response['body']}
Log Json Schema Validation OK Log Json Schema Validation OK
...@@ -198,7 +198,7 @@ Check HTTP Response Header Contains ...@@ -198,7 +198,7 @@ Check HTTP Response Header Contains
Check HTTP Response Body Json Schema Is Check HTTP Response Body Json Schema Is
[Arguments] ${input} [Arguments] ${input}
Should Contain ${response['headers']['Content-Type']} application/json Should Contain ${response['headers']['Content-Type']} application/json
${schema} = Catenate ${input} .schema.json ${schema} = Catenate SEPARATOR= ${input} .schema.json
Validate Json ${schema} ${response['body']} Validate Json ${schema} ${response['body']}
Log Json Schema Validation OK Log Json Schema Validation OK
......
...@@ -295,7 +295,7 @@ Check HTTP Response Body Matches exclude_fields selector ...@@ -295,7 +295,7 @@ Check HTTP Response Body Matches exclude_fields selector
Check HTTP Response Body Matches fields selector Check HTTP Response Body Matches fields selector
Log Trying to validate criteria schema Log Trying to validate criteria schema
${criteria}= Get Value From Json ${response['body']} $..criteria ${criteria}= Get Value From Json ${response['body']} $..criteria
Validate Json criteria.schema.json ${criteria[0]} Validate Json criteria.schema.json ${criteria}
Log Validation for criteria schema OK Log Validation for criteria schema OK
Log Trying to validate criteria schema Log Trying to validate criteria schema
${reports}= Get Value From Json ${response['body']} $..reports ${reports}= Get Value From Json ${response['body']} $..reports
...@@ -311,7 +311,7 @@ Check HTTP Response Body Matches exclude_default selector ...@@ -311,7 +311,7 @@ Check HTTP Response Body Matches exclude_default selector
Check HTTP Response Body Matches all_fields selector Check HTTP Response Body Matches all_fields selector
Log Trying to validate criteria schema Log Trying to validate criteria schema
${criteria}= Get Value From Json ${response['body']} $..criteria ${criteria}= Get Value From Json ${response['body']} $..criteria
Validate Json criteria.schema.json ${criteria[0]} Validate Json criteria.schema.json ${criteria}
Log Validation for criteria schema OK Log Validation for criteria schema OK
Log Trying to validate criteria schema Log Trying to validate criteria schema
${reports}= Get Value From Json ${response['body']} $..reports ${reports}= Get Value From Json ${response['body']} $..reports
...@@ -350,7 +350,7 @@ Check HTTP Response Header Contains ...@@ -350,7 +350,7 @@ Check HTTP Response Header Contains
Check HTTP Response Body Json Schema Is Check HTTP Response Body Json Schema Is
[Arguments] ${input} [Arguments] ${input}
Should Contain ${response['headers']['Content-Type']} application/json Should Contain ${response['headers']['Content-Type']} application/json
${schema} = Catenate ${input} .schema.json ${schema} = Catenate SEPARATOR= ${input} .schema.json
Validate Json ${schema} ${response['body']} Validate Json ${schema} ${response['body']}
Log Json Schema Validation OK Log Json Schema Validation OK
...@@ -211,7 +211,7 @@ Check HTTP Response Header Contains ...@@ -211,7 +211,7 @@ Check HTTP Response Header Contains
Check HTTP Response Body Json Schema Is Check HTTP Response Body Json Schema Is
[Arguments] ${input} [Arguments] ${input}
Should Contain ${response['headers']['Content-Type']} application/json Should Contain ${response['headers']['Content-Type']} application/json
${schema} = Catenate ${input} .schema.json ${schema} = Catenate SEPARATOR= ${input} .schema.json
Validate Json ${schema} ${response['body']} Validate Json ${schema} ${response['body']}
Log Json Schema Validation OK Log Json Schema Validation OK
......
...@@ -239,8 +239,8 @@ Check Postcondition VNF Performance Subscription is Unmodified (Implicit) ...@@ -239,8 +239,8 @@ Check Postcondition VNF Performance Subscription is Unmodified (Implicit)
GET individual VNF Performance Subscription GET individual VNF Performance Subscription
Log Check Response matches original VNF Threshold Log Check Response matches original VNF Threshold
${subscription}= evaluate json.loads('''${response['body']}''') json ${subscription}= evaluate json.loads('''${response['body']}''') json
Should Be Equal ${origResponse['body']['id']} ${subscription.id} Should Be Equal As Strings ${origResponse['body']['id']} ${subscription.id}
Should Be Equal ${origResponse['body']['callbackUri']} ${subscription.callbackUri} Should Be Equal As Strings ${origResponse['body']['callbackUri']} ${subscription.callbackUri}
Check Postcondition VNF Performance Subscription is not Created Check Postcondition VNF Performance Subscription is not Created
Log Trying to get a new subscription Log Trying to get a new subscription
...@@ -258,12 +258,12 @@ Check Postcondition VNF Performance Subscription is Deleted ...@@ -258,12 +258,12 @@ Check Postcondition VNF Performance Subscription is Deleted
Check HTTP Response Body Subscription Identifier matches the requested Subscription Check HTTP Response Body Subscription Identifier matches the requested Subscription
Log Trying to check response ID Log Trying to check response ID
Should Be Equal ${response['body']['id']} ${subscriptionId} Should Be Equal As Strings ${response['body']['id']} ${subscriptionId}
Log Subscription identifier as expected Log Subscription identifier as expected
Check HTTP Response Status Code Is Check HTTP Response Status Code Is
[Arguments] ${expected_status} [Arguments] ${expected_status}
Should Be Equal ${response['status']} ${expected_status} Should Be Equal As Strings ${response['status']} ${expected_status}
Log Status code validated Log Status code validated
...@@ -271,7 +271,7 @@ Check HTTP Response Status Code Is ...@@ -271,7 +271,7 @@ Check HTTP Response Status Code Is
Check HTTP Response Body Json Schema Is Check HTTP Response Body Json Schema Is
[Arguments] ${input} [Arguments] ${input}
Should Contain ${response['headers']['Content-Type']} application/json Should Contain ${response['headers']['Content-Type']} application/json
${schema} = Catenate ${input} .schema.json