...Test objective: The objective is to test that POST method creates a policy.
...Pre-conditions: none
...Reference: Clause 5.5.3.3.1 - ETSI GS NFV-SOL 012 [7] v3.4.1
...Config ID: Config_prod_NFV-MANO
...Applicability: none
...Post-Conditions: Policy is created.
POST Policies
Check HTTP Response Status Code Is201
Check HTTP Response Body Json Schema IsPolicy
Check HTTP Response Header ContainsLocation
GET Policies
[Documentation]Test ID: 10.3.1.2.2
...Test title: GET Policies
...Test objective: The objective is to test that GET method retrieves the list of existing policies.
...Pre-conditions: none
...Reference: Clause 5.5.3.3.2 - ETSI GS NFV-SOL 012 [7] v3.4.1
...Config ID: Config_prod_NFV-MANO
...Applicability: none
...Post-Conditions: none
GET Policies
Check HTTP Response Status Code Is200
Check HTTP Response Body Json Schema IsPolicies
GET Policies - Filter
[Documentation]Test ID: 10.3.1.2.3
...Test title: GET Policies - Filter
...Test objective: The objective is GET the list of existing policies using a filter.
...Pre-conditions: none
...Reference: Clause 5.5.3.3.2 - ETSI GS NFV-SOL 012 [7] v3.4.1
...Config ID: Config_prod_NFV-MANO
...Applicability: none
...Post-Conditions: none
GET Policies with filter
Check HTTP Response Status Code Is200
Check HTTP Response Body Json Schema IsPolicies
GET Policies - Bad Request Invalid attribute-based filtering parameters
[Documentation]Test ID: 10.3.1.2.4
...Test title: GET Policies - Bad Request Invalid attribute-based filtering parameters
...Test objective: The objective is GET the list of existing policies using an invalid filter.
...Pre-conditions: none
...Reference: Clause 5.5.3.3.2 - ETSI GS NFV-SOL 012 [7] v3.4.1
...Config ID: Config_prod_NFV-MANO
...Applicability: none
...Post-Conditions: none
Get Policies - invalid filter
Check HTTP Response Status Code Is400
Check HTTP Response Body Json Schema IsProblemDetails
GET Policies - Bad Request Response too Big
[Documentation]Test ID: 10.3.1.2.5
...Test title: GET Policies - Bad Request Response too Big
...Test objective: The objective is test that the retrieval of existing policies list fails because response is too big, and perform the JSON schema validation of the failed operation HTTP response.
...Pre-conditions: none
...Reference: Clause 5.5.3.3.2 - ETSI GS NFV-SOL 012 [7] v3.4.1
...Config ID: Config_prod_NFV-MANO
...Applicability: none
...Post-Conditions: none
GET Policies
Check HTTP Response Status Code Is400
Check HTTP Response Body Json Schema IsProblemDetails
GET Policies with "all_fields" attribute selector
[Documentation]Test ID: 10.3.1.2.6
...Test title: GET Policies with "all_fields" attribute selector
...Test objective: The objective is to retrieve the list of existing policies with "all_fields" attribute selector.
...Pre-conditions: none
...Reference: Clause 5.5.3.3.2 - ETSI GS NFV-SOL 012 [7] v3.4.1
...Config ID: Config_prod_NFV-MANO
...Applicability: none
...Post-Conditions: none
Get Policies with all_fields attribute selector
Check HTTP Response Status Code Is200
Check HTTP Response Body Json Schema IsPolicies
GET Policies with "exclude_default" attribute selector
[Documentation]Test ID: 10.3.1.2.7
...Test title: GET policies with "exclude_default" attribute selector
...Test objective: The objective is to retrieve the list of existing policies with "exclude_default"s attribute selector.
...Pre-conditions: none
...Reference: Clause 5.5.3.3.2 - ETSI GS NFV-SOL 012 [7] v3.4.1
...Config ID: Config_prod_NFV-MANO
...Applicability:none
...Post-Conditions: none
Get Policies with exclude_default attribute selector
Check HTTP Response Status Code Is200
Check HTTP Response Body Json Schema IsPolicies
GET Policies with "fields" attribute selector
[Documentation]Test ID: 10.3.1.2.8
...Test title: GET Policies with "fields" attribute selector
...Test objective: The objective is to retrieve the list of existing policies with "fields" attribute selector.
...Pre-conditions: none
...Reference: Clause 5.5.3.3.2 - ETSI GS NFV-SOL 012 [7] v3.4.1
...Config ID: Config_prod_NFV-MANO
...Applicability:none
...Post-Conditions: none
Get Policies with fields attribute selector
Check HTTP Response Status Code Is200
Check HTTP Response Body Json Schema IsPolicies
GET Policies with "exclude_fields" attribute selector
[Documentation]Test ID: 10.3.1.2.9
...Test title: GET Policies with "exclude_fields" attribute selector
...Test objective: The objective is to retrieve the list of existing policies with "exclude_fields" attribute selector.
...Pre-conditions: none
...Reference: Clause 5.5.3.3.2 - ETSI GS NFV-SOL 012 [7] v3.4.1
...Config ID: Config_prod_NFV-MANO
...Applicability:none
...Post-Conditions: none
Get Policies with exclude_fields attribute selector
Check HTTP Response Status Code Is200
Check HTTP Response Body Json Schema IsPolicies
GET Policies with "exclude_default" and "fields" attribute selector
[Documentation]Test ID: 10.3.1.2.10
...Test title: GET Policies with "exclude_default" and "fields" attribute selector
...Test objective: The objective is to retrieve the list of existing policies with "exclude_default" and "fields" attribute selector
...Pre-conditions:
...Reference: Clause 5.5.3.3.2 - ETSI GS NFV-SOL 012 [7] v3.4.1
...Config ID: Config_prod_NFV-MANO
...Applicability: none
...Post-Conditions: none
Get Policies with exclude_default and fields attribute selector
Check HTTP Response Status Code Is200
Check HTTP Response Body Json Schema IsPolicies
GET Policies as Paged Response
[Documentation]Test ID: 10.3.1.2.11
...Test title: GET Policies as Paged Response
...Test objective: The objective is to test that GET methodretrieve the list of existing policies as paged response.
...Pre-conditions: none
...Reference: Clause 5.5.3.3.2 - ETSI GS NFV-SOL 012 [7] v3.4.1
"description":"This type represents an individual policy. It shall comply with the provisions defined in table 5.6.2.3-1.",
"type":"object",
"properties":{
"id":{
"description":"An identifier with the intention of being globally unique.\n",
"type":"string"
},
"designer":{
"description":"Human readable name of the designer of the policy.\n",
"type":"string"
},
"name":{
"description":"Human readable name of the policy.\n",
"type":"string"
},
"pfId":{
"description":"An identifier with the intention of being globally unique.\n",
"type":"string"
},
"versions":{
"description":"Versions of the policy. Shall be present if at least one version of the policy has been transferred.\n",
"type":"array",
"items":{
"description":"A version.\n",
"type":"string"
}
},
"selectedVersion":{
"description":"A version.\n",
"type":"string"
},
"activationStatus":{
"description":"The enumeration ActivationStatus shall comply with the provisions defined in table 5.6.4.3-1. It indicates the activation status of a policy.\n",
"type":"string",
"enum":[
"ACTIVATED",
"DEACTIVATED"
]
},
"transferStatus":{
"description":"The enumeration TransferStatus shall comply with the provisions defined in table 5.6.4.4-1. It indicates the transfer status of a policy\n",
"type":"string",
"enum":[
"CREATED",
"TRANSFERRED"
]
},
"associations":{
"description":"Identifiers of the entities that the PF manages and to which the policy associates to. Shall be absent when the association feature is not applicable for the PF. The associations refer to identifiers of entities that the PF manages. E.g., if the PF is a VNFM, the policy can associate to VNF instances; if the PF is NFVO, the policy can associate to an NS instances. How the PF determines the scope of applicability of the policy when this attribute is absent is outside the scope of the present document.\n",
"type":"array",
"items":{
"description":"An identifier with the intention of being globally unique.\n",
"type":"string"
}
},
"_links":{
"description":"Links for this resource\n",
"type":"object",
"properties":{
"self":{
"description":"This type represents a link to a resource using an absolute URI.\n",
"type":"object",
"required":[
"href"
],
"properties":{
"href":{
"description":"String formatted according to IETF RFC 3986.\n",
"type":"string"
}
}
},
"selected":{
"description":"This type represents a link to a resource using an absolute URI.\n",
"type":"object",
"required":[
"href"
],
"properties":{
"href":{
"description":"String formatted according to IETF RFC 3986.\n",
"type":"string"
}
}
},
"versions":{
"description":"URIs of all the transferred versions of this policy, if exists.\n",
"type":"array",
"items":{
"description":"This type represents a link to a resource using an absolute URI.\n",
"type":"object",
"required":[
"href"
],
"properties":{
"href":{
"description":"String formatted according to IETF RFC 3986.\n",