diff --git a/SOL002/VNFFaultManagement-API/Alarms.robot b/SOL002/VNFFaultManagement-API/Alarms.robot index 2245d3b04607d04714ee6c9da9340898d25a0148..d04e45bef1bd26c9159559c6d62d3d3668652bb9 100644 --- a/SOL002/VNFFaultManagement-API/Alarms.robot +++ b/SOL002/VNFFaultManagement-API/Alarms.robot @@ -5,6 +5,7 @@ Library REST ${VNFM_SCHEMA}://${VNFM_HOST}:${VNFM_PORT} Library JSONLibrary Library JSONSchemaLibrary schemas/ Library OperatingSystem +Library Collections *** Test Cases *** POST Alarms - Method not implemented @@ -12,7 +13,7 @@ POST Alarms - Method not implemented ... Test title: POST Alarms - Method not implemented ... Test objective: The objective is to test that the method is not implemented ... Pre-conditions: - ... Reference: clause 7.4.2.3.1 - ETSI GS NFV-SOL 002 [2] v2.4.1 + ... Reference: clause 7.4.2.3.1 - ETSI GS NFV-SOL 002 [2] v2.6.1 ... Config ID: Config_prod_VNFM ... Applicability: ... Post-Conditions: none @@ -24,7 +25,7 @@ GET information about multiple alarms ... Test title: GET information about multiple alarms ... Test objective: The objective is to retrieve information about the alarm list ... Pre-conditions: - ... Reference: clause 7.4.2.3.2 - ETSI GS NFV-SOL 002 [2] v2.4.1 + ... Reference: clause 7.4.2.3.2 - ETSI GS NFV-SOL 002 [2] v2.6.1 ... Config ID: Config_prod_VNFM ... Applicability: ... Post-Conditions: @@ -37,7 +38,7 @@ GET information about multiple alarms with attribute-based filter ... Test title: GET information about multiple alarms with attribute-based filter ... Test objective: The objective is to retrieve information about the alarm list ... Pre-conditions: - ... Reference: clause 7.4.2.3.2 - ETSI GS NFV-SOL 002 [2] v2.4.1 + ... Reference: clause 7.4.2.3.3 - ETSI GS NFV-SOL 002 [2] v2.6.1 ... Config ID: Config_prod_VNFM ... Applicability: ... Post-Conditions: @@ -50,20 +51,73 @@ GET information about multiple alarms with invalid attribute-based filter ... Test title: GET information about multiple alarms with invalid attribute-based filter ... Test objective: The objective is to retrieve information about the alarm list ... Pre-conditions: - ... Reference: clause 7.4.2.3.2 - ETSI GS NFV-SOL 002 [2] v2.4.1 + ... Reference: clause 7.4.2.3.4 - ETSI GS NFV-SOL 002 [2] v2.6.1 ... Config ID: Config_prod_VNFM ... Applicability: ... Post-Conditions: GET Alarms Task with invalid filter Check HTTP Response Status Code Is 400 Check HTTP Response Body Json Schema Is ProblemDetails + +GET information about multiple alarms with "all_fields" attribute selector + [Documentation] Test ID: 6.3.4.1.5 + ... Test title: GET information about multiple alarms with "all_fields" attribute selector + ... Test objective: The objective is to retrieve information about the alarm list + ... Pre-conditions: + ... Reference: clause 7.4.2.3.3 - ETSI GS NFV-SOL 002 [2] v2.6.1 + ... Config ID: Config_prod_VNFM + ... Applicability: + ... Post-Conditions: + GET Alarms Task with all_fields attribute selector + Check HTTP Response Status Code Is 200 + Check HTTP Response Body Json Schema Is alarms + +GET information about multiple alarms with exclude_default attribute selector + [Documentation] Test ID: 6.3.4.1.6 + ... Test title: GET information about multiple alarms with "exclude_default" attribute selector + ... Test objective: The objective is to retrieve information about the alarm list + ... Pre-conditions: + ... Reference: clause 7.4.2.3.3 - ETSI GS NFV-SOL 002 [2] v2.6.1 + ... Config ID: Config_prod_VNFM + ... Applicability: + ... Post-Conditions: + GET Alarms Task with exclude_default attribute selector + Check HTTP Response Status Code Is 200 + Check HTTP Response Body Json Schema Is alarms + + +GET information about multiple alarms with fields attribute selector + [Documentation] Test ID: 6.3.4.1.7 + ... Test title: GET information about multiple alarms with fields attribute selector + ... Test objective: The objective is to retrieve information about the alarm list + ... Pre-conditions: + ... Reference: clause 7.4.2.3.3 - ETSI GS NFV-SOL 002 [2] v2.6.1 + ... Config ID: Config_prod_VNFM + ... Applicability: + ... Post-Conditions: + GET Alarms Task with fields attribute selector + Check HTTP Response Status Code Is 200 + Check HTTP Response Body Json Schema Is alarms + +GET information about multiple alarms with "exclude_fields" attribute selector + [Documentation] Test ID: 6.3.4.1.8 + ... Test title: GET information about multiple alarms with "exclude_fields" attribute selector + ... Test objective: The objective is to retrieve information about the alarm list + ... Pre-conditions: + ... Reference: clause 7.4.2.3.3 - ETSI GS NFV-SOL 002 [2] v2.6.1 + ... Config ID: Config_prod_VNFM + ... Applicability: + ... Post-Conditions: none + GET Alarms Task with exclude_fields attribute selector + Check HTTP Response Status Code Is 200 + Check HTTP Response Body Json Schema Is alarms PUT Alarms - Method not implemented [Documentation] Test ID: 6.3.4.1.9 ... Test title: PUT Alarms - Method not implemented ... Test objective: The objective is to test that the method is not implemented ... Pre-conditions: - ... Reference: clause 7.4.2.3.3 - ETSI GS NFV-SOL 002 [2] v2.4.1 + ... Reference: clause 7.4.2.3.4 - ETSI GS NFV-SOL 002 [2] v2.6.1 ... Config ID: Config_prod_VNFM ... Applicability: ... Post-Conditions: none @@ -75,7 +129,7 @@ PATCH Alarms - Method not implemented ... Test title: PATCH Alarms - Method not implemented ... Test objective: The objective is to test that the method is not implemented ... Pre-conditions: - ... Reference: clause 7.4.2.3.4 - ETSI GS NFV-SOL 002 [2] v2.4.1 + ... Reference: clause 7.4.2.3.5 - ETSI GS NFV-SOL 002 [2] v2.6.1 ... Config ID: Config_prod_VNFM ... Applicability: ... Post-Conditions: none @@ -87,12 +141,122 @@ DELETE Alarms - Method not implemented ... Test title: DELETE Alarms - Method not implemented ... Test objective: The objective is to test that the method is not implemented ... Pre-conditions: - ... Reference: clause 7.4.2.3.5 - ETSI GS NFV-SOL 002 [2] v2.4.1 + ... Reference: clause 7.4.2.3.6 - ETSI GS NFV-SOL 002 [2] v2.6.1 ... Config ID: Config_prod_VNFM ... Applicability: ... Post-Conditions: the alarm is not deleted DELETE Alarms Task Check HTTP Response Status Code Is 405 + +GET information about multiple alarms to get Paged Response + [Documentation] Test ID: 6.3.4.1.12 + ... Test title: GET information about multiple alarms to get Paged Response + ... Test objective: The objective is to retrieve information about the alarms to get paged response + ... Pre-conditions: + ... Reference: clause 7.4.2.3.2 - ETSI GS NFV-SOL 002 [2] v2.6.1 + ... Config ID: Config_prod_VNFM + ... Applicability: + ... Post-Conditions: + GET Alarms Task + Check HTTP Response Status Code Is 200 + Check LINK in Header + +GET information about multiple alarms for Bad Request Response too big + [Documentation] Test ID: 6.3.4.1.13 + ... Test title: GET information about multiple alarms for Bad Request Response too big + ... Test objective: The objective is to test that GET method fail retrieving status information about Alarms when Response is too big, and perform the JSON schema validation of the failed operation HTTP response + ... Pre-conditions: + ... Reference: clause 7.4.2.3.4 - ETSI GS NFV-SOL 002 [2] v2.6.1 + ... Config ID: Config_prod_VNFM + ... Applicability: + ... Post-Conditions: + GET Alarms Task with invalid filter + Check HTTP Response Status Code Is 400 + Check HTTP Response Body Json Schema Is ProblemDetails + +GET information about alarms with attribute-based filter "id" + [Documentation] Test ID: 6.3.4.1.14 + ... Test title: GET information about alarms with attribute-based filter "id" + ... Test objective: The objective is to retrieve information about the alarm list with alarm filter "id" + ... Pre-conditions: + ... Reference: clause 7.4.2.3.3 - ETSI GS NFV-SOL 002 [2] v2.6.1 + ... Config ID: Config_prod_VNFM + ... Applicability: + ... Post-Conditions: + GET Alarms Task with filter "id" + Check HTTP Response Status Code Is 200 + Check HTTP Response Body Json Schema Is alarm + Check PostCondition HTTP Response Body alarms Matches the requested attribute-based filter "id" + +GET information about multiple alarms with attribute-based filter "vnfcInstanceIds" + [Documentation] Test ID: 6.3.4.1.15 + ... Test title: GET information about multiple alarms with attribute-based filter "vnfcInstanceIds" + ... Test objective: The objective is to retrieve information about the alarm list with attribute filter "vnfcInstanceIds" + ... Pre-conditions: + ... Reference: clause 7.4.2.3.3 - ETSI GS NFV-SOL 002 [2] v2.6.1 + ... Config ID: Config_prod_VNFM + ... Applicability: + ... Post-Conditions: + GET Alarms Task with filter "vnfcInstanceIds" + Check HTTP Response Status Code Is 200 + Check HTTP Response Body Json Schema Is alarms + Check PostCondition HTTP Response Body alarms Matches the requested attribute-based filter "vnfcInstanceIds" + +GET information about multiple alarms with attribute-based filter "rootCauseFaultyResource.faultyResourceType" + [Documentation] Test ID: 6.3.4.1.16 + ... Test title: GET information about multiple alarms with attribute-based filter "rootCauseFaultyResource.faultyResourceType" + ... Test objective: The objective is to retrieve information about the alarm list with attribute filter "rootCauseFaultyResource.faultyResourceType" + ... Pre-conditions: + ... Reference: clause 7.4.2.3.3 - ETSI GS NFV-SOL 002 [2] v2.6.1 + ... Config ID: Config_prod_VNFM + ... Applicability: + ... Post-Conditions: + GET Alarms Task with filter "rootCauseFaultyResource_faultyResourceType" + Check HTTP Response Status Code Is 200 + Check HTTP Response Body Json Schema Is alarms + Check PostCondition HTTP Response Body alarms Matches the requested attribute-based filter "rootCauseFaultyResource_faultyResourceType" + +GET information about multiple alarms with attribute-based filter "eventType" + [Documentation] Test ID: 6.3.4.1.17 + ... Test title: GET information about multiple alarms with attribute-based filter "eventType" + ... Test objective: The objective is to retrieve information about the alarm list with attribute filter "eventType" + ... Pre-conditions: + ... Reference: clause 7.4.2.3.3 - ETSI GS NFV-SOL 002 [2] v2.6.1 + ... Config ID: Config_prod_VNFM + ... Applicability: + ... Post-Conditions: + GET Alarms Task with filter "eventType" + Check HTTP Response Status Code Is 200 + Check HTTP Response Body Json Schema Is alarms + Check PostCondition HTTP Response Body alarms Matches the requested attribute-based filter "eventType" + +GET information about multiple alarms with attribute-based filter "perceivedSeverity" + [Documentation] Test ID: 6.3.4.1.18 + ... Test title: GET information about multiple alarms with attribute-based filter "perceivedSeverity" + ... Test objective: The objective is to retrieve information about the alarm list with attribute filter "perceivedSeverity" + ... Pre-conditions: + ... Reference: clause 7.4.2.3.3 - ETSI GS NFV-SOL 002 [2] v2.6.1 + ... Config ID: Config_prod_VNFM + ... Applicability: + ... Post-Conditions: + GET Alarms Task with filter "perceivedSeverity" + Check HTTP Response Status Code Is 200 + Check HTTP Response Body Json Schema Is alarms + Check PostCondition HTTP Response Body alarms Matches the requested attribute-based filter "perceivedSeverity" + +GET information about multiple alarms with attribute-based filter "probableCause" + [Documentation] Test ID: 6.3.4.1.19 + ... Test title: GET information about multiple alarms with attribute-based filter "probableCause" + ... Test objective: The objective is to retrieve information about the alarm list with attribute filter "probableCause" + ... Pre-conditions: + ... Reference: clause 7.4.2.3.3 - ETSI GS NFV-SOL 002 [2] v2.6.1 + ... Config ID: Config_prod_VNFM + ... Applicability: + ... Post-Conditions: + GET Alarms Task with filter "probableCause" + Check HTTP Response Status Code Is 200 + Check HTTP Response Body Json Schema Is alarms + Check PostCondition HTTP Response Body alarms Matches the requested attribute-based filter "probableCause" *** Keywords *** POST Alarms Task @@ -193,3 +357,89 @@ Check HTTP Response Body Json Schema Is ${schema} = Catenate SEPARATOR= ${input} .schema.json Validate Json ${schema} ${response['body']} Log Json Schema Validation OK + +Check LINK in Header + ${linkURL}= Get Value From Json ${response.headers} $..Link + Should Not Be Empty ${linkURL} + +GET Alarms Task with filter "id" + Log Query VNF The GET method queries information about multiple alarms with filters "id". + Set Headers {"Accept":"${ACCEPT}"} + Run Keyword If ${AUTH_USAGE} == 1 Set Headers {"Authorization":"${AUTHORIZATION}"} + Log Execute Query and validate response + Get ${apiRoot}/${apiName}/${apiVersion}/alarms?id=${alarmId} + ${outputResponse}= Output response + Set Global Variable @{response} ${outputResponse} + +Check PostCondition HTTP Response Body alarms Matches the requested attribute-based filter "id" + Should Be Equal As Strings ${response['body']['id']} ${alarmId} + +GET Alarms Task with filter "vnfcInstanceIds" + Log Query VNF The GET method queries information about multiple alarms with filters "vnfcInstanceIds". + Set Headers {"Accept":"${ACCEPT}"} + Run Keyword If ${AUTH_USAGE} == 1 Set Headers {"Authorization":"${AUTHORIZATION}"} + Log Execute Query and validate response + Get ${apiRoot}/${apiName}/${apiVersion}/alarms?vnfcInstanceIds=${vnfcInstanceIds} + ${outputResponse}= Output response + Set Global Variable @{response} ${outputResponse} + +Check PostCondition HTTP Response Body alarms Matches the requested attribute-based filter "vnfcInstanceIds" + :FOR ${item} IN @{response['body']} + Lists Should Be Equal ${item['vnfcInstanceIds']} ${vnfcInstanceIds} + END + +GET Alarms Task with filter "rootCauseFaultyResource_faultyResourceType" + Log Query VNF The GET method queries information about multiple alarms with filters "rootCauseFaultyResource.faultyResourceType". + Set Headers {"Accept":"${ACCEPT}"} + Run Keyword If ${AUTH_USAGE} == 1 Set Headers {"Authorization":"${AUTHORIZATION}"} + Log Execute Query and validate response + Get ${apiRoot}/${apiName}/${apiVersion}/alarms?rootCauseFaultyResource.faultyResourceType=${faultyResourceType} + ${outputResponse}= Output response + Set Global Variable @{response} ${outputResponse} + +Check PostCondition HTTP Response Body alarms Matches the requested attribute-based filter "rootCauseFaultyResource_faultyResourceType" + :FOR ${item} IN @{response['body']} + Should Be Equal As Strings ${item['rootCauseFaultyResource']['faultyResourceType']} ${faultyResourceType} + END + +GET Alarms Task with filter "eventType" + Log Query VNF The GET method queries information about multiple alarms with filters "eventType". + Set Headers {"Accept":"${ACCEPT}"} + Run Keyword If ${AUTH_USAGE} == 1 Set Headers {"Authorization":"${AUTHORIZATION}"} + Log Execute Query and validate response + Get ${apiRoot}/${apiName}/${apiVersion}/alarms?eventType=${eventType} + ${outputResponse}= Output response + Set Global Variable @{response} ${outputResponse} + +Check PostCondition HTTP Response Body alarms Matches the requested attribute-based filter "eventType" + :FOR ${item} IN @{response['body']} + Should Be Equal As Strings ${item['eventType']} ${eventType} + END + +GET Alarms Task with filter "perceivedSeverity" + Log Query VNF The GET method queries information about multiple alarms with filters "perceivedSeverity". + Set Headers {"Accept":"${ACCEPT}"} + Run Keyword If ${AUTH_USAGE} == 1 Set Headers {"Authorization":"${AUTHORIZATION}"} + Log Execute Query and validate response + Get ${apiRoot}/${apiName}/${apiVersion}/alarms?perceivedSeverity=${perceivedSeverity} + ${outputResponse}= Output response + Set Global Variable @{response} ${outputResponse} + +Check PostCondition HTTP Response Body alarms Matches the requested attribute-based filter "perceivedSeverity" + :FOR ${item} IN @{response['body']} + Should Be Equal As Strings ${item['perceivedSeverity']} ${perceivedSeverity} + END + +GET Alarms Task with filter "probableCause" + Log Query VNF The GET method queries information about multiple alarms with filters "probableCause". + Set Headers {"Accept":"${ACCEPT}"} + Run Keyword If ${AUTH_USAGE} == 1 Set Headers {"Authorization":"${AUTHORIZATION}"} + Log Execute Query and validate response + Get ${apiRoot}/${apiName}/${apiVersion}/alarms?probableCause=${probableCause} + ${outputResponse}= Output response + Set Global Variable @{response} ${outputResponse} + +Check PostCondition HTTP Response Body alarms Matches the requested attribute-based filter "probableCause" + :FOR ${item} IN @{response['body']} + Should Be Equal As Strings ${item['probableCause']} ${probableCause} + END \ No newline at end of file diff --git a/SOL002/VNFFaultManagement-API/EscalatePerceivedSeverityTask.robot b/SOL002/VNFFaultManagement-API/EscalatePerceivedSeverityTask.robot index 87c44a93b913702b6211e5094c85fa6215dc7af5..3521496cff2db6e7e2ac577692846c3120751988 100644 --- a/SOL002/VNFFaultManagement-API/EscalatePerceivedSeverityTask.robot +++ b/SOL002/VNFFaultManagement-API/EscalatePerceivedSeverityTask.robot @@ -10,7 +10,7 @@ Escalate the perceived severity ... Test title: Escalate the perceived severity ... Test objective: To enable the consumer to escalate the perceived severity of an alarm that is represented by an individual alarm resource. ... Pre-conditions: The resource representing the individual alarm has been created - ... Reference: clause 7.4.4.3.1 - ETSI GS NFV-SOL 002 [2] v2.4.1 + ... Reference: clause 7.4.4.3.1 - ETSI GS NFV-SOL 002 [2] v2.6.1 ... Config ID: Config_prod_VNFM ... Applicability: ... Post-Conditions: @@ -22,7 +22,7 @@ GET Escalate the perceived severity - Method not implemented ... Test title: GET Escalate the perceived severity - Method not implemented ... Test objective: The objective is to test that the GET HTTP method not implemented for escalate perceived severity ... Pre-conditions: - ... Reference: clause 7.4.4.3.2 - ETSI GS NFV-SOL 002 [2] v2.4.1 + ... Reference: clause 7.4.4.3.2 - ETSI GS NFV-SOL 002 [2] v2.6.1 ... Config ID: Config_prod_VNFM ... Applicability: ... Post-Conditions: @@ -34,7 +34,7 @@ PUT Escalate the perceived severity - Method not implemented ... Test title: PUT Escalate the perceived severity - Method not implemented ... Test objective: The objective is to test that the PUT HTTP method not implemented for escalate perceived severity ... Pre-conditions: - ... Reference: clause 7.4.4.3.3 - ETSI GS NFV-SOL 002 [2] v2.4.1 + ... Reference: clause 7.4.4.3.3 - ETSI GS NFV-SOL 002 [2] v2.6.1 ... Config ID: Config_prod_VNFM ... Applicability: ... Post-Conditions: @@ -46,7 +46,7 @@ PATCH Escalate the perceived severity - Method not implemented ... Test title: PATCH Escalate the perceived severity - Method not implemented ... Test objective: The objective is to test that the PATCH HTTP method not implemented for escalate perceived severity ... Pre-conditions: - ... Reference: clause 7.4.4.3.4 - ETSI GS NFV-SOL 002 [2] v2.4.1 + ... Reference: clause 7.4.4.3.4 - ETSI GS NFV-SOL 002 [2] v2.6.1 ... Config ID: Config_prod_VNFM ... Applicability: ... Post-Conditions: @@ -59,7 +59,7 @@ DELETE Escalate the perceived severity - Method not implemented ... Test title: DELETE Escalate the perceived severity - Method not implemented ... Test objective: The objective is to test that the DELETE HTTP method not implemented for escalate perceived severity ... Pre-conditions: - ... Reference: clause 7.4.4.3.5 - ETSI GS NFV-SOL 002 [2] v2.4.1 + ... Reference: clause 7.4.4.3.5 - ETSI GS NFV-SOL 002 [2] v2.6.1 ... Config ID: Config_prod_VNFM ... Applicability: ... Post-Conditions: diff --git a/SOL002/VNFFaultManagement-API/IndividualAlarm.robot b/SOL002/VNFFaultManagement-API/IndividualAlarm.robot index 29f26677e57aae180a3f21a3cb4f35c00af7bd43..3725ed77255bbff78cd0a1a3a93fbe75899d15d0 100644 --- a/SOL002/VNFFaultManagement-API/IndividualAlarm.robot +++ b/SOL002/VNFFaultManagement-API/IndividualAlarm.robot @@ -18,7 +18,7 @@ POST Alarm - Method not implemented ... Test title: POST Alarm - Method not implemented ... Test objective: The objective is to test that the method is not implemented ... Pre-conditions: - ... Reference: clause 7.4.3.3.1 - ETSI GS NFV-SOL 002 [2] v2.4.1 + ... Reference: clause 7.4.3.3.1 - ETSI GS NFV-SOL 002 [2] v2.6.1 ... Config ID: Config_prod_VNFM ... Applicability: ... Post-Conditions: none @@ -31,7 +31,7 @@ GET information about an individual alarm ... Test title: GET information about an individual alarm ... Test objective: The objective is to read an individual alarm. ... Pre-conditions: The related alarm exists - ... Reference: clause 7.4.3.3.2 - ETSI GS NFV-SOL 002 [2] v2.4.1 + ... Reference: clause 7.4.3.3.2 - ETSI GS NFV-SOL 002 [2] v2.6.1 ... Config ID: Config_prod_VNFM ... Applicability: ... Post-Conditions: @@ -46,7 +46,7 @@ PUT Individual Alarm - Method not implemented ... Test title: PUT Individual Alarm - Method not implemented ... Test objective: The objective is to test that the method is not implemented ... Pre-conditions: - ... Reference: clause 7.4.3.3.3 - ETSI GS NFV-SOL 002 [2] v2.4.1 + ... Reference: clause 7.4.3.3.3 - ETSI GS NFV-SOL 002 [2] v2.6.1 ... Config ID: Config_prod_VNFM ... Applicability: ... Post-Conditions: none @@ -59,7 +59,7 @@ PATCH Individual Alarm ... Test title: PATCH Individual Alarm ... Test objective: The objective is to Modify an individual alarm resource ... Pre-conditions: The related alarm exists - ... Reference: clause 7.4.3.3.4 - ETSI GS NFV-SOL 002 [2] v2.4.1 + ... Reference: clause 7.4.3.3.4 - ETSI GS NFV-SOL 002 [2] v2.6.1 ... Config ID: Config_prod_VNFM ... Applicability: ... Post-Conditions: none @@ -72,7 +72,7 @@ PATCH Individual Alarm - Precondition failed ... Test title: PATCH Individual Alarm - Precondition failed ... Test objective: The objective is to attempt to Modify an individual alarm resource, where the precondition was not met ... Pre-conditions: The related alarm exists - ... Reference: clause 7.4.3.3.4 - ETSI GS NFV-SOL 002 [2] v2.4.1 + ... Reference: clause 7.4.3.3.4 - ETSI GS NFV-SOL 002 [2] v2.6.1 ... Config ID: Config_prod_VNFM ... Applicability: ... Post-Conditions: The alarm resource is not modified @@ -85,7 +85,7 @@ PATCH Individual Alarm - Conflict ... Test title: PATCH Individual Alarm - Conflict ... Test objective: The objective is to Modify an individual alarm resource ... Pre-conditions: The related alarm exists - ... Reference: clause 7.4.3.3.4 - ETSI GS NFV-SOL 002 [2] v2.4.1 + ... Reference: clause 7.4.3.3.4 - ETSI GS NFV-SOL 002 [2] v2.6.1 ... Config ID: Config_prod_VNFM ... Applicability: ... Post-Conditions: The alarm resource is not modified @@ -99,7 +99,7 @@ DELETE Individual Alarm - Method not implemented ... Test title: DELETE Individual Alarm - Method not implemented ... Test objective: The objective is to test that the method is not implemented ... Pre-conditions: - ... Reference: clause 7.4.3.3.5 - ETSI GS NFV-SOL 002 [2] v2.4.1 + ... Reference: clause 7.4.3.3.5 - ETSI GS NFV-SOL 002 [2] v2.6.1 ... Config ID: Config_prod_VNFM ... Applicability: ... Post-Conditions: alarm not deleted diff --git a/SOL002/VNFFaultManagement-API/IndividualSubscription.robot b/SOL002/VNFFaultManagement-API/IndividualSubscription.robot index 650f490892ca8333a1da826e03a6ca8471e8388e..c6424f588bf9d89a7df98f858bb1cef481e04591 100644 --- a/SOL002/VNFFaultManagement-API/IndividualSubscription.robot +++ b/SOL002/VNFFaultManagement-API/IndividualSubscription.robot @@ -13,7 +13,7 @@ POST Individual Subscription - Method not implemented ... Test title: POST Individual Subscription - Method not implemented ... Test objective: The objective is to test that the method is not implemented ... Pre-conditions: - ... Reference: clause 7.4.6.3.1 - ETSI GS NFV-SOL 002 [2] v2.4.1 + ... Reference: clause 7.4.6.3.1 - ETSI GS NFV-SOL 002 [2] v2.6.1 ... Config ID: Config_prod_VNFM ... Applicability: ... Post-Conditions: @@ -25,7 +25,7 @@ GET Information about an individual subscription ... Test title: GET Information about an individual subscription ... Test objective: The objective is to read an individual subscription for VNF alarms subscribed by the client ... Pre-conditions: The subscription with the given id exists - ... Reference: clause 7.4.6.3.2 - ETSI GS NFV-SOL 002 [2] v2.4.1 + ... Reference: clause 7.4.6.3.2 - ETSI GS NFV-SOL 002 [2] v2.6.1 ... Config ID: Config_prod_VNFM ... Applicability: ... Post-Conditions: @@ -38,7 +38,7 @@ PUT an individual subscription - Method not implemented ... Test title: PUT an individual subscription - Method not implemented ... Test objective: The objective is to test that the method is not implemented ... Pre-conditions: - ... Reference: clause 7.4.6.3.3 - ETSI GS NFV-SOL 002 [2] v2.4.1 + ... Reference: clause 7.4.6.3.3 - ETSI GS NFV-SOL 002 [2] v2.6.1 ... Config ID: Config_prod_VNFM ... Applicability: ... Post-Conditions: @@ -51,7 +51,7 @@ PATCH an individual subscription - Method not implemented ... Test title: PATCH an individual subscription - Method not implemented ... Test objective: The objective is to test that the method is not implemented ... Pre-conditions: - ... Reference: clause 7.4.6.3.4 - ETSI GS NFV-SOL 002 [2] v2.4.1 + ... Reference: clause 7.4.6.3.4 - ETSI GS NFV-SOL 002 [2] v2.6.1 ... Config ID: Config_prod_VNFM ... Applicability: ... Post-Conditions: @@ -64,7 +64,7 @@ DELETE an individual subscription ... Test title: DELETE an individual subscription ... Test objective: The objective is to test that the deletion of a subscription ... Pre-conditions: an existing subscription - ... Reference: clause 7.4.6.3.5 - ETSI GS NFV-SOL 002 [2] v2.4.1 + ... Reference: clause 7.4.6.3.5 - ETSI GS NFV-SOL 002 [2] v2.6.1 ... Config ID: Config_prod_VNFM ... Applicability: ... Post-Conditions: the subscription is deleted diff --git a/SOL002/VNFFaultManagement-API/NotificationEndpoint.robot b/SOL002/VNFFaultManagement-API/NotificationEndpoint.robot index 2201f3d1b27fabddfa12ca83c6c170e46159156c..36327a91d139fac56df85492d332c493d87bbb44 100644 --- a/SOL002/VNFFaultManagement-API/NotificationEndpoint.robot +++ b/SOL002/VNFFaultManagement-API/NotificationEndpoint.robot @@ -15,7 +15,7 @@ VNF Fault Alarm Notification ... Test title: VNF Fault Alarm Notification ... Test objective: The objective is to test the dispatch of VNF Fault Alarm Notification when a virtualised resource within an VNF instance fails, and perform a JSON schema and content validation of the delivered notification. The action that triggers the notification under test is an explicit test step, but it is not performed by the test system. ... Pre-conditions: A VNF instance is instantiated, and a subscription for fault alarm notifications is available in the VNFM. - ... Reference: clause 7.4.7.3.1 - ETSI GS NFV-SOL 002 [2] v2.4.1 + ... Reference: clause 7.4.7.3.1 - ETSI GS NFV-SOL 002 [2] v2.6.1 ... Config ID: Config_prod_VNFM ... Applicability: none ... Post-Conditions: none @@ -28,7 +28,7 @@ VNF Fault Alarm Cleared Notification ... Test title: VNF Fault Alarm Cleared Notification ... Test objective: The objective is to test the dispatch of VNF Fault Alarm Cleared Notification when a faulty virtualised resource within an VNF instance is cleared, and perform a JSON schema and content validation of the delivered notification. The action that triggers the notification under test is an explicit test step, but it is not performed by the test system. ... Pre-conditions: A VNF instance is instantiated, a virtualised resource is in faulty state, and a subscription for fault alarm cleared notifications is available in the VNFM. - ... Reference: clause 7.4.7.3.1 - ETSI GS NFV-SOL 002 [2] v2.4.1 + ... Reference: clause 7.4.7.3.1 - ETSI GS NFV-SOL 002 [2] v2.6.1 ... Config ID: Config_prod_VNFM ... Applicability: none ... Post-Conditions: none @@ -41,7 +41,7 @@ VNF Fault Alarm List Rebuilt Notification ... Test title: VNF Fault Alarm List Rebuilt Notification ... Test objective: The objective is to test the dispatch of VNF Fault Alarm List Rebuilt Notification when the VNFM decides to rebuild the list of its VNF alarms, e.g. due to a corruption in the alarm storage, and perform a JSON schema and content validation of the delivered notification. The action that triggers the notification under test is an explicit test step, but it is not performed by the test system. ... Pre-conditions: A VNF instance is instantiated, one or more virtualised resource are in faulty state, and a subscription for fault alarm list rebuilt notifications is available in the VNFM. - ... Reference: clause 7.4.7.3.1 - ETSI GS NFV-SOL 002 [2] v2.4.1 + ... Reference: clause 7.4.7.3.1 - ETSI GS NFV-SOL 002 [2] v2.6.1 ... Config ID: Config_prod_VNFM ... Applicability: none ... Post-Conditions: none diff --git a/SOL002/VNFFaultManagement-API/Subscriptions.robot b/SOL002/VNFFaultManagement-API/Subscriptions.robot index b24fc27a1d8386ba8fafb508e0276de7089d0446..338d01d1b10f76f985b65ecaad2ad5b95fac2bf3 100644 --- a/SOL002/VNFFaultManagement-API/Subscriptions.robot +++ b/SOL002/VNFFaultManagement-API/Subscriptions.robot @@ -11,7 +11,7 @@ Create a new subscription ... Test title: Create a new subscription ... Test objective: The objective is to create a new subscription. ... Pre-conditions: no subscription with the same filter and callbackUri exists - ... Reference: clause 7.4.5.3.1 - ETSI GS NFV-SOL 002 [2] v2.4.1 + ... Reference: clause 7.4.5.3.1 - ETSI GS NFV-SOL 002 [2] v2.6.1 ... Config ID: Config_prod_VNFM ... Applicability: ... Post-Conditions: Resource created successfully @@ -25,7 +25,7 @@ Create a new Subscription - DUPLICATION ... Test title: Create a new Subscription - DUPLICATION ... Test objective: The objective is to create a duplicate subscription. ... Pre-conditions: subscription with the same filter and callbackUri exists - ... Reference: clause 7.4.5.3.1 - ETSI GS NFV-SOL 002 [2] v2.4.1 + ... Reference: clause 7.4.5.3.1 - ETSI GS NFV-SOL 002 [2] v2.6.1 ... Config ID: Config_prod_VNFM ... Applicability: the VNFM does not allow creation of a subscription resource if another subscription resource with the same filter and callbackUri already exists ... Post-Conditions: duplicated subscription is created @@ -38,7 +38,7 @@ Create a new Subscription - NO-DUPLICATION ... Test title: Create a new Subscription - NO-DUPLICATION ... Test objective: The objective is to create a subscription in case of not allowed DUPLICATION. ... Pre-conditions: subscription with the same filter and callbackUri exists - ... Reference: clause 7.4.5.3.1 - ETSI GS NFV-SOL 002 [2] v2.4.1 + ... Reference: clause 7.4.5.3.1 - ETSI GS NFV-SOL 002 [2] v2.6.1 ... Config ID: Config_prod_VNFM ... Applicability: the VNFM does not allow creation of a duplicate subscription resource ... Post-Conditions: duplicated subscription is not created @@ -50,7 +50,7 @@ GET Subscriptions ... Test title: GET Subscriptions ... Test objective: The objective is to retrieve the list of active subscriptions ... Pre-conditions: - ... Reference: clause 7.4.5.3.2 - ETSI GS NFV-SOL 002 [2] v2.4.1 + ... Reference: clause 7.4.5.3.2 - ETSI GS NFV-SOL 002 [2] v2.6.1 ... Config ID: Config_prod_VNFM ... Applicability: ... Post-Conditions: subscription is not deleted @@ -63,7 +63,7 @@ GET Subscription - Filter ... Test title: GET Subscription - Filter ... Test objective: The objective is to retrieve the list of active subscriptions with filter ... Pre-conditions: - ... Reference: clause 7.4.5.3.2 - ETSI GS NFV-SOL 002 [2] v2.4.1 + ... Reference: clause 7.4.5.3.2 - ETSI GS NFV-SOL 002 [2] v2.6.1 ... Config ID: Config_prod_VNFM ... Applicability: ... Post-Conditions: @@ -76,20 +76,74 @@ GET subscriptions - Bad Request Invalid attribute-based filtering parameters ... Test title: GET subscriptions - Bad Request Invalid attribute-based filtering parameters ... Test objective: The objective is to retrieve the list of active subscriptions with Invalid attribute-based filtering parameters ... Pre-conditions: - ... Reference: clause 7.4.5.3.2 - ETSI GS NFV-SOL 002 [2] v2.4.1 + ... Reference: clause 7.4.5.3.2 - ETSI GS NFV-SOL 002 [2] v2.6.1 ... Config ID: Config_prod_VNFM ... Applicability: ... Post-Conditions: Get subscriptions - invalid filter Check HTTP Response Status Code Is 400 Check HTTP Response Body Json Schema Is ProblemDetails + +GET subscriptions with "all_fields" attribute selector + [Documentation] Test ID: 6.3.4.4.8 + ... Test title: GET subscriptions with "all_fields" attribute selector + ... Test objective: The objective is to retrieve the list of active subscriptions with attribute selector + ... Pre-conditions: + ... Reference: clause 7.4.5.3.2 - ETSI GS NFV-SOL 002 [2] v2.6.1 + ... Config ID: Config_prod_VNFM + ... Applicability: + ... Post-Conditions: + Get subscriptions with all_fields attribute selector + Check HTTP Response Status Code Is 200 + Check HTTP Response Body Json Schema Is FmSubscriptions + +GET subscriptions with "exclude_default" attribute selector + [Documentation] Test ID: 6.3.4.4.9 + ... Test title: GET subscriptions with "exclude_default" attribute selector + ... Test objective: The objective is to retrieve the list of active subscriptions with attribute selector + ... Pre-conditions: + ... Reference: clause 7.4.5.3.2 - ETSI GS NFV-SOL 002 [2] v2.6.1 + ... Config ID: Config_prod_VNFM + ... Applicability: + ... Post-Conditions: + Get subscriptions with exclude_default attribute selector + Check HTTP Response Status Code Is 200 + Check HTTP Response Body Json Schema Is FmSubscriptions + +GET subscriptions with "fields" attribute selector + [Documentation] Test ID: 6.3.4.4.10 + ... Test title: GET subscriptions with "fields" attribute selector + ... Test objective: The objective is to retrieve the list of active subscriptions with attribute selector + ... Pre-conditions: + ... Reference: clause 7.4.5.3.2 - ETSI GS NFV-SOL 002 [2] v2.6.1 + ... Config ID: Config_prod_VNFM + ... Applicability: + ... Post-Conditions: + Get subscriptions with fields attribute selector + Check HTTP Response Status Code Is 200 + Check HTTP Response Body Json Schema Is FmSubscriptions + +GET subscriptions with "exclude_fields" attribute selector + [Documentation] Test ID: 6.3.4.4.11 + ... Test title: GET subscriptions with "exclude_fields" attribute selector + ... Test objective: The objective is to retrieve the list of active subscriptions with attribute selector + ... Pre-conditions: + ... Reference: clause 7.4.5.3.2 - ETSI GS NFV-SOL 002 [2] v2.6.1 + ... Config ID: Config_prod_VNFM + ... Applicability: + ... Post-Conditions: + Get subscriptions with exclude_fields attribute selector + Check HTTP Response Status Code Is 200 + Check HTTP Response Body Json Schema Is FmSubscriptions + + PUT subscriptions - Method not implemented [Documentation] Test ID: 6.3.4.4.8 ... Test title: PUT subscriptions - Method not implemented ... Test objective: The objective is to test that the method is not implemented ... Pre-conditions: - ... Reference: clause 7.4.5.3.3 - ETSI GS NFV-SOL 002 [2] v2.4.1 + ... Reference: clause 7.4.5.3.3 - ETSI GS NFV-SOL 002 [2] v2.6.1 ... Config ID: Config_prod_VNFM ... Applicability: ... Post-Conditions: @@ -101,7 +155,7 @@ PATCH subscriptions - Method not implemented ... Test title: PUT subscriptions - Method not implemented ... Test objective: The objective is to test that the method is not implemented ... Pre-conditions: - ... Reference: clause 7.4.5.3.4 - ETSI GS NFV-SOL 002 [2] v2.4.1 + ... Reference: clause 7.4.5.3.4 - ETSI GS NFV-SOL 002 [2] v2.6.1 ... Config ID: Config_prod_VNFM ... Applicability: ... Post-Conditions: @@ -113,13 +167,124 @@ DELETE subscriptions - Method not implemented ... Test title: DELETE subscriptions - Method not implemented ... Test objective: The objective is to test that the method is not implemented ... Pre-conditions: - ... Reference: clause 7.4.5.3.5 - ETSI GS NFV-SOL 002 [2] v2.4.1 + ... Reference: clause 7.4.5.3.5 - ETSI GS NFV-SOL 002 [2] v2.6.1 ... Config ID: Config_prod_VNFM ... Applicability: ... Post-Conditions: subscription not deleted DELETE subscriptions Check HTTP Response Status Code Is 405 + +GET Subscriptions to get Paged Response + [Documentation] Test ID: 6.3.4.4.11 + ... Test title: GET Subscriptions to get Paged Response + ... Test objective: The objective is to retrieve the list of active subscriptions to get paged response + ... Pre-conditions: + ... Reference: clause 7.4.5.3.2 - ETSI GS NFV-SOL 002 [2] v2.6.1 + ... Config ID: Config_prod_VNFM + ... Applicability: + ... Post-Conditions: subscription is not deleted + Get subscriptions + Check HTTP Response Status Code Is 200 + Check LINK in Header + +GET subscriptions - Bad Request Response too Big + [Documentation] Test ID: 6.3.4.4.12 + ... Test title: GET subscriptions - Bad Request Response too Big + ... Test objective: The objective is to test that GET method fail retrieving list of active subscription because Response is too big, and perform the JSON schema validation of the failed operation HTTP response + ... Pre-conditions: + ... Reference: clause 7.4.5.3.2 - ETSI GS NFV-SOL 002 [2] v2.6.1 + ... Config ID: Config_prod_VNFM + ... Applicability: + ... Post-Conditions: + Get subscriptions - invalid filter + Check HTTP Response Status Code Is 400 + Check HTTP Response Body Json Schema Is ProblemDetails +GET Subscription with attribute-based filter "id" + [Documentation] Test ID: 6.3.4.4.13 + ... Test title: GET Subscription with attribute-based filter "id" + ... Test objective: The objective is to retrieve the list of active subscriptions with filter "id" + ... Pre-conditions: + ... Reference: clause 7.4.5.3.2 - ETSI GS NFV-SOL 002 [2] v2.6.1 + ... Config ID: Config_prod_VNFM + ... Applicability: + ... Post-Conditions: + Get subscriptions with filter "id" + Check HTTP Response Status Code Is 200 + Check HTTP Response Body Json Schema Is FmSubscription + Check PostCondition HTTP Response Body Subscription Matches the requested attribute-based filter "id" + + +Get subscriptions with filter "filter.notificationTypes" + [Documentation] Test ID: 6.3.4.4.14 + ... Test title: GET Subscription with attribute-based filter "filter.notificationTypes" + ... Test objective: The objective is to retrieve the list of active subscriptions with filter "filter.notificationTypes" + ... Pre-conditions: + ... Reference: clause 7.4.5.3.2 - ETSI GS NFV-SOL 002 [2] v2.6.1 + ... Config ID: Config_prod_VNFM + ... Applicability: + ... Post-Conditions: + Get subscriptions with filter "filter_notificationTypes" + Check HTTP Response Status Code Is 200 + Check HTTP Response Body Json Schema Is FmSubscriptions + Check PostCondition HTTP Response Body Subscriptions Matches the requested attribute-based filter "filter_notificationTypes" + +Get subscriptions with filter "filter.faultyResourceTypes" + [Documentation] Test ID: 6.3.4.4.15 + ... Test title: GET Subscription with attribute-based filter "filter.faultyResourceTypes" + ... Test objective: The objective is to retrieve the list of active subscriptions with filter "filter.faultyResourceTypes" + ... Pre-conditions: + ... Reference: clause 7.4.5.3.2 - ETSI GS NFV-SOL 002 [2] v2.6.1 + ... Config ID: Config_prod_VNFM + ... Applicability: + ... Post-Conditions: + Get subscriptions with filter "filter_faultyResourceTypes" + Check HTTP Response Status Code Is 200 + Check HTTP Response Body Json Schema Is FmSubscriptions + Check PostCondition HTTP Response Body Subscriptions Matches the requested attribute-based filter "filter_faultyResourceTypes" + +Get subscriptions with filter "filter.perceivedSeverities" + [Documentation] Test ID: 6.3.4.4.16 + ... Test title: GET Subscription with attribute-based filter "filter.perceivedSeverities" + ... Test objective: The objective is to retrieve the list of active subscriptions with filter "filter.perceivedSeverities" + ... Pre-conditions: + ... Reference: clause 7.4.5.3.2 - ETSI GS NFV-SOL 002 [2] v2.6.1 + ... Config ID: Config_prod_VNFM + ... Applicability: + ... Post-Conditions: + Get subscriptions with filter "filter_perceivedSeverities" + Check HTTP Response Status Code Is 200 + Check HTTP Response Body Json Schema Is FmSubscriptions + Check PostCondition HTTP Response Body Subscriptions Matches the requested attribute-based filter "filter_perceivedSeverities" + +Get subscriptions with filter "filter.eventTypes" + [Documentation] Test ID: 6.3.4.4.17 + ... Test title: GET Subscription with attribute-based filter "filter.eventTypes" + ... Test objective: The objective is to retrieve the list of active subscriptions with filter "filter.eventTypes" + ... Pre-conditions: + ... Reference: clause 7.4.5.3.2 - ETSI GS NFV-SOL 002 [2] v2.6.1 + ... Config ID: Config_prod_VNFM + ... Applicability: + ... Post-Conditions: + Get subscriptions with filter "filter_eventTypes" + Check HTTP Response Status Code Is 200 + Check HTTP Response Body Json Schema Is FmSubscriptions + Check PostCondition HTTP Response Body Subscriptions Matches the requested attribute-based filter "filter_eventTypes" + +Get subscriptions with filter "filter.probableCauses" + [Documentation] Test ID: 6.3.4.4.18 + ... Test title: GET Subscription with attribute-based filter "filter.probableCauses" + ... Test objective: The objective is to retrieve the list of active subscriptions with filter "filter.probableCauses" + ... Pre-conditions: + ... Reference: clause 7.4.5.3.2 - ETSI GS NFV-SOL 002 [2] v2.6.1 + ... Config ID: Config_prod_VNFM + ... Applicability: + ... Post-Conditions: + Get subscriptions with filter "filter_probableCauses" + Check HTTP Response Status Code Is 200 + Check HTTP Response Body Json Schema Is FmSubscriptions + Check PostCondition HTTP Response Body Subscriptions Matches the requested attribute-based filter "filter_probableCauses" + *** Keywords *** Post Create subscription Log Create subscription instance by POST to ${apiRoot}/${apiName}/${apiVersion}/subscriptions @@ -235,9 +400,82 @@ Check HTTP Response Body Json Schema Is Validate Json ${schema} ${response['body']} Log Json Schema Validation OK -Check resource existence - Set Headers {"Accept":"${ACCEPT}"} - Run Keyword If ${AUTH_USAGE} == 1 Set Headers {"Authorization":"${AUTHORIZATION}"} - Get ${apiRoot}/${apiName}/${apiVersion}/subscriptions/${response['body']['id']} - Integer response status 200 - +Check LINK in Header + ${linkURL}= Get Value From Json ${response.headers} $..Link + Should Not Be Empty ${linkURL} + +Get subscriptions with filter "id" + Log Get the list of active subscriptions using a filter "id" + Set Headers {"Accept": "${ACCEPT}"} + Run Keyword If ${AUTH_USAGE} == 1 Set Headers {"Authorization": "${AUTHORIZATION}"} + GET ${apiRoot}/${apiName}/${apiVersion}/subscriptions?id=${subscription_id} + ${outputResponse}= Output response + Set Global Variable @{response} ${outputResponse} + +Check PostCondition HTTP Response Body Subscription Matches the requested attribute-based filter "id" + Should Be Equal As Strings ${response['body']['id']} ${subscription_id} + +Get subscriptions with filter "filter_notificationTypes" + Log Get the list of active subscriptions using a filter "filter.notificationTypes" + Set Headers {"Accept": "${ACCEPT}"} + Run Keyword If ${AUTH_USAGE} == 1 Set Headers {"Authorization": "${AUTHORIZATION}"} + GET ${apiRoot}/${apiName}/${apiVersion}/subscriptions?filter.notificationTypes=${notification_type} + ${outputResponse}= Output response + Set Global Variable @{response} ${outputResponse} + +Check PostCondition HTTP Response Body Subscriptions Matches the requested attribute-based filter "filter_notificationTypes" + :FOR ${item} IN @{response['body']} + Should Be Equal As Strings ${item['filter']['notificationTypes']} ${notification_type} + END + +Get subscriptions with filter "filter_faultyResourceTypes" + Log Get the list of active subscriptions using a filter "filter.faultyResourceTypes" + Set Headers {"Accept": "${ACCEPT}"} + Run Keyword If ${AUTH_USAGE} == 1 Set Headers {"Authorization": "${AUTHORIZATION}"} + GET ${apiRoot}/${apiName}/${apiVersion}/subscriptions?filter.faultyResourceTypes=${faultyResourceType} + ${outputResponse}= Output response + Set Global Variable @{response} ${outputResponse} + +Check PostCondition HTTP Response Body Subscriptions Matches the requested attribute-based filter "filter_faultyResourceTypes" + :FOR ${item} IN @{response['body']} + Should Be Equal As Strings ${item['filter']['faultyResourceTypes']} ${faultyResourceType} + END + +Get subscriptions with filter "filter_perceivedSeverities" + Log Get the list of active subscriptions using a filter "filter.perceivedSeverities" + Set Headers {"Accept": "${ACCEPT}"} + Run Keyword If ${AUTH_USAGE} == 1 Set Headers {"Authorization": "${AUTHORIZATION}"} + GET ${apiRoot}/${apiName}/${apiVersion}/subscriptions?filter.perceivedSeverities=${perceivedSeverity} + ${outputResponse}= Output response + Set Global Variable @{response} ${outputResponse} + +Check PostCondition HTTP Response Body Subscriptions Matches the requested attribute-based filter "filter_perceivedSeverities" + :FOR ${item} IN @{response['body']} + Should Be Equal As Strings ${item['filter']['perceivedSeverities']} ${perceivedSeverity} + END + +Get subscriptions with filter "filter_eventTypes" + Log Get the list of active subscriptions using a filter "filter.eventTypes" + Set Headers {"Accept": "${ACCEPT}"} + Run Keyword If ${AUTH_USAGE} == 1 Set Headers {"Authorization": "${AUTHORIZATION}"} + GET ${apiRoot}/${apiName}/${apiVersion}/subscriptions?filter.eventTypes=${eventType} + ${outputResponse}= Output response + Set Global Variable @{response} ${outputResponse} + +Check PostCondition HTTP Response Body Subscriptions Matches the requested attribute-based filter "filter_eventTypes" + :FOR ${item} IN @{response['body']} + Should Be Equal As Strings ${item['filter']['eventTypes']} ${eventType} + END + +Get subscriptions with filter "filter_probableCauses" + Log Get the list of active subscriptions using a filter "filter.probableCauses" + Set Headers {"Accept": "${ACCEPT}"} + Run Keyword If ${AUTH_USAGE} == 1 Set Headers {"Authorization": "${AUTHORIZATION}"} + GET ${apiRoot}/${apiName}/${apiVersion}/subscriptions?filter.probableCauses=${probableCause} + ${outputResponse}= Output response + Set Global Variable @{response} ${outputResponse} + +Check PostCondition HTTP Response Body Subscriptions Matches the requested attribute-based filter "filter_probableCauses" + :FOR ${item} IN @{response['body']} + Should Be Equal As Strings ${item['filter']['probableCauses']} ${probableCause} + END \ No newline at end of file diff --git a/SOL002/VNFFaultManagement-API/environment/variables.txt b/SOL002/VNFFaultManagement-API/environment/variables.txt index 4a93fafa99bbc19c33af0eee20e25f1ba79d3984..87d59878097dadefb5bcfc8ea85b486f132c5a96 100644 --- a/SOL002/VNFFaultManagement-API/environment/variables.txt +++ b/SOL002/VNFFaultManagement-API/environment/variables.txt @@ -36,7 +36,6 @@ ${callback_endpoint_error} /endpoint_404 ${sleep_interval} 20s ${total_polling_time} 2 min ${polling_interval} 10 sec - ${notification_request} [] ${notification_response} [] @@ -48,4 +47,13 @@ ${AlarmListRebuiltNotification} {} ${fields} softwareImages,additionalArtifacts -${response}= httpresponse \ No newline at end of file +${response}= httpresponse + +${vnfcInstanceIds} [] +${faultyResourceType} COMPUTE +${eventType} COMMUNICATIONS_ALARM +${perceivedSeverity} CRITICAL +${probableCause} + +${subscription_id} +${notification_type} AlarmNotification \ No newline at end of file