From 2de3070a7589a7281a5a4084ffb7f385b19bc86a Mon Sep 17 00:00:00 2001 From: hammad zafar Date: Tue, 2 Mar 2021 18:17:25 +0500 Subject: [PATCH 1/6] New resources added in the VNFSnapshotPackageManagement-API --- .../ApiVersion.robot | 125 ++++++ .../IndividualVNFSnapshotPackage.robot | 77 ++++ ...IndividualVNFSnapshotPackageArtifact.robot | 115 +++++ .../VNFSnapshotPackageContent.robot | 115 +++++ .../VNFSnapshotPackages.robot | 181 ++++++++ ...VnfSnapshotPackageManagementKeywords.robot | 412 ++++++++++++++++++ .../environment/variables.txt | 98 +++++ .../schemas/VnfSnapshotPkgInfo.schema.json | 350 +++++++++++++++ .../schemas/VnfSnapshotPkgInfos.schema.json | 354 +++++++++++++++ 9 files changed, 1827 insertions(+) create mode 100644 SOL003/VNFSnapshotPackageManagement-API/ApiVersion.robot create mode 100644 SOL003/VNFSnapshotPackageManagement-API/IndividualVNFSnapshotPackage.robot create mode 100644 SOL003/VNFSnapshotPackageManagement-API/IndividualVNFSnapshotPackageArtifact.robot create mode 100644 SOL003/VNFSnapshotPackageManagement-API/VNFSnapshotPackageContent.robot create mode 100644 SOL003/VNFSnapshotPackageManagement-API/VNFSnapshotPackages.robot create mode 100644 SOL003/VNFSnapshotPackageManagement-API/VnfSnapshotPackageManagementKeywords.robot create mode 100644 SOL003/VNFSnapshotPackageManagement-API/environment/variables.txt create mode 100644 SOL003/VNFSnapshotPackageManagement-API/schemas/VnfSnapshotPkgInfo.schema.json create mode 100644 SOL003/VNFSnapshotPackageManagement-API/schemas/VnfSnapshotPkgInfos.schema.json diff --git a/SOL003/VNFSnapshotPackageManagement-API/ApiVersion.robot b/SOL003/VNFSnapshotPackageManagement-API/ApiVersion.robot new file mode 100644 index 000000000..e770a7790 --- /dev/null +++ b/SOL003/VNFSnapshotPackageManagement-API/ApiVersion.robot @@ -0,0 +1,125 @@ +*** Settings *** +Resource VnfSnapshotPackageManagementKeywords.robot + +*** Test Cases *** +POST API Version - Method not implemented + [Documentation] Test ID: 7.3.8.1.1 + ... Test title: POST API version - Method not implemented + ... Test objective: The objective is to test that POST method is not implemented + ... Pre-conditions: none + ... Reference: Clause 9.3.3.3.1 - ETSI GS NFV-SOL 013 v3.3.1 + ... Config ID: Config_prod_VNFM + ... Applicability: none + ... Post-Conditions: none + POST API Version + Check HTTP Response Status Code Is 405 + +GET API Version + [Documentation] Test ID: 7.3.8.1.2 + ... Test title: GET API Version + ... Test objective: The objective is to test that GET method successfully return ApiVersionInformation + ... Pre-conditions: none + ... Reference: Clause 9.3.3.3.2 - ETSI GS NFV-SOL 013 v3.3.1 + ... Config ID: Config_prod_VNFM + ... Applicability: none + ... Post-Conditions: none + GET API Version + Check HTTP Response Status Code Is 200 + Check HTTP Response Body Json Schema Is ApiVersionInformation + +PUT API Version - Method not implemented + [Documentation] Test ID: 7.3.8.1.3 + ... Test title: PUT API Version - Method not implemented + ... Test objective: The objective is to test that PUT method is not implemented + ... Pre-conditions: none + ... Reference: Clause 9.3.3.3.3 - ETSI GS NFV-SOL 013 v3.3.1 + ... Config ID: Config_prod_VNFM + ... Applicability: none + ... Post-Conditions: none + PUT API Version + Check HTTP Response Status Code Is 405 + +PATCH API Version - Method not implemented + [Documentation] Test ID: 7.3.8.1.4 + ... Test title: PATCH API Version - Method not implemented + ... Test objective: The objective is to test that PATCH method is not implemented + ... Pre-conditions: none + ... Reference: Clause 9.3.3.3.4 - ETSI GS NFV-SOL 013 v3.3.1 + ... Config ID: Config_prod_VNFM + ... Applicability: none + ... Post-Conditions: none + PATCH API Version + Check HTTP Response Status Code Is 405 + +DELETE API Version - Method not implemented + [Documentation] Test ID: 7.3.8.1.5 + ... Test title: DELETE API Version - Method not implemented + ... Test objective: The objective is to test that DELETE method is not implemented + ... Pre-conditions: none + ... Reference: Clause 9.3.3.3.5 - ETSI GS NFV-SOL 013 v3.3.1 + ... Config ID: Config_prod_VNFM + ... Applicability: none + ... Post-Conditions: none + DELETE API Version + Check HTTP Response Status Code Is 405 + +POST API Version with apiMajorVerion - Method not implemented + [Documentation] Test ID: 7.3.8.1.6 + ... Test title: POST API version with apiMajorVerion - Method not implemented + ... Test objective: The objective is to test that POST method is not implemented + ... Pre-conditions: none + ... Reference: Clause 9.3.3.3.1 - ETSI GS NFV-SOL 013 v3.3.1 + ... Config ID: Config_prod_VNFM + ... Applicability: none + ... Post-Conditions: none + POST API Version + Check HTTP Response Status Code Is 405 + +GET API Version with apiMajorVerion + [Documentation] Test ID: 7.3.8.1.7 + ... Test title: GET API Version with apiMajorVerion + ... Test objective: The objective is to test that GET method successfully return ApiVersionInformation + ... Pre-conditions: none + ... Reference: Clause 9.3.3.3.2 - ETSI GS NFV-SOL 013 v3.3.1 + ... Config ID: Config_prod_VNFM + ... Applicability: none + ... Post-Conditions: none + GET API Version + Check HTTP Response Status Code Is 200 + Check HTTP Response Body Json Schema Is ApiVersionInformation + +PUT API Version with apiMajorVerion - Method not implemented + [Documentation] Test ID: 7.3.8.1.8 + ... Test title: PUT API Version with apiMajorVerion - Method not implemented + ... Test objective: The objective is to test that PUT method is not implemented + ... Pre-conditions: none + ... Reference: Clause 9.3.3.3.3 - ETSI GS NFV-SOL 013 v3.3.1 + ... Config ID: Config_prod_VNFM + ... Applicability: none + ... Post-Conditions: none + PUT API Version + Check HTTP Response Status Code Is 405 + +PATCH API Version with apiMajorVerion - Method not implemented + [Documentation] Test ID: 7.3.8.1.9 + ... Test title: PATCH API Version with apiMajorVerion - Method not implemented + ... Test objective: The objective is to test that PATCH method is not implemented + ... Pre-conditions: none + ... Reference: Clause 9.3.3.3.4 - ETSI GS NFV-SOL 013 v3.3.1 + ... Config ID: Config_prod_VNFM + ... Applicability: none + ... Post-Conditions: none + PATCH API Version + Check HTTP Response Status Code Is 405 + +DELETE API Version with apiMajorVerion - Method not implemented + [Documentation] Test ID: 7.3.8.1.10 + ... Test title: DELETE API Version with apiMajorVerion - Method not implemented + ... Test objective: The objective is to test that DELETE method is not implemented + ... Pre-conditions: none + ... Reference: Clause 9.3.3.3.5 - ETSI GS NFV-SOL 013 v3.3.1 + ... Config ID: Config_prod_VNFM + ... Applicability: none + ... Post-Conditions: none + DELETE API Version + Check HTTP Response Status Code Is 405 \ No newline at end of file diff --git a/SOL003/VNFSnapshotPackageManagement-API/IndividualVNFSnapshotPackage.robot b/SOL003/VNFSnapshotPackageManagement-API/IndividualVNFSnapshotPackage.robot new file mode 100644 index 000000000..36d951061 --- /dev/null +++ b/SOL003/VNFSnapshotPackageManagement-API/IndividualVNFSnapshotPackage.robot @@ -0,0 +1,77 @@ +*** Settings *** +Resource VnfSnapshotPackageManagementKeywords.robot + +*** Test Cases *** +POST Individual VNF Snapshot Package - Method not implemented + [Documentation] Test ID: 7.3.8.3.1 + ... Test title: POST Individual VNF Snapshot Package - Method not implemented + ... Test objective: The objective is to test that POST method is not implemented + ... Pre-conditions: none + ... Reference: Clause 12.4.3.3.1 - ETSI GS NFV-SOL 003 [1] v3.3.1 + ... Config ID: Config_prod_VNFM + ... Applicability: none + ... Post-Conditions: none + POST individual VNF Snapshot Package + Check HTTP Response Status Code Is 405 + +GET Information about an individual VNF Snapshot Package - SUCCESSFUL + [Documentation] Test ID: 7.3.8.3.2 + ... Test title: GET Information about an individual VNF Snapshot Package - SUCCESSFUL + ... Test objective: The objective is to create a new VNF Snapshot Package resource + ... Pre-conditions: none + ... Reference: Clause 12.4.3.3.2 - ETSI GS NFV-SOL 003 [1] v3.3.1 + ... Config ID: Config_prod_VNFM + ... Applicability: none + ... Post-Conditions: none + GET individual VNF Snapshot Package + Check HTTP Response Status Code Is 200 + Check HTTP Response Body Json Schema Is VnfSnapshotPkgInfo + +GET Information about an individual VNF Snapshot Package - NOT FOUND + [Documentation] Test ID: 7.3.8.3.3 + ... Test title: GET Information about an individual VNF Snapshot Package - NOT FOUND + ... Test objective: The objective is to test that the retrieval of individual VNF Snapshot Package fails when using an invalid resource identifier. + ... Pre-conditions: At least one individual VNF Snapshot Package is available in the NFV-MANO. + ... Reference: Clause 12.4.3.3.2 - ETSI GS NFV-SOL 003 [1] v3.3.1 + ... Config ID: Config_prod_NFV-MANO + ... Applicability: none + ... Post-Conditions: none + GET Individual VNF Snapshot Package with Invalid URI + Check HTTP Response Status Code Is 404 + Check HTTP Response Body Json Schema Is ProblemDetails + +PUT Individual VNF Snapshot Package - Method not implemented + [Documentation] Test ID: 7.3.8.3.4 + ... Test title: PUT Individual VNF Snapshot Package - Method not implemented + ... Test objective: The objective is to test that PUT method is not implemented + ... Pre-conditions: none + ... Reference: Clause 12.4.3.3.3 - ETSI GS NFV-SOL 003 [1] v3.3.1 + ... Config ID: Config_prod_VNFM + ... Applicability: none + ... Post-Conditions: VNF Snapshot Package not modified + PUT individual VNF Snapshot Package + Check HTTP Response Status Code Is 405 + +PATCH Individual VNF Snapshot Package - Method Not implemented + [Documentation] Test ID: 7.3.8.3.5 + ... Test title: PATCH Individual VNF Snapshot Package + ... Test objective: The objective is to test that PATCH method is not implemented + ... Pre-conditions: none + ... Reference: Clause 12.4.3.3.4 - ETSI GS NFV-SOL 003 [1] v3.3.1 + ... Config ID: Config_prod_VNFM + ... Applicability: none + ... Post-Conditions: VNF Snapshot Package modified + PATCH individual VNF Snapshot Package + Check HTTP Response Status Code Is 405 + +DELETE Individual VNF Snapshot Package - Method Not implemented + [Documentation] Test ID: 7.3.8.3.6 + ... Test title: DELETE Individual VNF Snapshot Package - Method Not implemented + ... Test objective: The objective is to test that DELETE method is not implemented + ... Pre-conditions: none + ... Reference: Clause 12.4.3.3.5 - ETSI GS NFV-SOL 003 [1] v3.3.1 + ... Config ID: Config_prod_VNFM + ... Applicability: none + ... Post-Conditions: VNF Snapshot Package deleted + DELETE individual VNF Snapshot Package + Check HTTP Response Status Code Is 405 \ No newline at end of file diff --git a/SOL003/VNFSnapshotPackageManagement-API/IndividualVNFSnapshotPackageArtifact.robot b/SOL003/VNFSnapshotPackageManagement-API/IndividualVNFSnapshotPackageArtifact.robot new file mode 100644 index 000000000..224459059 --- /dev/null +++ b/SOL003/VNFSnapshotPackageManagement-API/IndividualVNFSnapshotPackageArtifact.robot @@ -0,0 +1,115 @@ +*** Settings *** +Resource VnfSnapshotPackageManagementKeywords.robot + +*** Test Cases *** +POST Individual VNF Snapshot Package Artifact - Method not implemented + [Documentation] Test ID: 7.3.8.5.1 + ... Test title: POST Individual VNF Snapshot Package Artifact - Method not implemented + ... Test objective: The objective is to test that POST method is not implemented + ... Pre-conditions: none + ... Reference: Clause 12.4.5.3.1 - ETSI GS NFV-SOL 003 [1] v3.3.1 + ... Config ID: Config_prod_VNFM + ... Applicability: none + ... Post-Conditions: none + POST Individual VNF Snapshot Package Artifact + Check HTTP Response Status Code Is 405 + +GET Individual VNF Snapshot Package Artifact - Complete File + [Documentation] Test ID: 7.3.8.5.2 + ... Test title: GET Information about an individual VNF Snapshot Package - Complete File + ... Test objective: The objective is to fetch the whole content of a VNF snapshot package using GET method. + ... Pre-conditions: none + ... Reference: Clause 12.4.5.3.2 - ETSI GS NFV-SOL 003 [1] v3.3.1 + ... Config ID: Config_prod_VNFM + ... Applicability: none + ... Post-Conditions: none + GET Individual VNF Snapshot Package Artifact - Complete + Check HTTP Response Status Code Is 200 + Check HTTP Content-Type Header Is Set For Package Artifact + +GET Individual VNF Snapshot Package Artifact - Partial Content + [Documentation] Test ID: 7.3.8.5.3 + ... Test title: GET Individual VNF Snapshot Package Artifact - Partial Content + ... Test objective: The objective is to fetch partial content of a VNF snapshot package by sending a range request using GET method. + ... Pre-conditions: none + ... Reference: Clause 12.4.5.3.2 - ETSI GS NFV-SOL 003 [1] v3.3.1 + ... Config ID: Config_prod_VNFM + ... Applicability: NFVO supports range requests + ... Post-Conditions: none + GET Individual VNF Snapshot Package Artifact - Range Request + Check HTTP Response Status Code Is 206 + Check HTTP Content-Type Header Is Set For Package Artifact + Check HTTP Content-Range Header Is Set + +GET Individual VNF Snapshot Package Artifact - Range Request Not Supported + [Documentation] Test ID: 7.3.8.5.4 + ... Test title: GET Information about an individual VNF Snapshot Package - Range Request Not Supported + ... Test objective: The objective is to test that the whole content of a VNF snapshot package is delivered even with a range request when NFVO does not support range requests. + ... Pre-conditions: none + ... Reference: Clause 12.4.5.3.2 - ETSI GS NFV-SOL 003 [1] v3.3.1 + ... Config ID: Config_prod_VNFM + ... Applicability: NFVO does not support range requests + ... Post-Conditions: none + GET Individual VNF Snapshot Package Artifact - Range Request + Check HTTP Response Status Code Is 200 + Check HTTP Content-Type Header Is Set For Package Artifact + +GET Individual VNF Snapshot Package Artifact - Range Not Satisfiable + [Documentation] Test ID: 7.3.8.5.5 + ... Test title: GET Information about an individual VNF Snapshot Package - Range Not Satisfiable + ... Test objective: The objective is to test that an error is returned when the byte range passed in the "Range" header does not match any available byte range in the VNF snapshot package file. + ... Pre-conditions: none + ... Reference: Clause 12.4.5.3.2 - ETSI GS NFV-SOL 003 [1] v3.3.1 + ... Config ID: Config_prod_VNFM + ... Applicability: NFVO supports range requests + ... Post-Conditions: none + GET Individual VNF Snapshot Package Artifact - Invalid Range + Check HTTP Response Status Code Is 416 + +GET Individual VNF Snapshot Package Artifact - Conflict + [Documentation] Test ID: 7.3.8.5.6 + ... Test title: GET Information about an individual VNF Snapshot Package - Conflict + ... Test objective: The objective is to test that an error is returned when the "state" of the VNF snapshot package has a value different from "AVAILABLE". + ... Pre-conditions: none + ... Reference: Clause 12.4.5.3.2 - ETSI GS NFV-SOL 003 [1] v3.3.1 + ... Config ID: Config_prod_VNFM + ... Applicability: The "state" of the VNF snapshot package has a value different from "AVAILABLE". + ... Post-Conditions: none + GET Individual VNF Snapshot Package Artifact - Not Available + Check HTTP Response Status Code Is 409 + +PUT Individual VNF Snapshot Package Artifact - Method not implemented + [Documentation] Test ID: 7.3.8.5.7 + ... Test title: PUT Individual VNF Snapshot Package Artifact - Method not implemented + ... Test objective: The objective is to test that PUT method is not implemented + ... Pre-conditions: none + ... Reference: Clause 12.4.5.3.3 - ETSI GS NFV-SOL 003 [1] v3.3.1 + ... Config ID: Config_prod_VNFM + ... Applicability: none + ... Post-Conditions: VNF Snapshot Package not modified + PUT Individual VNF Snapshot Package Artifact + Check HTTP Response Status Code Is 405 + +PATCH Individual VNF Snapshot Package Artifact - Method Not implemented + [Documentation] Test ID: 7.3.8.5.8 + ... Test title: PATCH Individual VNF Snapshot Package Artifact + ... Test objective: The objective is to test that PATCH method is not implemented + ... Pre-conditions: none + ... Reference: Clause 12.4.5.3.4 - ETSI GS NFV-SOL 003 [1] v3.3.1 + ... Config ID: Config_prod_VNFM + ... Applicability: none + ... Post-Conditions: none + PATCH Individual VNF Snapshot Package Artifact + Check HTTP Response Status Code Is 405 + +DELETE Individual VNF Snapshot Package Artifact - Method Not implemented + [Documentation] Test ID: 7.3.8.5.9 + ... Test title: DELETE Individual VNF Snapshot Package Artifact - Method Not implemented + ... Test objective: The objective is to test that DELETE method is not implemented + ... Pre-conditions: none + ... Reference: Clause 12.4.5.3.5 - ETSI GS NFV-SOL 003 [1] v3.3.1 + ... Config ID: Config_prod_VNFM + ... Applicability: none + ... Post-Conditions: none + DELETE Individual VNF Snapshot Package Artifact + Check HTTP Response Status Code Is 405 \ No newline at end of file diff --git a/SOL003/VNFSnapshotPackageManagement-API/VNFSnapshotPackageContent.robot b/SOL003/VNFSnapshotPackageManagement-API/VNFSnapshotPackageContent.robot new file mode 100644 index 000000000..8271d7489 --- /dev/null +++ b/SOL003/VNFSnapshotPackageManagement-API/VNFSnapshotPackageContent.robot @@ -0,0 +1,115 @@ +*** Settings *** +Resource VnfSnapshotPackageManagementKeywords.robot + +*** Test Cases *** +POST VNF Snapshot Package Content - Method not implemented + [Documentation] Test ID: 7.3.8.4.1 + ... Test title: POST VNF Snapshot Package Content - Method not implemented + ... Test objective: The objective is to test that POST method is not implemented + ... Pre-conditions: none + ... Reference: Clause 12.4.4.3.1 - ETSI GS NFV-SOL 003 [1] v3.3.1 + ... Config ID: Config_prod_VNFM + ... Applicability: none + ... Post-Conditions: none + POST VNF Snapshot Package Content + Check HTTP Response Status Code Is 405 + +GET VNF Snapshot Package Content - Complete File + [Documentation] Test ID: 7.3.8.4.2 + ... Test title: GET Information about an individual VNF Snapshot Package - Complete File + ... Test objective: The objective is to fetch the whole content of a VNF snapshot package using GET method. + ... Pre-conditions: none + ... Reference: Clause 12.4.4.3.2 - ETSI GS NFV-SOL 003 [1] v3.3.1 + ... Config ID: Config_prod_VNFM + ... Applicability: none + ... Post-Conditions: none + GET VNF Snapshot Package Content - Complete + Check HTTP Response Status Code Is 200 + Check HTTP Content-Type Header Is Set For Package Content + +GET VNF Snapshot Package Content - Partial Content + [Documentation] Test ID: 7.3.8.4.3 + ... Test title: GET VNF Snapshot Package Content - Partial Content + ... Test objective: The objective is to fetch partial content of a VNF snapshot package by sending a range request using GET method. + ... Pre-conditions: none + ... Reference: Clause 12.4.4.3.2 - ETSI GS NFV-SOL 003 [1] v3.3.1 + ... Config ID: Config_prod_VNFM + ... Applicability: NFVO supports range requests + ... Post-Conditions: none + GET VNF Snapshot Package Content - Range Request + Check HTTP Response Status Code Is 206 + Check HTTP Content-Type Header Is Set For Package Content + Check HTTP Content-Range Header Is Set + +GET VNF Snapshot Package Content - Range Request Not Supported + [Documentation] Test ID: 7.3.8.4.4 + ... Test title: GET Information about an individual VNF Snapshot Package - Range Request Not Supported + ... Test objective: The objective is to test that the whole content of a VNF snapshot package is delivered even with a range request when NFVO does not support range requests. + ... Pre-conditions: none + ... Reference: Clause 12.4.4.3.2 - ETSI GS NFV-SOL 003 [1] v3.3.1 + ... Config ID: Config_prod_VNFM + ... Applicability: NFVO does not support range requests + ... Post-Conditions: none + GET VNF Snapshot Package Content - Range Request + Check HTTP Response Status Code Is 200 + Check HTTP Content-Type Header Is Set For Package Content + +GET VNF Snapshot Package Content - Range Not Satisfiable + [Documentation] Test ID: 7.3.8.4.5 + ... Test title: GET Information about an individual VNF Snapshot Package - Range Not Satisfiable + ... Test objective: The objective is to test that an error is returned when the byte range passed in the "Range" header does not match any available byte range in the VNF snapshot package file. + ... Pre-conditions: none + ... Reference: Clause 12.4.4.3.2 - ETSI GS NFV-SOL 003 [1] v3.3.1 + ... Config ID: Config_prod_VNFM + ... Applicability: NFVO supports range requests + ... Post-Conditions: none + GET VNF Snapshot Package Content - Invalid Range + Check HTTP Response Status Code Is 416 + +GET VNF Snapshot Package Content - Conflict + [Documentation] Test ID: 7.3.8.4.6 + ... Test title: GET Information about an individual VNF Snapshot Package - Conflict + ... Test objective: The objective is to test that an error is returned when the "state" of the VNF snapshot package has a value different from "AVAILABLE". + ... Pre-conditions: none + ... Reference: Clause 12.4.4.3.2 - ETSI GS NFV-SOL 003 [1] v3.3.1 + ... Config ID: Config_prod_VNFM + ... Applicability: The "state" of the VNF snapshot package has a value different from "AVAILABLE". + ... Post-Conditions: none + GET VNF Snapshot Package Content - Not Available + Check HTTP Response Status Code Is 409 + +PUT VNF Snapshot Package Content - Method not implemented + [Documentation] Test ID: 7.3.8.4.7 + ... Test title: PUT VNF Snapshot Package Content - Method not implemented + ... Test objective: The objective is to test that PUT method is not implemented + ... Pre-conditions: none + ... Reference: Clause 12.4.4.3.3 - ETSI GS NFV-SOL 003 [1] v3.3.1 + ... Config ID: Config_prod_VNFM + ... Applicability: none + ... Post-Conditions: VNF Snapshot Package not modified + PUT VNF Snapshot Package Content + Check HTTP Response Status Code Is 405 + +PATCH VNF Snapshot Package Content - Method Not implemented + [Documentation] Test ID: 7.3.8.4.8 + ... Test title: PATCH VNF Snapshot Package Content + ... Test objective: The objective is to test that PATCH method is not implemented + ... Pre-conditions: none + ... Reference: Clause 12.4.4.3.4 - ETSI GS NFV-SOL 003 [1] v3.3.1 + ... Config ID: Config_prod_VNFM + ... Applicability: none + ... Post-Conditions: none + PATCH VNF Snapshot Package Content + Check HTTP Response Status Code Is 405 + +DELETE VNF Snapshot Package Content - Method Not implemented + [Documentation] Test ID: 7.3.8.4.9 + ... Test title: DELETE VNF Snapshot Package Content - Method Not implemented + ... Test objective: The objective is to test that DELETE method is not implemented + ... Pre-conditions: none + ... Reference: Clause 12.4.4.3.5 - ETSI GS NFV-SOL 003 [1] v3.3.1 + ... Config ID: Config_prod_VNFM + ... Applicability: none + ... Post-Conditions: none + DELETE VNF Snapshot Package Content + Check HTTP Response Status Code Is 405 \ No newline at end of file diff --git a/SOL003/VNFSnapshotPackageManagement-API/VNFSnapshotPackages.robot b/SOL003/VNFSnapshotPackageManagement-API/VNFSnapshotPackages.robot new file mode 100644 index 000000000..6a845045f --- /dev/null +++ b/SOL003/VNFSnapshotPackageManagement-API/VNFSnapshotPackages.robot @@ -0,0 +1,181 @@ +*** Settings *** +Resource VnfSnapshotPackageManagementKeywords.robot + +*** Test Cases *** +POST VNF Snapshot Packages - Method not implemented + [Documentation] Test ID: 7.3.8.2.1 + ... Test title: POST VNF Snapshot Packages - Method not implemented + ... Test objective: The objective is to test that POST method is not implemented + ... Pre-conditions: none + ... Reference: Clause 12.4.2.3.1 - ETSI GS NFV-SOL 003 [1] v3.3.1 + ... Config ID: Config_prod_VNFM + ... Applicability: none + ... Post-Conditions: none + POST VNF Snapshot Packages + Check HTTP Response Status Code Is 405 + +GET information about multiple VNF Snapshot Packages + [Documentation] Test ID: 7.3.8.2.2 + ... Test title: GET information about multiple VNF Snapshot Packages + ... Test objective: The objective is to get information about multiples VNF Snapshot Packages + ... Pre-conditions: none + ... Reference: Clause 12.4.2.3.2 - ETSI GS NFV-SOL 003 [1] v3.3.1 + ... Config ID: Config_prod_VNFM + ... Applicability: none + ... Post-Conditions: none + GET multiple VNF Snapshot Packages + Check HTTP Response Status Code Is 200 + Check HTTP Response Body Json Schema Is VnfSnapshotPkgInfos + +GET information about multiple VNF Snapshot Packages Bad Request Invalid attribute-based filtering parameters + [Documentation] Test ID: 7.3.8.2.3 + ... Test title: GET information about multiple VNF Snapshot Packages Bad Request Invalid attribute-based filtering parameters + ... Test objective: The objective is to get information about multiples VNF Snapshot Packages with Invalid attribute-based filtering parameters + ... Pre-conditions: none + ... Reference: Clause 12.4.2.3.2 - ETSI GS NFV-SOL 003 [1] v3.3.1 + ... Config ID: Config_prod_VNFM + ... Applicability: none + ... Post-Conditions: none + GET multiple VNF Snapshot Packages with bad attribute + Check HTTP Response Status Code Is 400 + Check HTTP Response Body Json Schema Is ProblemDetails + +GET information about multiple VNF Snapshot Packages Bad Request Invalid attribute selector + [Documentation] Test ID: 7.3.8.2.4 + ... Test title: GET information about multiple VNF Snapshot Packages Bad Request Invalid attribute selector + ... Test objective: The objective is to get information about multiples VNF Snapshot Packages with Invalid attribute-based filtering parameters + ... Pre-conditions: none + ... Reference: Clause 12.4.2.3.2 - ETSI GS NFV-SOL 003 [1] v3.3.1 + ... Config ID: Config_prod_VNFM + ... Applicability: none + ... Post-Conditions: none + GET multiple VNF Snapshot Packages with bad filter + Check HTTP Response Status Code Is 400 + Check HTTP Response Body Json Schema Is ProblemDetails + +GET information about multiple VNF Snapshot Packages with "all_fields" attribute selector + [Documentation] Test ID: 7.3.8.2.5 + ... Test title: GET information about multiple VNF Snapshot Packages with "all_fields" attribute selector + ... Test objective: The objective is to query information about multiple VNF Snapshot Packages + ... Pre-conditions: none + ... Reference: Clause 12.4.2.3.2 - ETSI GS NFV-SOL 003 [1] v3.3.1 + ... Config ID: Config_prod_VNFM + ... Applicability: none + ... Post-Conditions: none + GET multiple VNF Snapshot Packages with all_fields attribute selector + Check HTTP Response Status Code Is 200 + Check HTTP Response Body Json Schema Is VnfSnapshotPkgInfos + +GET information about multiple VNF Snapshot Packages with "exclude_default" attribute selector + [Documentation] Test ID: 7.3.8.2.6 + ... Test title: GET information about multiple VNF Snapshot Packages with "exclude_default" attribute selector + ... Test objective: The objective is to query information about multiple VNF Snapshot Packages + ... Pre-conditions: none + ... Reference: Clause 12.4.2.3.2 - ETSI GS NFV-SOL 003 [1] v3.3.1 + ... Config ID: Config_prod_VNFM + ... Applicability: none + ... Post-Conditions: none + GET multiple VNF Snapshot Packages with exclude_default attribute selector + Check HTTP Response Status Code Is 200 + Check HTTP Response Body Json Schema Is VnfSnapshotPkgInfos + +GET information about multiple VNF Snapshot Packages with "fields" attribute selector + [Documentation] Test ID: 7.3.8.2.7 + ... Test title: GET information about multiple VNF Snapshot Packages with "fields" attribute selector + ... Test objective: The objective is to query information about multiple VNF Snapshot Packages + ... Pre-conditions: none + ... Reference: Clause 12.4.2.3.2 - ETSI GS NFV-SOL 003 [1] v3.3.1 + ... Config ID: Config_prod_VNFM + ... Applicability: none + ... Post-Conditions: none + GET multiple VNF Snapshot Packages with fields attribute selector + Check HTTP Response Status Code Is 200 + Check HTTP Response Body Json Schema Is VnfSnapshotPkgInfos + +GET information about multiple VNF Snapshot Packages with "exclude_default" and "fields" attribute selector + [Documentation] Test ID: 7.3.8.2.8 + ... Test title: GET information about multiple VNF Snapshot Packages with "exclude_default" and "fields" attribute selector + ... Test objective: The objective is to query information about multiple VNF Snapshot Packages + ... Pre-conditions: none + ... Reference: Clause 12.4.2.3.2 - ETSI GS NFV-SOL 003 [1] v3.3.1 + ... Config ID: Config_prod_VNFM + ... Applicability: none + ... Post-Conditions: none + GET multiple VNF Snapshot Packages with exclude_default and fields attribute selector + Check HTTP Response Status Code Is 200 + Check HTTP Response Body Json Schema Is VnfSnapshotPkgInfos + +GET information about multiple VNF Snapshot Packages with "exclude_fields" attribute selector + [Documentation] Test ID: 7.3.8.2.9 + ... Test title: GET information about multiple VNF Snapshot Packages with "exclude_fields" attribute selector + ... Test objective: The objective is to query information about multiple VNF Snapshot Packages + ... Pre-conditions: none + ... Reference: Clause 12.4.2.3.2 - ETSI GS NFV-SOL 003 [1] v3.3.1 + ... Config ID: Config_prod_VNFM + ... Applicability: none + ... Post-Conditions: none + GET multiple VNF Snapshot Packages with exclude_fields attribute selector + Check HTTP Response Status Code Is 200 + Check HTTP Response Body Json Schema Is VnfSnapshotPkgInfos + +GET VNF Snapshot Packages - Bad Request Response too Big + [Documentation] Test ID: 7.3.8.2.10 + ... Test title: GET VNF Snapshot Packages - Bad Request Response too Big + ... Test objective: The objective is test that the retrieval of existing VNF Snapshot Packages list fails because response is too big, and perform the JSON schema validation of the failed operation HTTP response. + ... Pre-conditions: none + ... Reference: Clause 12.4.2.3.2 - ETSI GS NFV-SOL 003 [1] v3.3.1 + ... Config ID: Config_prod_VNFM + ... Applicability: NFVO does not support paged response. + ... Post-Conditions: none + GET VNF Snapshot Packages without Paging support + Check HTTP Response Status Code Is 400 + Check HTTP Response Body Json Schema Is ProblemDetails + +GET VNF Snapshot Packages as Paged Response + [Documentation] Test ID: 7.3.8.2.11 + ... Test title: GET VNF Snapshot Packages as Paged Response + ... Test objective: The objective is to test that GET method retrieves the list of existing VNF Snapshot Packages as paged response. + ... Pre-conditions: none + ... Reference: Clause 12.4.2.3.2 - ETSI GS NFV-SOL 003 [1] v3.3.1 + ... Config ID: Config_prod_VNFM + ... Applicability: NFVO supports paged response. + ... Post-Conditions: none + GET VNF Snapshot Packages with Paging support + Check HTTP Response Status Code Is 200 + Check HTTP Response Header Contains Link + +PUT VNF Snapshot Packages - Method not implemented + [Documentation] Test ID: 7.3.8.2.12 + ... Test title: PUT VNF Snapshot Packages - Method not implemented + ... Test objective: The objective is to test that PUT method is not implemented + ... Pre-conditions: none + ... Reference: Clause 12.4.2.3.3 - ETSI GS NFV-SOL 003 [1] v3.3.1 + ... Config ID: Config_prod_VNFM + ... Applicability: none + ... Post-Conditions: none + PUT VNF Snapshot Packages + Check HTTP Response Status Code Is 405 + +PATCH VNF Snapshot Packages - Method not implemented + [Documentation] Test ID: 7.3.8.2.13 + ... Test title: PATCH VNF Snapshot Packages - Method not implemented + ... Test objective: The objective is to test that PATCH method is not implemented + ... Pre-conditions: none + ... Reference: Clause 12.4.2.3.4 - ETSI GS NFV-SOL 003 [1] v3.3.1 + ... Config ID: Config_prod_VNFM + ... Applicability: none + ... Post-Conditions: none + PATCH VNF Snapshot Packages + Check HTTP Response Status Code Is 405 + +DELETE VNF Snapshot Packages - Method not implemented + [Documentation] Test ID: 7.3.8.2.14 + ... Test title: DELETE VNF Snapshot Packages - Method not implemented + ... Test objective: The objective is to test that DELETE method is not implemented + ... Pre-conditions: none + ... Reference: Clause 12.4.2.3.5 - ETSI GS NFV-SOL 003 [1] v3.3.1 + ... Config ID: Config_prod_VNFM + ... Applicability: none + ... Post-Conditions: VNF snapshot package is not deleted + DELETE VNF Snapshot Packages + Check HTTP Response Status Code Is 405 diff --git a/SOL003/VNFSnapshotPackageManagement-API/VnfSnapshotPackageManagementKeywords.robot b/SOL003/VNFSnapshotPackageManagement-API/VnfSnapshotPackageManagementKeywords.robot new file mode 100644 index 000000000..ac4c4a0fa --- /dev/null +++ b/SOL003/VNFSnapshotPackageManagement-API/VnfSnapshotPackageManagementKeywords.robot @@ -0,0 +1,412 @@ +*** Settings *** +Resource environment/variables.txt +Library REST ${VNFM_SCHEMA}://${VNFM_HOST}:${VNFM_PORT} ssl_verify=false +Library DependencyLibrary +Library JSONLibrary +Library JSONSchemaLibrary schemas/ + +*** Keywords *** +POST API Version + Set Headers {"Accept":"${ACCEPT_JSON}"} + Run Keyword If ${AUTH_USAGE} == 1 Set Headers {"${AUTHORIZATION_HEADER}":"${AUTHORIZATION_TOKEN}"} + Post ${apiRoot}/${apiName}/api_versions + ${outputResponse}= Output response + Set Global Variable ${response} ${outputResponse} + +GET API Version + Set Headers {"Accept":"${ACCEPT_JSON}"} + Run Keyword If ${AUTH_USAGE} == 1 Set Headers {"${AUTHORIZATION_HEADER}":"${AUTHORIZATION_TOKEN}"} + Get ${apiRoot}/${apiName}/api_versions + ${outputResponse}= Output response + Set Global Variable ${response} ${outputResponse} + +PUT API Version + Set Headers {"Accept":"${ACCEPT_JSON}"} + Run Keyword If ${AUTH_USAGE} == 1 Set Headers {"${AUTHORIZATION_HEADER}":"${AUTHORIZATION_TOKEN}"} + Put ${apiRoot}/${apiName}/api_versions + ${outputResponse}= Output response + Set Global Variable ${response} ${outputResponse} + +PATCH API Version + Set Headers {"Accept":"${ACCEPT_JSON}"} + Run Keyword If ${AUTH_USAGE} == 1 Set Headers {"${AUTHORIZATION_HEADER}":"${AUTHORIZATION_TOKEN}"} + Patch ${apiRoot}/${apiName}/api_versions + ${outputResponse}= Output response + Set Global Variable ${response} ${outputResponse} + +DELETE API Version + Set Headers {"Accept":"${ACCEPT_JSON}"} + Run Keyword If ${AUTH_USAGE} == 1 Set Headers {"${AUTHORIZATION_HEADER}":"${AUTHORIZATION_TOKEN}"} + Delete ${apiRoot}/${apiName}/api_versions + ${outputResponse}= Output response + Set Global Variable ${response} ${outputResponse} + +POST API Version with apiMajorVersion + Set Headers {"Accept":"${ACCEPT_JSON}"} + Run Keyword If ${AUTH_USAGE} == 1 Set Headers {"${AUTHORIZATION_HEADER}":"${AUTHORIZATION_TOKEN}"} + Post ${apiRoot}/${apiName}/${apiMajorVersion}/api_versions + ${outputResponse}= Output response + Set Global Variable ${response} ${outputResponse} + +GET API Version with apiMajorVersion + Set Headers {"Accept":"${ACCEPT_JSON}"} + Run Keyword If ${AUTH_USAGE} == 1 Set Headers {"${AUTHORIZATION_HEADER}":"${AUTHORIZATION_TOKEN}"} + Get ${apiRoot}/${apiName}/${apiMajorVersion}/api_versions + ${outputResponse}= Output response + Set Global Variable ${response} ${outputResponse} + +PUT API Version with apiMajorVersion + Set Headers {"Accept":"${ACCEPT_JSON}"} + Run Keyword If ${AUTH_USAGE} == 1 Set Headers {"${AUTHORIZATION_HEADER}":"${AUTHORIZATION_TOKEN}"} + Put ${apiRoot}/${apiName}/${apiMajorVersion}/api_versions + ${outputResponse}= Output response + Set Global Variable ${response} ${outputResponse} + +PATCH API Version with apiMajorVersion + Set Headers {"Accept":"${ACCEPT_JSON}"} + Run Keyword If ${AUTH_USAGE} == 1 Set Headers {"${AUTHORIZATION_HEADER}":"${AUTHORIZATION_TOKEN}"} + Patch ${apiRoot}/${apiName}/${apiMajorVersion}/api_versions + ${outputResponse}= Output response + Set Global Variable ${response} ${outputResponse} + +DELETE API Version with apiMajorVersion + Set Headers {"Accept":"${ACCEPT_JSON}"} + Run Keyword If ${AUTH_USAGE} == 1 Set Headers {"${AUTHORIZATION_HEADER}":"${AUTHORIZATION_TOKEN}"} + Delete ${apiRoot}/${apiName}/${apiMajorVersion}/api_versions + ${outputResponse}= Output response + Set Global Variable ${response} ${outputResponse} + + +Check HTTP Response Status Code Is + [Arguments] ${expected_status} + Should Be Equal As Strings ${response['status']} ${expected_status} + Log Status code validated + +Check HTTP Response Body Json Schema Is + [Arguments] ${input} + ${schema} = Catenate SEPARATOR= ${input} .schema.json + Validate Json ${schema} ${response['body']} + Log Json Schema Validation OK + +POST VNF Snapshot Packages + Log Trying to perform a POST. This method should not be implemented. + Set Headers {"Accept":"${ACCEPT_JSON}"} + Set Headers {"Content-Type":"${CONTENT_TYPE_JSON}"} + Run Keyword If ${AUTH_USAGE} == 1 Set Headers {"${AUTHORIZATION_HEADER}":"${AUTHORIZATION_TOKEN}"} + Post ${apiRoot}/${apiName}/${apiMajorVersion}/vnf_snapshot_packages + ${outputResponse}= Output response + Set Global Variable ${response} ${outputResponse} + +GET multiple VNF Snapshot Packages + Log Query VNF The GET method queries information about multiple VNF Snapshot Packages. + Set Headers {"Accept":"${ACCEPT_JSON}"} + Set Headers {"Content-Type": "${CONTENT_TYPE_JSON}"} + Set Headers {"${AUTHORIZATION_HEADER}":"${AUTHORIZATION_TOKEN}"} + Get ${apiRoot}/${apiName}/${apiMajorVersion}/vnf_snapshot_packages + ${outputResponse}= Output response + Set Global Variable ${response} ${outputResponse} + +GET multiple VNF Snapshot Packages with bad attribute + Log Query VNF The GET method queries information about multiple VNF Snapshot Packages. + Set Headers {"Accept":"${ACCEPT_JSON}"} + Set Headers {"Content-Type": "${CONTENT_TYPE_JSON}"} + Set Headers {"${AUTHORIZATION_HEADER}":"${AUTHORIZATION_TOKEN}"} + GET ${apiRoot}/${apiName}/${apiMajorVersion}/vnf_snapshot_packages?attribute_not_exist=some_value + ${outputResponse}= Output response + Set Global Variable ${response} ${outputResponse} + +GET multiple VNF Snapshot Packages with bad filter + Log Query VNF The GET method queries information about multiple VNF Snapshot Packages. + Set Headers {"Accept":"${ACCEPT_JSON}"} + Set Headers {"Content-Type": "${CONTENT_TYPE_JSON}"} + Run Keyword If ${AUTH_USAGE} == 1 Set Headers {"${AUTHORIZATION_HEADER}":"${AUTHORIZATION_TOKEN}"} + GET ${apiRoot}/${apiName}/${apiMajorVersion}/vnf_snapshot_packages?fields=wrong_field + ${outputResponse}= Output response + Set Global Variable ${response} ${outputResponse} + +GET multiple VNF Snapshot Packages with all_fields attribute selector + Log Query status information about multiple VNF Snapshot Packages, using fields + Set Headers {"Accept": "${ACCEPT_JSON}"} + Run Keyword If ${AUTH_USAGE} == 1 Set Headers {"${AUTHORIZATION_HEADER}":"${AUTHORIZATION_TOKEN}"} + GET ${apiRoot}/${apiName}/${apiMajorVersion}/vnf_snapshot_packages?exclude_default + ${output}= Output response + Set Suite Variable ${response} ${output} + +GET multiple VNF Snapshot Packages with exclude_default attribute selector + Log Query status information about multiple VNF Snapshot Packages using fields + Set Headers {"Accept": "${ACCEPT_JSON}"} + Run Keyword If ${AUTH_USAGE} == 1 Set Headers {"${AUTHORIZATION_HEADER}":"${AUTHORIZATION_TOKEN}"} + GET ${apiRoot}/${apiName}/${apiMajorVersion}/vnf_snapshot_packages?exclude_default + ${output}= Output response + Set Suite Variable ${response} ${output} + +GET multiple VNF Snapshot Packages with fields attribute selector + Log Query status information about multiple VNF Snapshot Packages, using fields + Set Headers {"Accept": "${ACCEPT_JSON}"} + Run Keyword If ${AUTH_USAGE} == 1 Set Headers {"${AUTHORIZATION_HEADER}":"${AUTHORIZATION_TOKEN}"} + GET ${apiRoot}/${apiName}/${apiMajorVersion}/vnf_snapshot_packages?fields=${fields} + ${output}= Output response + Set Suite Variable ${response} ${output} + +GET multiple VNF Snapshot Packages with exclude_default and fields attribute selector + Log Query status information about multiple VNF Snapshot Packages, using fields + Set Headers {"Accept": "${ACCEPT_JSON}"} + Run Keyword If ${AUTH_USAGE} == 1 Set Headers {"${AUTHORIZATION_HEADER}":"${AUTHORIZATION_TOKEN}"} + GET ${apiRoot}/${apiName}/${apiMajorVersion}/vnf_snapshot_packages?fields=${fields}&exclude_default + ${output}= Output response + Set Suite Variable ${response} ${output} + +GET multiple VNF Snapshot Packages with exclude_fields attribute selector + Log Query status information about multiple VNF Snapshot Packages, using fields + Set Headers {"Accept": "${ACCEPT_JSON}"} + Run Keyword If ${AUTH_USAGE} == 1 Set Headers {"${AUTHORIZATION_HEADER}":"${AUTHORIZATION_TOKEN}"} + GET ${apiRoot}/${apiName}/${apiMajorVersion}/vnf_snapshot_packages?exclude_fields=${fields} + ${output}= Output response + Set Suite Variable ${response} ${output} + +GET VNF Snapshot Packages without Paging support + Run Keyword If ${PAGING_SUPPORTED} == 0 GET multiple VNF Snapshot Packages + +GET VNF Snapshot Packages with Paging support + Run Keyword If ${PAGING_SUPPORTED} == 1 GET multiple VNF Snapshot Packages + +Check HTTP Response Header Contains Link + ${linkURL}= Get Value From Json ${response['headers']} $..Link + Should Not Be Empty ${linkURL} + +PUT VNF Snapshot Packages + log Trying to perform a PUT. This method should not be implemented + Set Headers {"Accept":"${ACCEPT_JSON}"} + Set Headers {"Content-Type": "${CONTENT_TYPE_JSON}"} + Run Keyword If ${AUTH_USAGE} == 1 Set Headers {"${AUTHORIZATION_HEADER}":"${AUTHORIZATION_TOKEN}"} + Put ${apiRoot}/${apiName}/${apiMajorVersion}/vnf_snapshot_packages + ${outputResponse}= Output response + Set Global Variable ${response} ${outputResponse} + +PATCH VNF Snapshot Packages + Log Trying to perform a PATCH. This method should not be implemented + Set Headers {"Accept":"${ACCEPT_JSON}"} + Patch ${apiRoot}/${apiName}/${apiMajorVersion}/vnf_snapshot_packages + ${outputResponse}= Output response + Set Global Variable ${response} ${outputResponse} + +DELETE VNF Snapshot Packages + Log Trying to perform a DELETE. This method should not be implemented + Run Keyword If ${AUTH_USAGE} == 1 Set Headers {"${AUTHORIZATION_HEADER}":"${AUTHORIZATION_TOKEN}"} + Delete ${apiRoot}/${apiName}/${apiMajorVersion}/vnf_snapshot_packages + ${outputResponse}= Output response + Set Global Variable ${response} ${outputResponse} + +POST individual VNF Snapshot Package + log Trying to perform a POST. This method should not be implemented + Set Headers {"Accept":"${ACCEPT_JSON}"} + Set Headers {"Content-Type": "${CONTENT_TYPE_JSON}"} + Run Keyword If ${AUTH_USAGE} == 1 Set Headers {"${AUTHORIZATION_HEADER}":"${AUTHORIZATION_TOKEN}"} + Post ${apiRoot}/${apiName}/${apiMajorVersion}/vnf_snapshot_packages/${vnfSnapshotPkgId} + ${outputResponse}= Output response + Set Global Variable ${response} ${outputResponse} + +GET individual VNF Snapshot Package + log Trying to get information about an individual VNF Snapshot Package + Set Headers {"Accept":"${ACCEPT_JSON}"} + Set Headers {"Content-Type": "${CONTENT_TYPE_JSON}"} + Run Keyword If ${AUTH_USAGE} == 1 Set Headers {"${AUTHORIZATION_HEADER}":"${AUTHORIZATION_TOKEN}"} + Get ${apiRoot}/${apiName}/${apiMajorVersion}/vnf_snapshot_packages/${vnfSnapshotPkgId} + ${outputResponse}= Output response + Set Global Variable ${response} ${outputResponse} + +GET individual VNF Snapshot Package with invalid URI + log Trying to get information about an individual VNF Snapshot Package + Set Headers {"Accept":"${ACCEPT_JSON}"} + Set Headers {"Content-Type": "${CONTENT_TYPE_JSON}"} + Run Keyword If ${AUTH_USAGE} == 1 Set Headers {"${AUTHORIZATION_HEADER}":"${AUTHORIZATION_TOKEN}"} + Get ${apiRoot}/${apiName}/${apiMajorVersion}/vnf_snapshot_packages/${invalidVnfSnapshotInfoId} + ${outputResponse}= Output response + Set Global Variable ${response} ${outputResponse} + +PUT individual VNF Snapshot Package + log Trying to perform a PUT. This method should not be implemented + Set Headers {"Accept":"${ACCEPT_JSON}"} + Set Headers {"Content-Type": "${CONTENT_TYPE_JSON}"} + Run Keyword If ${AUTH_USAGE} == 1 Set Headers {"${AUTHORIZATION_HEADER}":"${AUTHORIZATION_TOKEN}"} + Put ${apiRoot}/${apiName}/${apiMajorVersion}/vnf_snapshot_packages/${vnfSnapshotPkgId} + ${outputResponse}= Output response + Set Global Variable ${response} ${outputResponse} + +PATCH individual VNF Snapshot Package + log Trying to perform a PATCH. This method should not be implemented + Set Headers {"Accept":"${ACCEPT_JSON}"} + Set Headers {"Content-Type": "${CONTENT_TYPE_JSON}"} + Run Keyword If ${AUTH_USAGE} == 1 Set Headers {"${AUTHORIZATION_HEADER}":"${AUTHORIZATION_TOKEN}"} + Patch ${apiRoot}/${apiName}/${apiMajorVersion}/vnf_snapshot_packages/${vnfSnapshotPkgId} + ${outputResponse}= Output response + Set Global Variable ${response} ${outputResponse} + +DELETE individual VNF Snapshot Package + log Trying to perform a DELETE. This method should not be implemented + Set Headers {"Accept":"${ACCEPT_JSON}"} + Run Keyword If ${AUTH_USAGE} == 1 Set Headers {"${AUTHORIZATION_HEADER}":"${AUTHORIZATION_TOKEN}"} + Patch ${apiRoot}/${apiName}/${apiMajorVersion}/vnf_snapshot_packages/${vnfSnapshotPkgId} + ${outputResponse}= Output response + Set Global Variable ${response} ${outputResponse} + +POST VNF Snapshot Package Content + log Trying to perform a POST. This method should not be implemented + Set Headers {"Accept":"${ACCEPT_ZIP}"} + Set Headers {"Content-Type": "${CONTENT_TYPE_JSON}"} + Run Keyword If ${AUTH_USAGE} == 1 Set Headers {"${AUTHORIZATION_HEADER}":"${AUTHORIZATION_TOKEN}"} + Post ${apiRoot}/${apiName}/${apiMajorVersion}/vnf_snapshot_packages/${vnfSnapshotPkgId}/package_content + ${outputResponse}= Output response + Set Global Variable ${response} ${outputResponse} + +GET VNF Snapshot Package Content - Complete + log Trying to fetch the complete contents of VNF Snapshot Package + Set Headers {"Accept":"${ACCEPT_ZIP}"} + Run Keyword If ${AUTH_USAGE} == 1 Set Headers {"${AUTHORIZATION_HEADER}":"${AUTHORIZATION_TOKEN}"} + Get ${apiRoot}/${apiName}/${apiMajorVersion}/vnf_snapshot_packages/${vnfSnapshotPkgId}/package_content + ${outputResponse}= Output response + Set Global Variable ${response} ${outputResponse} + +GET VNF Snapshot Package Content - Range Request + Pass Execution If ${NFVO_RANGE_OK} == 0 Skipping this test as NFVO is not able to handle partial Requests. + log Trying to get information about an individual VNF Snapshot Package using a range request + Set Headers {"Accept":"${ACCEPT_ZIP}"} + Set Headers {"Range":"${range}"} + Run Keyword If ${AUTH_USAGE} == 1 Set Headers {"${AUTHORIZATION_HEADER}":"${AUTHORIZATION_TOKEN}"} + Get ${apiRoot}/${apiName}/${apiMajorVersion}/vnf_snapshot_packages/${vnfSnapshotPkgId}/package_content + ${outputResponse}= Output response + Set Global Variable ${response} ${outputResponse} + +GET VNF Snapshot Package Content - Invalid Range + Pass Execution If ${NFVO_RANGE_OK} == 0 Skipping this test as NFVO is not able to handle partial Requests. + log Trying to get information about an individual VNF Snapshot Package with invalid range + Set Headers {"Accept":"${ACCEPT_ZIP}"} + Set Headers {"Range":"${erroneousRange}"} + Run Keyword If ${AUTH_USAGE} == 1 Set Headers {"${AUTHORIZATION_HEADER}":"${AUTHORIZATION_TOKEN}"} + Get ${apiRoot}/${apiName}/${apiMajorVersion}/vnf_snapshot_packages/${vnfSnapshotPkgId}/package_content + ${outputResponse}= Output response + Set Global Variable ${response} ${outputResponse} + +GET VNF Snapshot Package Content - Not Available + Log Trying to fetch the contents of a VNF Snapshot Package which is not in AVAILABLE state + Set Headers {"Accept":"${ACCEPT_ZIP}"} + Run Keyword If ${AUTH_USAGE} == 1 Set Headers {"${AUTHORIZATION_HEADER}":"${AUTHORIZATION_TOKEN}"} + Get ${apiRoot}/${apiName}/${apiMajorVersion}/vnf_snapshot_packages/${vnfSnapshotPkgId_notInAvailableState}/package_content + ${outputResponse}= Output response + Set Global Variable ${response} ${outputResponse} + +Check HTTP Content-Type Header Is Set For Package Content + Log Check Content-Type HTTP Header + Should Contain ${response['headers']} Content-Type + Should Be Equal As Strings ${response['headers']['Content-Type']} ${CONTENT_TYPE_ZIP} + Log Content type validated + +Check HTTP Content-Range Header Is Set + Log Check Content-Range HTTP Header + Should Contain ${response['headers']} Content-Range + Should Be Equal As Strings ${response['headers']['Content-Range']} ${range} + Log Header Content-Range is present + +PUT VNF Snapshot Package Content + log Trying to perform a PUT. This method should not be implemented + Set Headers {"Accept":"${ACCEPT_ZIP}"} + Set Headers {"Content-Type": "${CONTENT_TYPE_ZIP}"} + Run Keyword If ${AUTH_USAGE} == 1 Set Headers {"${AUTHORIZATION_HEADER}":"${AUTHORIZATION_TOKEN}"} + Put ${apiRoot}/${apiName}/${apiMajorVersion}/vnf_snapshot_packages/${vnfSnapshotPkgId}/package_content + ${outputResponse}= Output response + Set Global Variable ${response} ${outputResponse} + +PATCH VNF Snapshot Package Content + log Trying to perform a PATCH. This method should not be implemented + Set Headers {"Accept":"${ACCEPT_ZIP}"} + Set Headers {"Content-Type": "${CONTENT_TYPE_ZIP}"} + Run Keyword If ${AUTH_USAGE} == 1 Set Headers {"${AUTHORIZATION_HEADER}":"${AUTHORIZATION_TOKEN}"} + Patch ${apiRoot}/${apiName}/${apiMajorVersion}/vnf_snapshot_packages/${vnfSnapshotPkgId}/package_content + ${outputResponse}= Output response + Set Global Variable ${response} ${outputResponse} + +DELETE VNF Snapshot Package Content + log Trying to perform a DELETE. This method should not be implemented + Set Headers {"Accept":"${ACCEPT_ZIP}"} + Run Keyword If ${AUTH_USAGE} == 1 Set Headers {"${AUTHORIZATION_HEADER}":"${AUTHORIZATION_TOKEN}"} + Patch ${apiRoot}/${apiName}/${apiMajorVersion}/vnf_snapshot_packages/${vnfSnapshotPkgId}/package_content + ${outputResponse}= Output response + Set Global Variable ${response} ${outputResponse} + +POST Individual VNF Snapshot Package Artifact + log Trying to perform a POST. This method should not be implemented + Set Headers {"Accept":"${ACCEPT_OCTET}"} + Set Headers {"Content-Type": "${CONTENT_TYPE_OCTET}"} + Run Keyword If ${AUTH_USAGE} == 1 Set Headers {"${AUTHORIZATION_HEADER}":"${AUTHORIZATION_TOKEN}"} + Post ${apiRoot}/${apiName}/${apiMajorVersion}/vnf_snapshot_packages/${vnfSnapshotPkgId}/artifacts/${artifactPath} + ${outputResponse}= Output response + Set Global Variable ${response} ${outputResponse} + +GET Individual VNF Snapshot Package Artifact - Complete + log Trying to fetch the complete contents of an individual VNF Snapshot Package artifact + Set Headers {"Accept":"${ACCEPT_OCTET}"} + Run Keyword If ${AUTH_USAGE} == 1 Set Headers {"${AUTHORIZATION_HEADER}":"${AUTHORIZATION_TOKEN}"} + Get ${apiRoot}/${apiName}/${apiMajorVersion}/vnf_snapshot_packages/${vnfSnapshotPkgId}/artifacts/${artifactPath} + ${outputResponse}= Output response + Set Global Variable ${response} ${outputResponse} + +GET Individual VNF Snapshot Package Artifact - Range Request + Pass Execution If ${NFVO_RANGE_OK} == 0 Skipping this test as NFVO is not able to handle partial Requests. + log Trying to get information about an individual VNF Snapshot Package artifact using a range request + Set Headers {"Accept":"${ACCEPT_OCTET}"} + Set Headers {"Range":"${range}"} + Run Keyword If ${AUTH_USAGE} == 1 Set Headers {"${AUTHORIZATION_HEADER}":"${AUTHORIZATION_TOKEN}"} + Get ${apiRoot}/${apiName}/${apiMajorVersion}/vnf_snapshot_packages/${vnfSnapshotPkgId}/artifacts/${artifactPath} + ${outputResponse}= Output response + Set Global Variable ${response} ${outputResponse} + +GET Individual VNF Snapshot Package Artifact - Invalid Range + Pass Execution If ${NFVO_RANGE_OK} == 0 Skipping this test as NFVO is not able to handle partial Requests. + log Trying to get information about an individual VNF Snapshot Package artifact with invalid range + Set Headers {"Accept":"${CONTENT_TYPE_OCTET}"} + Set Headers {"Range":"${erroneousRange}"} + Run Keyword If ${AUTH_USAGE} == 1 Set Headers {"${AUTHORIZATION_HEADER}":"${AUTHORIZATION_TOKEN}"} + Get ${apiRoot}/${apiName}/${apiMajorVersion}/vnf_snapshot_packages/${vnfSnapshotPkgId}/artifacts/${artifactPath} + ${outputResponse}= Output response + Set Global Variable ${response} ${outputResponse} + +GET Individual VNF Snapshot Package Artifact - Not Available + Log Trying to get information about an individual artifact of a VNF Snapshot Package which is not in AVAILABLE state + Set Headers {"Accept":"${ACCEPT_OCTET}"} + Run Keyword If ${AUTH_USAGE} == 1 Set Headers {"${AUTHORIZATION_HEADER}":"${AUTHORIZATION_TOKEN}"} + Get ${apiRoot}/${apiName}/${apiMajorVersion}/vnf_snapshot_packages/${vnfSnapshotPkgId_notInAvailableState}/artifacts/${artifactPath} + ${outputResponse}= Output response + Set Global Variable ${response} ${outputResponse} + +PUT Individual VNF Snapshot Package Artifact + log Trying to perform a PUT. This method should not be implemented + Set Headers {"Accept":"${ACCEPT_OCTET}"} + Set Headers {"Content-Type": "${CONTENT_TYPE_OCTET}"} + Run Keyword If ${AUTH_USAGE} == 1 Set Headers {"${AUTHORIZATION_HEADER}":"${AUTHORIZATION_TOKEN}"} + Put ${apiRoot}/${apiName}/${apiMajorVersion}/vnf_snapshot_packages/${vnfSnapshotPkgId}/artifacts/${artifactPath} + ${outputResponse}= Output response + Set Global Variable ${response} ${outputResponse} + +PATCH Individual VNF Snapshot Package Artifact + log Trying to perform a PATCH. This method should not be implemented + Set Headers {"Accept":"${ACCEPT_OCTET}"} + Set Headers {"Content-Type": "${CONTENT_TYPE_OCTET}"} + Run Keyword If ${AUTH_USAGE} == 1 Set Headers {"${AUTHORIZATION_HEADER}":"${AUTHORIZATION_TOKEN}"} + Patch ${apiRoot}/${apiName}/${apiMajorVersion}/vnf_snapshot_packages/${vnfSnapshotPkgId}/artifacts/${artifactPath} + ${outputResponse}= Output response + Set Global Variable ${response} ${outputResponse} + +DELETE Individual VNF Snapshot Package Artifact + log Trying to perform a DELETE. This method should not be implemented + Set Headers {"Accept":"${ACCEPT_OCTET}"} + Run Keyword If ${AUTH_USAGE} == 1 Set Headers {"${AUTHORIZATION_HEADER}":"${AUTHORIZATION_TOKEN}"} + Patch ${apiRoot}/${apiName}/${apiMajorVersion}/vnf_snapshot_packages/${vnfSnapshotPkgId}/artifacts/${artifactPath} + ${outputResponse}= Output response + Set Global Variable ${response} ${outputResponse} + +Check HTTP Content-Type Header Is Set For Package Artifact + Log Check Content-Type HTTP Header + Should Contain ${response['headers']} Content-Type + Should Be Equal As Strings ${response['headers']['Content-Type']} ${CONTENT_TYPE_OCTET} + Log Content type validated + diff --git a/SOL003/VNFSnapshotPackageManagement-API/environment/variables.txt b/SOL003/VNFSnapshotPackageManagement-API/environment/variables.txt new file mode 100644 index 000000000..845607daf --- /dev/null +++ b/SOL003/VNFSnapshotPackageManagement-API/environment/variables.txt @@ -0,0 +1,98 @@ +*** Variables *** +${NFVO_HOST} localhost # Hostname of the NFVO +${NFVO_PORT} 8081 # Listening port of the NFVO +${NFVO_SCHEMA} https +${AUTHORIZATION_HEADER} Authorization +${AUTHORIZATION_TOKEN} Bearer 0b79bab50daca910b000d4f1a2b675d604257e42 +${ACCEPT_JSON} application/json +${AUTH_USAGE} 1 +${CONTENT_TYPE_JSON} application/json +${NEG_AUTHORIZATION} Bearer negativetoken +${NFVO_FIELDS} 1 + +${vnfPackageId} 788106a2-d692-44f3-a86d-384f0ce35e42 +${vndId} 788106a2-d692-44f3-a86d-384f0ce35e42 +${onboardingStateVnfPkgId} f9f130e4-05eb-4082-a676-4c97d13a883d +${onboardingStateVnfdId} f9f130e4-05eb-4082-a676-4c97d13a883d + +${apiRoot} / +${apiMajorVersion} v1 +${apiName} vnfsnapshotpkgm + +${NFVO_CHECKS_NOTIF_ENDPOINT} 1 ## If true, during subscription, the FUT performs a get to the notification endpoint + +${NFVO_ALLOWS_DUPLICATE_SUBS} 1 + +${PAGING_SUPPORTED} 1 + +${response} httpresponse + +${MOCK_SERVER_JAR} ../../../bin/mockserver-netty-5.5.0-jar-with-dependencies.jar + +${callback_uri} http://localhost +${callback_port} 9091 +${callback_endpoint} /endpoint +${callback_endpoint_fwd} /endpoint/check +${callback_endpoint_error} /endpoint_404 +${sleep_interval} 20s +${total_polling_time} 2 min +${polling_interval} 10 sec + + +${notification_request} [] +${notification_response} [] + +${NFVO_non-MANO_OK} 1 # If 1 means that non-MANO artifacts are supported by the NFVO +${non_mano_artifact_sets} + + +${subscriptionId} f3ae6df7-07e1-47c9-8924-9ebe10343586 +${erroneousSubscriptionId} 442e3ee5-0499-4849-9b31-eb91ce1638f1 # Not existing ID on the subscriptions +${newSubscriptionId} newSubsciptionId + +${origResponse} httpresponse + + +${erroneousVnfPackageId} erroneousVnfPackageId # Given ID for vnfPkg not present in database +${erroneousVnfdId} erroneousVnfdId + + +${filter_ok} callbackUri=http://172.22.1.7:9091/vnfpkgm/subscriptions +${filter_ko} nfvId=f9f130e4-05eb-4082-a676-4c97d13a883d # Not existant filter attribute-based +${SEPERATOR} = + + +${ACCEPT_PLAIN} text/plain +${CONTENT_TYPE_PLAIN} text/plain +${vnfPkgPlainVNFD} c26ad7fb-072b-48c4-a663-7d71646d9e98 # The VNF Pakcage contains a VNFD which is a Single Plain File +${ACCEPT_ZIP} application/zip +${ACCEPT_OCTET} application/octet-stream +${CONTENT_TYPE_ZIP} application/zip +${vnfPkgZipVNFD} f5b220d4-6177-4ebb-a554-a43311e16075 # The VNF Package contains a VNFD composed by multiple files +${erroneousVnfPkgId} erroneousVnfPackageId # Given ID for vnfPkg not present in database +${vndIdZipVnfd} f5b220d4-6177-4ebb-a554-a43311e16075 + + +${artifactPath} artifactPath +${CONTENT_TYPE_OCTET} application/octet-stream +${NFVO_RANGE_OK} 1 # If 1 means that Range is supported by the NFVO +${range} bytes=0-1023 +${full_size} 2000 # Size of the requested artifact to be downloaded via partial downloads +${erroneousRange} bytes=10000000-1000000000 # Requesting a out of range number of bytes +${vnfPackageOctetStreamId} octetStreamPkgId +${vnfdOctetStreamId} octetStreamVnfdId +${vndEncryptedArtifactID} encryptedId + + +${length} 1024 + +${POS_FILTER} vnfdId=41fdd38a-3d4c-465c-83e0-f80e014425f8 ,vnfProvider=NXW # Positive case, suing compiant fields name for filtering get request +${NEG_FILTER} nfvId=41fdd38a-3d4c-465c-83e0-f80e014425f8 # Negative case, using wrong name of field +${fields} softwareImages,additionalArtifacts +${VAR_SEPERATOR} & + +${callbackResp} localhost + +${vnfSnapshotPkgId} +${invalidVnfSnapshotInfoId} +${vnfSnapshotPkgId_notInAvailableState} \ No newline at end of file diff --git a/SOL003/VNFSnapshotPackageManagement-API/schemas/VnfSnapshotPkgInfo.schema.json b/SOL003/VNFSnapshotPackageManagement-API/schemas/VnfSnapshotPkgInfo.schema.json new file mode 100644 index 000000000..d2cf2c049 --- /dev/null +++ b/SOL003/VNFSnapshotPackageManagement-API/schemas/VnfSnapshotPkgInfo.schema.json @@ -0,0 +1,350 @@ +{ + "description": "This type represents the information of a VNF snapshot package.\n", + "type": "object", + "required": [ + "id", + "name", + "isFullSnapshot", + "state", + "isCancelPending", + "_links" + ], + "properties": { + "id": { + "description": "An identifier with the intention of being globally unique.\n", + "type": "string" + }, + "vnfSnapshotPkgUniqueId": { + "description": "An identifier with the intention of being globally unique.\n", + "type": "string" + }, + "name": { + "description": "A string defined in IETF RFC 8259.\n", + "type": "string" + }, + "checksum": { + "description": "Cheksum description\n", + "type": "string" + }, + "createdAt": { + "description": "Date-time stamp. Representation: String formatted according to IETF RFC 3339.\n", + "type": "string", + "format": "date-time" + }, + "vnfSnapshotId": { + "description": "An identifier with the intention of being globally unique.\n", + "type": "string" + }, + "vnfcSnapshotInfoIds": { + "description": "Identifiers of information held by the VNFM about specific VNFC snapshots part of the VNF snapshot and contained in the VNF snapshot package. This identifier is allocated by the VNFM during the VNF snapshot creation.\nNOTE: The attribute shall not be present before the VNF snapshot package content has been uploaded or built. Otherwise, this attribute shall be present unless it has been requested to be excluded per attribute selector.\n", + "type": "object", + "items": { + "description": "An identifier that is unique within a limited local scope other than above listed identifiers, such as within a complex data structure or within a request-response pair. Representation: string of variable length.\n", + "type": "string" + } + }, + "isFullSnapshot": { + "description": "The Boolean is a data type having two values (true and false).\n", + "type": "boolean" + }, + "vnfdInfo": { + "description": "This type represents the VNFD which is contained in a VNF snapshot package.\n", + "type": "object", + "required": [ + "avnfdId", + "vnfdPath", + "checksum", + "isEncrypted" + ], + "properties": { + "avnfdId": { + "description": "An identifier with the intention of being globally unique.\n", + "type": "string" + }, + "vnfdPath": { + "description": "A string defined in IETF RFC 8259.\n", + "type": "string" + }, + "checksum": { + "description": "Cheksum description\n", + "type": "string" + }, + "isEncrypted": { + "description": "The Boolean is a data type having two values (true and false).\n", + "type": "boolean" + } + } + }, + "vnfsr": { + "description": "This type represents the VNF snapshot record which is contained in a VNF snapshot package.\n", + "type": "object", + "required": [ + "recordPath", + "checksum", + "isEncrypted" + ], + "properties": { + "recordPath": { + "description": "A string defined in IETF RFC 8259.\n", + "type": "string" + }, + "checksum": { + "description": "Cheksum description\n", + "type": "string" + }, + "isEncrypted": { + "description": "The Boolean is a data type having two values (true and false).\n", + "type": "boolean" + } + } + }, + "vnfcSnapshotImages": { + "description": "Information about VNF snapshot artifacts that are VNFC snapshot images. Every local and external snapshot image shall be included. No other artifacts shall be included.\nNOTE: The attribute shall not be present before the VNF snapshot package content has been uploaded or built. Otherwise, this attribute shall be present unless it has been requested to be excluded per attribute selector.\n", + "type": "object", + "items": { + "description": "This type represents an artifact contained in a VNF snapshot package which represents a snapshot image.\n", + "type": "object", + "required": [ + "id", + "name", + "checksum", + "isEncrypted", + "vnfcInstanceId", + "containerFormat", + "diskFormat", + "createdAt", + "minDisk", + "minRam", + "size" + ], + "properties": { + "id": { + "description": "An identifier that is unique within a limited local scope other than above listed identifiers, such as within a complex data structure or within a request-response pair. Representation: string of variable length.\n", + "type": "string" + }, + "name": { + "description": "A string defined in IETF RFC 8259.\n", + "type": "string" + }, + "checksum": { + "description": "Cheksum description\n", + "type": "string" + }, + "isEncrypted": { + "description": "The Boolean is a data type having two values (true and false).\n", + "type": "boolean" + }, + "vnfcInstanceId": { + "description": "An identifier that is unique for the respective type within a VNF instance, but may not be globally unique.\n", + "type": "string" + }, + "containerFormat": { + "description": "Container format indicates whether the snapshot image is in a file format that also contains metadata about the actual snapshot.\nPermitted values: - AKI: a kernel image format - AMI: a machine image format - ARI: a ramdisk image format - BARE: the image does not have a container or metadata envelope - DOCKER: docker container format - OVA: OVF package in a tarfile - OVF: OVF container format\nNOTE: The list of permitted values was taken from \"Container formats\" in [i.5] (OpenStack® documentation: \"Disk and container formats for images\").\n", + "type": "string", + "enum": [ + "AKI", + "AMI", + "ARI", + "BARE", + "DOCKER", + "OVA", + "OVF" + ] + }, + "diskFormat": { + "description": "Disk format of a snapshot image is the format of the underlying disk image.\nPermitted values: - AKI: a kernel image format - AMI: a machine image format - ARI: a ramdisk image format - ISO: an archive format for the data contents of an optical disc, such as CD-ROM - QCOW2: a common disk image format, which can expand dynamically and supports copy on write - RAW: an unstructured disk image format - VDI: a common disk image format - VHD: a common disk image format - VHDX: enhanced version of VHD format - VMDK: a common disk image format\nNOTE: The list of permitted values was adapted from \"Disk formats\" in [i.5] (OpenStack® documentation: \"Disk and container formats for images\").\n", + "type": "string", + "enum": [ + "AKI", + "AMI", + "ARI", + "ISO", + "QCOW2", + "RAW", + "VDI", + "VHD", + "VHDX", + "VMDK" + ] + }, + "createdAt": { + "description": "Date-time stamp. Representation: String formatted according to IETF RFC 3339.\n", + "type": "string", + "format": "date-time" + }, + "minDisk": { + "description": "Unsigned integer number\n", + "type": "integer", + "minimum": 0 + }, + "minRam": { + "description": "Unsigned integer number\n", + "type": "integer", + "minimum": 0 + }, + "size": { + "description": "Unsigned integer number\n", + "type": "integer", + "minimum": 0 + }, + "userMetadata": { + "description": "This type represents a list of key-value pairs. The order of the pairs in the list is not significant. In JSON, a set of keyvalue pairs is represented as an object. It shall comply with the provisions defined in clause 4 of IETF RFC 8259. In the following example, a list of key-value pairs with four keys (\"aString\", \"aNumber\", \"anArray\" and \"anObject\") is provided to illustrate that the values associated with different keys can be of different type.\n", + "type": "object" + }, + "imagePath": { + "description": "A string defined in IETF RFC 8259.\n", + "type": "string" + }, + "imageUri": { + "description": "String formatted according to IETF RFC 3986.\n", + "type": "string" + } + } + } + }, + "additionalArtifacts": { + "description": "Information about VNF snapshot artifacts that are not VNFC snapshot images.\nNOTE: The attribute shall not be present before the VNF snapshot package content has been uploaded or built. Otherwise, this attribute shall be present unless it has been requested to be excluded per attribute selector.\n", + "type": "object", + "items": { + "description": "This type represents an artifact other than a software image which is contained in a VNF snapshot package.\n", + "type": "object", + "required": [ + "checksum", + "isEncrypted" + ], + "properties": { + "artifactPath": { + "description": "A string defined in IETF RFC 8259.\n", + "type": "string" + }, + "artifactUri": { + "description": "String formatted according to IETF RFC 3986.\n", + "type": "string" + }, + "checksum": { + "description": "Cheksum description\n", + "type": "string" + }, + "isEncrypted": { + "description": "The Boolean is a data type having two values (true and false).\n", + "type": "boolean" + }, + "metadata": { + "description": "This type represents a list of key-value pairs. The order of the pairs in the list is not significant. In JSON, a set of keyvalue pairs is represented as an object. It shall comply with the provisions defined in clause 4 of IETF RFC 8259. In the following example, a list of key-value pairs with four keys (\"aString\", \"aNumber\", \"anArray\" and \"anObject\") is provided to illustrate that the values associated with different keys can be of different type.\n", + "type": "object" + } + } + } + }, + "state": { + "description": "State of the VNF snapshot package. Permitted values: - CREATED: the VNF snapshot package information has been created. - BUILDING: the VNF snapshot package is being built. - UPLOADING: the VNF snapshot package is being uploaded. - EXTRACTING: the VNF snapshot package’s content is being extracted. - AVAILABLE: the VNF snapshot package is available (i.e., build or upload is completed). - ERROR: failure during the VNF snapshot package building, uploading or processing. - ERROR_EXTRACTING: failure during the VNF snapshot package extraction task.\n", + "type": "string", + "enum": [ + "CREATED", + "BUILDING", + "UPLOADING", + "EXTRACTING", + "AVAILABLE", + "ERROR", + "ERROR_EXTRACTING" + ] + }, + "isCancelPending": { + "description": "The Boolean is a data type having two values (true and false).\n", + "type": "boolean" + }, + "failureDetails": { + "description": "Failure details associated to current error state of the VNF snapshot package state. If \"state\" is \"ERROR\" or \"ERROR_EXTRACTING\", this attribute shall be present unless it has been requested to be excluded via an attribute selector.\n", + "type": "object", + "required": [ + "errorType", + "details" + ], + "properties": { + "errorType": { + "description": "Type of error, when the failure happened (building, upload, processing, extracting).\nPermitted values: - BUILD_ERROR - UPLOAD_ERROR - PROCESS_ERROR - CANCELLED - EXTRACTION_ERROR\n", + "type": "string", + "enum": [ + "BUILD_ERROR", + "UPLOAD_ERROR", + "PROCESS_ERROR", + "CANCELLED", + "EXTRACTION_ERROR" + ] + }, + "details": { + "description": "The definition of the general \"ProblemDetails\" data structure from IETF RFC 7807 [19] is reproduced inthis structure. Compared to the general framework defined in IETF RFC 7807 [19], the \"status\" and \"detail\" attributes are mandated to be included by the present document, to ensure that the response contains additional textual information about an error. IETF RFC 7807 [19] foresees extensibility of the \"ProblemDetails\" type. It is possible that particular APIs in the present document, or particular implementations, define extensions to define additional attributes that provide more information about the error. The description column only provides some explanation of the meaning to Facilitate understanding of the design. For a full description, see IETF RFC 7807 [19].\n", + "type": "object", + "required": [ + "status", + "detail" + ], + "properties": { + "type": { + "description": "A URI reference according to IETF RFC 3986 [5] that identifies the problem type. It is encouraged that the URI provides human-readable documentation for the problem (e.g. using HTML) when dereferenced. When this member is not present, its value is assumed to be \"about:blank\".\n", + "type": "string", + "format": "URI" + }, + "title": { + "description": "A short, human-readable summary of the problem type. It should not change from occurrence to occurrence of the problem, except for purposes of localization. If type is given and other than \"about:blank\", this attribute shall also be provided. A short, human-readable summary of the problem type. It SHOULD NOT change from occurrence to occurrence of the problem, except for purposes of localization (e.g., using proactive content negotiation; see [RFC7231], Section 3.4).\n", + "type": "string" + }, + "status": { + "description": "The HTTP status code for this occurrence of the problem. The HTTP status code ([RFC7231], Section 6) generated by the origin server for this occurrence of the problem.\n", + "type": "integer" + }, + "detail": { + "description": "A human-readable explanation specific to this occurrence of the problem.\n", + "type": "string" + }, + "instance": { + "description": "A URI reference that identifies the specific occurrence of the problem. It may yield further information if dereferenced.\n", + "type": "string", + "format": "URI" + } + } + } + } + }, + "userDefinedData": { + "description": "This type represents a list of key-value pairs. The order of the pairs in the list is not significant. In JSON, a set of keyvalue pairs is represented as an object. It shall comply with the provisions defined in clause 4 of IETF RFC 8259. In the following example, a list of key-value pairs with four keys (\"aString\", \"aNumber\", \"anArray\" and \"anObject\") is provided to illustrate that the values associated with different keys can be of different type.\n", + "type": "object" + }, + "_links": { + "description": "Links to resources related to this resource.\n", + "type": "object", + "required": [ + "self", + "packageContent" + ], + "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" + } + } + }, + "packageContent": { + "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" + } + } + } + } + } + } +} \ No newline at end of file diff --git a/SOL003/VNFSnapshotPackageManagement-API/schemas/VnfSnapshotPkgInfos.schema.json b/SOL003/VNFSnapshotPackageManagement-API/schemas/VnfSnapshotPkgInfos.schema.json new file mode 100644 index 000000000..692200c73 --- /dev/null +++ b/SOL003/VNFSnapshotPackageManagement-API/schemas/VnfSnapshotPkgInfos.schema.json @@ -0,0 +1,354 @@ +{ + "type": "array", + "items": + { + "description": "This type represents the information of a VNF snapshot package.\n", + "type": "object", + "required": [ + "id", + "name", + "isFullSnapshot", + "state", + "isCancelPending", + "_links" + ], + "properties": { + "id": { + "description": "An identifier with the intention of being globally unique.\n", + "type": "string" + }, + "vnfSnapshotPkgUniqueId": { + "description": "An identifier with the intention of being globally unique.\n", + "type": "string" + }, + "name": { + "description": "A string defined in IETF RFC 8259.\n", + "type": "string" + }, + "checksum": { + "description": "Cheksum description\n", + "type": "string" + }, + "createdAt": { + "description": "Date-time stamp. Representation: String formatted according to IETF RFC 3339.\n", + "type": "string", + "format": "date-time" + }, + "vnfSnapshotId": { + "description": "An identifier with the intention of being globally unique.\n", + "type": "string" + }, + "vnfcSnapshotInfoIds": { + "description": "Identifiers of information held by the VNFM about specific VNFC snapshots part of the VNF snapshot and contained in the VNF snapshot package. This identifier is allocated by the VNFM during the VNF snapshot creation.\nNOTE: The attribute shall not be present before the VNF snapshot package content has been uploaded or built. Otherwise, this attribute shall be present unless it has been requested to be excluded per attribute selector.\n", + "type": "object", + "items": { + "description": "An identifier that is unique within a limited local scope other than above listed identifiers, such as within a complex data structure or within a request-response pair. Representation: string of variable length.\n", + "type": "string" + } + }, + "isFullSnapshot": { + "description": "The Boolean is a data type having two values (true and false).\n", + "type": "boolean" + }, + "vnfdInfo": { + "description": "This type represents the VNFD which is contained in a VNF snapshot package.\n", + "type": "object", + "required": [ + "avnfdId", + "vnfdPath", + "checksum", + "isEncrypted" + ], + "properties": { + "avnfdId": { + "description": "An identifier with the intention of being globally unique.\n", + "type": "string" + }, + "vnfdPath": { + "description": "A string defined in IETF RFC 8259.\n", + "type": "string" + }, + "checksum": { + "description": "Cheksum description\n", + "type": "string" + }, + "isEncrypted": { + "description": "The Boolean is a data type having two values (true and false).\n", + "type": "boolean" + } + } + }, + "vnfsr": { + "description": "This type represents the VNF snapshot record which is contained in a VNF snapshot package.\n", + "type": "object", + "required": [ + "recordPath", + "checksum", + "isEncrypted" + ], + "properties": { + "recordPath": { + "description": "A string defined in IETF RFC 8259.\n", + "type": "string" + }, + "checksum": { + "description": "Cheksum description\n", + "type": "string" + }, + "isEncrypted": { + "description": "The Boolean is a data type having two values (true and false).\n", + "type": "boolean" + } + } + }, + "vnfcSnapshotImages": { + "description": "Information about VNF snapshot artifacts that are VNFC snapshot images. Every local and external snapshot image shall be included. No other artifacts shall be included.\nNOTE: The attribute shall not be present before the VNF snapshot package content has been uploaded or built. Otherwise, this attribute shall be present unless it has been requested to be excluded per attribute selector.\n", + "type": "object", + "items": { + "description": "This type represents an artifact contained in a VNF snapshot package which represents a snapshot image.\n", + "type": "object", + "required": [ + "id", + "name", + "checksum", + "isEncrypted", + "vnfcInstanceId", + "containerFormat", + "diskFormat", + "createdAt", + "minDisk", + "minRam", + "size" + ], + "properties": { + "id": { + "description": "An identifier that is unique within a limited local scope other than above listed identifiers, such as within a complex data structure or within a request-response pair. Representation: string of variable length.\n", + "type": "string" + }, + "name": { + "description": "A string defined in IETF RFC 8259.\n", + "type": "string" + }, + "checksum": { + "description": "Cheksum description\n", + "type": "string" + }, + "isEncrypted": { + "description": "The Boolean is a data type having two values (true and false).\n", + "type": "boolean" + }, + "vnfcInstanceId": { + "description": "An identifier that is unique for the respective type within a VNF instance, but may not be globally unique.\n", + "type": "string" + }, + "containerFormat": { + "description": "Container format indicates whether the snapshot image is in a file format that also contains metadata about the actual snapshot.\nPermitted values: - AKI: a kernel image format - AMI: a machine image format - ARI: a ramdisk image format - BARE: the image does not have a container or metadata envelope - DOCKER: docker container format - OVA: OVF package in a tarfile - OVF: OVF container format\nNOTE: The list of permitted values was taken from \"Container formats\" in [i.5] (OpenStack® documentation: \"Disk and container formats for images\").\n", + "type": "string", + "enum": [ + "AKI", + "AMI", + "ARI", + "BARE", + "DOCKER", + "OVA", + "OVF" + ] + }, + "diskFormat": { + "description": "Disk format of a snapshot image is the format of the underlying disk image.\nPermitted values: - AKI: a kernel image format - AMI: a machine image format - ARI: a ramdisk image format - ISO: an archive format for the data contents of an optical disc, such as CD-ROM - QCOW2: a common disk image format, which can expand dynamically and supports copy on write - RAW: an unstructured disk image format - VDI: a common disk image format - VHD: a common disk image format - VHDX: enhanced version of VHD format - VMDK: a common disk image format\nNOTE: The list of permitted values was adapted from \"Disk formats\" in [i.5] (OpenStack® documentation: \"Disk and container formats for images\").\n", + "type": "string", + "enum": [ + "AKI", + "AMI", + "ARI", + "ISO", + "QCOW2", + "RAW", + "VDI", + "VHD", + "VHDX", + "VMDK" + ] + }, + "createdAt": { + "description": "Date-time stamp. Representation: String formatted according to IETF RFC 3339.\n", + "type": "string", + "format": "date-time" + }, + "minDisk": { + "description": "Unsigned integer number\n", + "type": "integer", + "minimum": 0 + }, + "minRam": { + "description": "Unsigned integer number\n", + "type": "integer", + "minimum": 0 + }, + "size": { + "description": "Unsigned integer number\n", + "type": "integer", + "minimum": 0 + }, + "userMetadata": { + "description": "This type represents a list of key-value pairs. The order of the pairs in the list is not significant. In JSON, a set of keyvalue pairs is represented as an object. It shall comply with the provisions defined in clause 4 of IETF RFC 8259. In the following example, a list of key-value pairs with four keys (\"aString\", \"aNumber\", \"anArray\" and \"anObject\") is provided to illustrate that the values associated with different keys can be of different type.\n", + "type": "object" + }, + "imagePath": { + "description": "A string defined in IETF RFC 8259.\n", + "type": "string" + }, + "imageUri": { + "description": "String formatted according to IETF RFC 3986.\n", + "type": "string" + } + } + } + }, + "additionalArtifacts": { + "description": "Information about VNF snapshot artifacts that are not VNFC snapshot images.\nNOTE: The attribute shall not be present before the VNF snapshot package content has been uploaded or built. Otherwise, this attribute shall be present unless it has been requested to be excluded per attribute selector.\n", + "type": "object", + "items": { + "description": "This type represents an artifact other than a software image which is contained in a VNF snapshot package.\n", + "type": "object", + "required": [ + "checksum", + "isEncrypted" + ], + "properties": { + "artifactPath": { + "description": "A string defined in IETF RFC 8259.\n", + "type": "string" + }, + "artifactUri": { + "description": "String formatted according to IETF RFC 3986.\n", + "type": "string" + }, + "checksum": { + "description": "Cheksum description\n", + "type": "string" + }, + "isEncrypted": { + "description": "The Boolean is a data type having two values (true and false).\n", + "type": "boolean" + }, + "metadata": { + "description": "This type represents a list of key-value pairs. The order of the pairs in the list is not significant. In JSON, a set of keyvalue pairs is represented as an object. It shall comply with the provisions defined in clause 4 of IETF RFC 8259. In the following example, a list of key-value pairs with four keys (\"aString\", \"aNumber\", \"anArray\" and \"anObject\") is provided to illustrate that the values associated with different keys can be of different type.\n", + "type": "object" + } + } + } + }, + "state": { + "description": "State of the VNF snapshot package. Permitted values: - CREATED: the VNF snapshot package information has been created. - BUILDING: the VNF snapshot package is being built. - UPLOADING: the VNF snapshot package is being uploaded. - EXTRACTING: the VNF snapshot package’s content is being extracted. - AVAILABLE: the VNF snapshot package is available (i.e., build or upload is completed). - ERROR: failure during the VNF snapshot package building, uploading or processing. - ERROR_EXTRACTING: failure during the VNF snapshot package extraction task.\n", + "type": "string", + "enum": [ + "CREATED", + "BUILDING", + "UPLOADING", + "EXTRACTING", + "AVAILABLE", + "ERROR", + "ERROR_EXTRACTING" + ] + }, + "isCancelPending": { + "description": "The Boolean is a data type having two values (true and false).\n", + "type": "boolean" + }, + "failureDetails": { + "description": "Failure details associated to current error state of the VNF snapshot package state. If \"state\" is \"ERROR\" or \"ERROR_EXTRACTING\", this attribute shall be present unless it has been requested to be excluded via an attribute selector.\n", + "type": "object", + "required": [ + "errorType", + "details" + ], + "properties": { + "errorType": { + "description": "Type of error, when the failure happened (building, upload, processing, extracting).\nPermitted values: - BUILD_ERROR - UPLOAD_ERROR - PROCESS_ERROR - CANCELLED - EXTRACTION_ERROR\n", + "type": "string", + "enum": [ + "BUILD_ERROR", + "UPLOAD_ERROR", + "PROCESS_ERROR", + "CANCELLED", + "EXTRACTION_ERROR" + ] + }, + "details": { + "description": "The definition of the general \"ProblemDetails\" data structure from IETF RFC 7807 [19] is reproduced inthis structure. Compared to the general framework defined in IETF RFC 7807 [19], the \"status\" and \"detail\" attributes are mandated to be included by the present document, to ensure that the response contains additional textual information about an error. IETF RFC 7807 [19] foresees extensibility of the \"ProblemDetails\" type. It is possible that particular APIs in the present document, or particular implementations, define extensions to define additional attributes that provide more information about the error. The description column only provides some explanation of the meaning to Facilitate understanding of the design. For a full description, see IETF RFC 7807 [19].\n", + "type": "object", + "required": [ + "status", + "detail" + ], + "properties": { + "type": { + "description": "A URI reference according to IETF RFC 3986 [5] that identifies the problem type. It is encouraged that the URI provides human-readable documentation for the problem (e.g. using HTML) when dereferenced. When this member is not present, its value is assumed to be \"about:blank\".\n", + "type": "string", + "format": "URI" + }, + "title": { + "description": "A short, human-readable summary of the problem type. It should not change from occurrence to occurrence of the problem, except for purposes of localization. If type is given and other than \"about:blank\", this attribute shall also be provided. A short, human-readable summary of the problem type. It SHOULD NOT change from occurrence to occurrence of the problem, except for purposes of localization (e.g., using proactive content negotiation; see [RFC7231], Section 3.4).\n", + "type": "string" + }, + "status": { + "description": "The HTTP status code for this occurrence of the problem. The HTTP status code ([RFC7231], Section 6) generated by the origin server for this occurrence of the problem.\n", + "type": "integer" + }, + "detail": { + "description": "A human-readable explanation specific to this occurrence of the problem.\n", + "type": "string" + }, + "instance": { + "description": "A URI reference that identifies the specific occurrence of the problem. It may yield further information if dereferenced.\n", + "type": "string", + "format": "URI" + } + } + } + } + }, + "userDefinedData": { + "description": "This type represents a list of key-value pairs. The order of the pairs in the list is not significant. In JSON, a set of keyvalue pairs is represented as an object. It shall comply with the provisions defined in clause 4 of IETF RFC 8259. In the following example, a list of key-value pairs with four keys (\"aString\", \"aNumber\", \"anArray\" and \"anObject\") is provided to illustrate that the values associated with different keys can be of different type.\n", + "type": "object" + }, + "_links": { + "description": "Links to resources related to this resource.\n", + "type": "object", + "required": [ + "self", + "packageContent" + ], + "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" + } + } + }, + "packageContent": { + "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" + } + } + } + } + } + } + } +} \ No newline at end of file -- GitLab From 48dc1df98a50df51200826744a44f244c90ca74e Mon Sep 17 00:00:00 2001 From: hammad zafar Date: Tue, 2 Mar 2021 19:05:10 +0500 Subject: [PATCH 2/6] bug fixes --- .../ApiVersion.robot | 20 ++++++------- .../IndividualVNFSnapshotPackage.robot | 10 +++---- ...IndividualVNFSnapshotPackageArtifact.robot | 18 ++++++------ .../VNFSnapshotPackageContent.robot | 18 ++++++------ .../VNFSnapshotPackages.robot | 28 +++++++++---------- ...VnfSnapshotPackageManagementKeywords.robot | 2 +- 6 files changed, 48 insertions(+), 48 deletions(-) diff --git a/SOL003/VNFSnapshotPackageManagement-API/ApiVersion.robot b/SOL003/VNFSnapshotPackageManagement-API/ApiVersion.robot index e770a7790..2faac7da5 100644 --- a/SOL003/VNFSnapshotPackageManagement-API/ApiVersion.robot +++ b/SOL003/VNFSnapshotPackageManagement-API/ApiVersion.robot @@ -8,7 +8,7 @@ POST API Version - Method not implemented ... Test objective: The objective is to test that POST method is not implemented ... Pre-conditions: none ... Reference: Clause 9.3.3.3.1 - ETSI GS NFV-SOL 013 v3.3.1 - ... Config ID: Config_prod_VNFM + ... Config ID: Config_prod_NFVO ... Applicability: none ... Post-Conditions: none POST API Version @@ -20,7 +20,7 @@ GET API Version ... Test objective: The objective is to test that GET method successfully return ApiVersionInformation ... Pre-conditions: none ... Reference: Clause 9.3.3.3.2 - ETSI GS NFV-SOL 013 v3.3.1 - ... Config ID: Config_prod_VNFM + ... Config ID: Config_prod_NFVO ... Applicability: none ... Post-Conditions: none GET API Version @@ -33,7 +33,7 @@ PUT API Version - Method not implemented ... Test objective: The objective is to test that PUT method is not implemented ... Pre-conditions: none ... Reference: Clause 9.3.3.3.3 - ETSI GS NFV-SOL 013 v3.3.1 - ... Config ID: Config_prod_VNFM + ... Config ID: Config_prod_NFVO ... Applicability: none ... Post-Conditions: none PUT API Version @@ -45,7 +45,7 @@ PATCH API Version - Method not implemented ... Test objective: The objective is to test that PATCH method is not implemented ... Pre-conditions: none ... Reference: Clause 9.3.3.3.4 - ETSI GS NFV-SOL 013 v3.3.1 - ... Config ID: Config_prod_VNFM + ... Config ID: Config_prod_NFVO ... Applicability: none ... Post-Conditions: none PATCH API Version @@ -57,7 +57,7 @@ DELETE API Version - Method not implemented ... Test objective: The objective is to test that DELETE method is not implemented ... Pre-conditions: none ... Reference: Clause 9.3.3.3.5 - ETSI GS NFV-SOL 013 v3.3.1 - ... Config ID: Config_prod_VNFM + ... Config ID: Config_prod_NFVO ... Applicability: none ... Post-Conditions: none DELETE API Version @@ -69,7 +69,7 @@ POST API Version with apiMajorVerion - Method not implemented ... Test objective: The objective is to test that POST method is not implemented ... Pre-conditions: none ... Reference: Clause 9.3.3.3.1 - ETSI GS NFV-SOL 013 v3.3.1 - ... Config ID: Config_prod_VNFM + ... Config ID: Config_prod_NFVO ... Applicability: none ... Post-Conditions: none POST API Version @@ -81,7 +81,7 @@ GET API Version with apiMajorVerion ... Test objective: The objective is to test that GET method successfully return ApiVersionInformation ... Pre-conditions: none ... Reference: Clause 9.3.3.3.2 - ETSI GS NFV-SOL 013 v3.3.1 - ... Config ID: Config_prod_VNFM + ... Config ID: Config_prod_NFVO ... Applicability: none ... Post-Conditions: none GET API Version @@ -94,7 +94,7 @@ PUT API Version with apiMajorVerion - Method not implemented ... Test objective: The objective is to test that PUT method is not implemented ... Pre-conditions: none ... Reference: Clause 9.3.3.3.3 - ETSI GS NFV-SOL 013 v3.3.1 - ... Config ID: Config_prod_VNFM + ... Config ID: Config_prod_NFVO ... Applicability: none ... Post-Conditions: none PUT API Version @@ -106,7 +106,7 @@ PATCH API Version with apiMajorVerion - Method not implemented ... Test objective: The objective is to test that PATCH method is not implemented ... Pre-conditions: none ... Reference: Clause 9.3.3.3.4 - ETSI GS NFV-SOL 013 v3.3.1 - ... Config ID: Config_prod_VNFM + ... Config ID: Config_prod_NFVO ... Applicability: none ... Post-Conditions: none PATCH API Version @@ -118,7 +118,7 @@ DELETE API Version with apiMajorVerion - Method not implemented ... Test objective: The objective is to test that DELETE method is not implemented ... Pre-conditions: none ... Reference: Clause 9.3.3.3.5 - ETSI GS NFV-SOL 013 v3.3.1 - ... Config ID: Config_prod_VNFM + ... Config ID: Config_prod_NFVO ... Applicability: none ... Post-Conditions: none DELETE API Version diff --git a/SOL003/VNFSnapshotPackageManagement-API/IndividualVNFSnapshotPackage.robot b/SOL003/VNFSnapshotPackageManagement-API/IndividualVNFSnapshotPackage.robot index 36d951061..082970684 100644 --- a/SOL003/VNFSnapshotPackageManagement-API/IndividualVNFSnapshotPackage.robot +++ b/SOL003/VNFSnapshotPackageManagement-API/IndividualVNFSnapshotPackage.robot @@ -8,7 +8,7 @@ POST Individual VNF Snapshot Package - Method not implemented ... Test objective: The objective is to test that POST method is not implemented ... Pre-conditions: none ... Reference: Clause 12.4.3.3.1 - ETSI GS NFV-SOL 003 [1] v3.3.1 - ... Config ID: Config_prod_VNFM + ... Config ID: Config_prod_NFVO ... Applicability: none ... Post-Conditions: none POST individual VNF Snapshot Package @@ -20,7 +20,7 @@ GET Information about an individual VNF Snapshot Package - SUCCESSFUL ... Test objective: The objective is to create a new VNF Snapshot Package resource ... Pre-conditions: none ... Reference: Clause 12.4.3.3.2 - ETSI GS NFV-SOL 003 [1] v3.3.1 - ... Config ID: Config_prod_VNFM + ... Config ID: Config_prod_NFVO ... Applicability: none ... Post-Conditions: none GET individual VNF Snapshot Package @@ -46,7 +46,7 @@ PUT Individual VNF Snapshot Package - Method not implemented ... Test objective: The objective is to test that PUT method is not implemented ... Pre-conditions: none ... Reference: Clause 12.4.3.3.3 - ETSI GS NFV-SOL 003 [1] v3.3.1 - ... Config ID: Config_prod_VNFM + ... Config ID: Config_prod_NFVO ... Applicability: none ... Post-Conditions: VNF Snapshot Package not modified PUT individual VNF Snapshot Package @@ -58,7 +58,7 @@ PATCH Individual VNF Snapshot Package - Method Not implemented ... Test objective: The objective is to test that PATCH method is not implemented ... Pre-conditions: none ... Reference: Clause 12.4.3.3.4 - ETSI GS NFV-SOL 003 [1] v3.3.1 - ... Config ID: Config_prod_VNFM + ... Config ID: Config_prod_NFVO ... Applicability: none ... Post-Conditions: VNF Snapshot Package modified PATCH individual VNF Snapshot Package @@ -70,7 +70,7 @@ DELETE Individual VNF Snapshot Package - Method Not implemented ... Test objective: The objective is to test that DELETE method is not implemented ... Pre-conditions: none ... Reference: Clause 12.4.3.3.5 - ETSI GS NFV-SOL 003 [1] v3.3.1 - ... Config ID: Config_prod_VNFM + ... Config ID: Config_prod_NFVO ... Applicability: none ... Post-Conditions: VNF Snapshot Package deleted DELETE individual VNF Snapshot Package diff --git a/SOL003/VNFSnapshotPackageManagement-API/IndividualVNFSnapshotPackageArtifact.robot b/SOL003/VNFSnapshotPackageManagement-API/IndividualVNFSnapshotPackageArtifact.robot index 224459059..44da2f1e1 100644 --- a/SOL003/VNFSnapshotPackageManagement-API/IndividualVNFSnapshotPackageArtifact.robot +++ b/SOL003/VNFSnapshotPackageManagement-API/IndividualVNFSnapshotPackageArtifact.robot @@ -8,7 +8,7 @@ POST Individual VNF Snapshot Package Artifact - Method not implemented ... Test objective: The objective is to test that POST method is not implemented ... Pre-conditions: none ... Reference: Clause 12.4.5.3.1 - ETSI GS NFV-SOL 003 [1] v3.3.1 - ... Config ID: Config_prod_VNFM + ... Config ID: Config_prod_NFVO ... Applicability: none ... Post-Conditions: none POST Individual VNF Snapshot Package Artifact @@ -20,7 +20,7 @@ GET Individual VNF Snapshot Package Artifact - Complete File ... Test objective: The objective is to fetch the whole content of a VNF snapshot package using GET method. ... Pre-conditions: none ... Reference: Clause 12.4.5.3.2 - ETSI GS NFV-SOL 003 [1] v3.3.1 - ... Config ID: Config_prod_VNFM + ... Config ID: Config_prod_NFVO ... Applicability: none ... Post-Conditions: none GET Individual VNF Snapshot Package Artifact - Complete @@ -33,7 +33,7 @@ GET Individual VNF Snapshot Package Artifact - Partial Content ... Test objective: The objective is to fetch partial content of a VNF snapshot package by sending a range request using GET method. ... Pre-conditions: none ... Reference: Clause 12.4.5.3.2 - ETSI GS NFV-SOL 003 [1] v3.3.1 - ... Config ID: Config_prod_VNFM + ... Config ID: Config_prod_NFVO ... Applicability: NFVO supports range requests ... Post-Conditions: none GET Individual VNF Snapshot Package Artifact - Range Request @@ -47,7 +47,7 @@ GET Individual VNF Snapshot Package Artifact - Range Request Not Supported ... Test objective: The objective is to test that the whole content of a VNF snapshot package is delivered even with a range request when NFVO does not support range requests. ... Pre-conditions: none ... Reference: Clause 12.4.5.3.2 - ETSI GS NFV-SOL 003 [1] v3.3.1 - ... Config ID: Config_prod_VNFM + ... Config ID: Config_prod_NFVO ... Applicability: NFVO does not support range requests ... Post-Conditions: none GET Individual VNF Snapshot Package Artifact - Range Request @@ -60,7 +60,7 @@ GET Individual VNF Snapshot Package Artifact - Range Not Satisfiable ... Test objective: The objective is to test that an error is returned when the byte range passed in the "Range" header does not match any available byte range in the VNF snapshot package file. ... Pre-conditions: none ... Reference: Clause 12.4.5.3.2 - ETSI GS NFV-SOL 003 [1] v3.3.1 - ... Config ID: Config_prod_VNFM + ... Config ID: Config_prod_NFVO ... Applicability: NFVO supports range requests ... Post-Conditions: none GET Individual VNF Snapshot Package Artifact - Invalid Range @@ -72,7 +72,7 @@ GET Individual VNF Snapshot Package Artifact - Conflict ... Test objective: The objective is to test that an error is returned when the "state" of the VNF snapshot package has a value different from "AVAILABLE". ... Pre-conditions: none ... Reference: Clause 12.4.5.3.2 - ETSI GS NFV-SOL 003 [1] v3.3.1 - ... Config ID: Config_prod_VNFM + ... Config ID: Config_prod_NFVO ... Applicability: The "state" of the VNF snapshot package has a value different from "AVAILABLE". ... Post-Conditions: none GET Individual VNF Snapshot Package Artifact - Not Available @@ -84,7 +84,7 @@ PUT Individual VNF Snapshot Package Artifact - Method not implemented ... Test objective: The objective is to test that PUT method is not implemented ... Pre-conditions: none ... Reference: Clause 12.4.5.3.3 - ETSI GS NFV-SOL 003 [1] v3.3.1 - ... Config ID: Config_prod_VNFM + ... Config ID: Config_prod_NFVO ... Applicability: none ... Post-Conditions: VNF Snapshot Package not modified PUT Individual VNF Snapshot Package Artifact @@ -96,7 +96,7 @@ PATCH Individual VNF Snapshot Package Artifact - Method Not implemented ... Test objective: The objective is to test that PATCH method is not implemented ... Pre-conditions: none ... Reference: Clause 12.4.5.3.4 - ETSI GS NFV-SOL 003 [1] v3.3.1 - ... Config ID: Config_prod_VNFM + ... Config ID: Config_prod_NFVO ... Applicability: none ... Post-Conditions: none PATCH Individual VNF Snapshot Package Artifact @@ -108,7 +108,7 @@ DELETE Individual VNF Snapshot Package Artifact - Method Not implemented ... Test objective: The objective is to test that DELETE method is not implemented ... Pre-conditions: none ... Reference: Clause 12.4.5.3.5 - ETSI GS NFV-SOL 003 [1] v3.3.1 - ... Config ID: Config_prod_VNFM + ... Config ID: Config_prod_NFVO ... Applicability: none ... Post-Conditions: none DELETE Individual VNF Snapshot Package Artifact diff --git a/SOL003/VNFSnapshotPackageManagement-API/VNFSnapshotPackageContent.robot b/SOL003/VNFSnapshotPackageManagement-API/VNFSnapshotPackageContent.robot index 8271d7489..9518e4bbf 100644 --- a/SOL003/VNFSnapshotPackageManagement-API/VNFSnapshotPackageContent.robot +++ b/SOL003/VNFSnapshotPackageManagement-API/VNFSnapshotPackageContent.robot @@ -8,7 +8,7 @@ POST VNF Snapshot Package Content - Method not implemented ... Test objective: The objective is to test that POST method is not implemented ... Pre-conditions: none ... Reference: Clause 12.4.4.3.1 - ETSI GS NFV-SOL 003 [1] v3.3.1 - ... Config ID: Config_prod_VNFM + ... Config ID: Config_prod_NFVO ... Applicability: none ... Post-Conditions: none POST VNF Snapshot Package Content @@ -20,7 +20,7 @@ GET VNF Snapshot Package Content - Complete File ... Test objective: The objective is to fetch the whole content of a VNF snapshot package using GET method. ... Pre-conditions: none ... Reference: Clause 12.4.4.3.2 - ETSI GS NFV-SOL 003 [1] v3.3.1 - ... Config ID: Config_prod_VNFM + ... Config ID: Config_prod_NFVO ... Applicability: none ... Post-Conditions: none GET VNF Snapshot Package Content - Complete @@ -33,7 +33,7 @@ GET VNF Snapshot Package Content - Partial Content ... Test objective: The objective is to fetch partial content of a VNF snapshot package by sending a range request using GET method. ... Pre-conditions: none ... Reference: Clause 12.4.4.3.2 - ETSI GS NFV-SOL 003 [1] v3.3.1 - ... Config ID: Config_prod_VNFM + ... Config ID: Config_prod_NFVO ... Applicability: NFVO supports range requests ... Post-Conditions: none GET VNF Snapshot Package Content - Range Request @@ -47,7 +47,7 @@ GET VNF Snapshot Package Content - Range Request Not Supported ... Test objective: The objective is to test that the whole content of a VNF snapshot package is delivered even with a range request when NFVO does not support range requests. ... Pre-conditions: none ... Reference: Clause 12.4.4.3.2 - ETSI GS NFV-SOL 003 [1] v3.3.1 - ... Config ID: Config_prod_VNFM + ... Config ID: Config_prod_NFVO ... Applicability: NFVO does not support range requests ... Post-Conditions: none GET VNF Snapshot Package Content - Range Request @@ -60,7 +60,7 @@ GET VNF Snapshot Package Content - Range Not Satisfiable ... Test objective: The objective is to test that an error is returned when the byte range passed in the "Range" header does not match any available byte range in the VNF snapshot package file. ... Pre-conditions: none ... Reference: Clause 12.4.4.3.2 - ETSI GS NFV-SOL 003 [1] v3.3.1 - ... Config ID: Config_prod_VNFM + ... Config ID: Config_prod_NFVO ... Applicability: NFVO supports range requests ... Post-Conditions: none GET VNF Snapshot Package Content - Invalid Range @@ -72,7 +72,7 @@ GET VNF Snapshot Package Content - Conflict ... Test objective: The objective is to test that an error is returned when the "state" of the VNF snapshot package has a value different from "AVAILABLE". ... Pre-conditions: none ... Reference: Clause 12.4.4.3.2 - ETSI GS NFV-SOL 003 [1] v3.3.1 - ... Config ID: Config_prod_VNFM + ... Config ID: Config_prod_NFVO ... Applicability: The "state" of the VNF snapshot package has a value different from "AVAILABLE". ... Post-Conditions: none GET VNF Snapshot Package Content - Not Available @@ -84,7 +84,7 @@ PUT VNF Snapshot Package Content - Method not implemented ... Test objective: The objective is to test that PUT method is not implemented ... Pre-conditions: none ... Reference: Clause 12.4.4.3.3 - ETSI GS NFV-SOL 003 [1] v3.3.1 - ... Config ID: Config_prod_VNFM + ... Config ID: Config_prod_NFVO ... Applicability: none ... Post-Conditions: VNF Snapshot Package not modified PUT VNF Snapshot Package Content @@ -96,7 +96,7 @@ PATCH VNF Snapshot Package Content - Method Not implemented ... Test objective: The objective is to test that PATCH method is not implemented ... Pre-conditions: none ... Reference: Clause 12.4.4.3.4 - ETSI GS NFV-SOL 003 [1] v3.3.1 - ... Config ID: Config_prod_VNFM + ... Config ID: Config_prod_NFVO ... Applicability: none ... Post-Conditions: none PATCH VNF Snapshot Package Content @@ -108,7 +108,7 @@ DELETE VNF Snapshot Package Content - Method Not implemented ... Test objective: The objective is to test that DELETE method is not implemented ... Pre-conditions: none ... Reference: Clause 12.4.4.3.5 - ETSI GS NFV-SOL 003 [1] v3.3.1 - ... Config ID: Config_prod_VNFM + ... Config ID: Config_prod_NFVO ... Applicability: none ... Post-Conditions: none DELETE VNF Snapshot Package Content diff --git a/SOL003/VNFSnapshotPackageManagement-API/VNFSnapshotPackages.robot b/SOL003/VNFSnapshotPackageManagement-API/VNFSnapshotPackages.robot index 6a845045f..b5de47fe8 100644 --- a/SOL003/VNFSnapshotPackageManagement-API/VNFSnapshotPackages.robot +++ b/SOL003/VNFSnapshotPackageManagement-API/VNFSnapshotPackages.robot @@ -8,7 +8,7 @@ POST VNF Snapshot Packages - Method not implemented ... Test objective: The objective is to test that POST method is not implemented ... Pre-conditions: none ... Reference: Clause 12.4.2.3.1 - ETSI GS NFV-SOL 003 [1] v3.3.1 - ... Config ID: Config_prod_VNFM + ... Config ID: Config_prod_NFVO ... Applicability: none ... Post-Conditions: none POST VNF Snapshot Packages @@ -20,7 +20,7 @@ GET information about multiple VNF Snapshot Packages ... Test objective: The objective is to get information about multiples VNF Snapshot Packages ... Pre-conditions: none ... Reference: Clause 12.4.2.3.2 - ETSI GS NFV-SOL 003 [1] v3.3.1 - ... Config ID: Config_prod_VNFM + ... Config ID: Config_prod_NFVO ... Applicability: none ... Post-Conditions: none GET multiple VNF Snapshot Packages @@ -33,7 +33,7 @@ GET information about multiple VNF Snapshot Packages Bad Request Invalid attribu ... Test objective: The objective is to get information about multiples VNF Snapshot Packages with Invalid attribute-based filtering parameters ... Pre-conditions: none ... Reference: Clause 12.4.2.3.2 - ETSI GS NFV-SOL 003 [1] v3.3.1 - ... Config ID: Config_prod_VNFM + ... Config ID: Config_prod_NFVO ... Applicability: none ... Post-Conditions: none GET multiple VNF Snapshot Packages with bad attribute @@ -46,7 +46,7 @@ GET information about multiple VNF Snapshot Packages Bad Request Invalid attribu ... Test objective: The objective is to get information about multiples VNF Snapshot Packages with Invalid attribute-based filtering parameters ... Pre-conditions: none ... Reference: Clause 12.4.2.3.2 - ETSI GS NFV-SOL 003 [1] v3.3.1 - ... Config ID: Config_prod_VNFM + ... Config ID: Config_prod_NFVO ... Applicability: none ... Post-Conditions: none GET multiple VNF Snapshot Packages with bad filter @@ -59,7 +59,7 @@ GET information about multiple VNF Snapshot Packages with "all_fields" attribute ... Test objective: The objective is to query information about multiple VNF Snapshot Packages ... Pre-conditions: none ... Reference: Clause 12.4.2.3.2 - ETSI GS NFV-SOL 003 [1] v3.3.1 - ... Config ID: Config_prod_VNFM + ... Config ID: Config_prod_NFVO ... Applicability: none ... Post-Conditions: none GET multiple VNF Snapshot Packages with all_fields attribute selector @@ -72,7 +72,7 @@ GET information about multiple VNF Snapshot Packages with "exclude_default" attr ... Test objective: The objective is to query information about multiple VNF Snapshot Packages ... Pre-conditions: none ... Reference: Clause 12.4.2.3.2 - ETSI GS NFV-SOL 003 [1] v3.3.1 - ... Config ID: Config_prod_VNFM + ... Config ID: Config_prod_NFVO ... Applicability: none ... Post-Conditions: none GET multiple VNF Snapshot Packages with exclude_default attribute selector @@ -85,7 +85,7 @@ GET information about multiple VNF Snapshot Packages with "fields" attribute sel ... Test objective: The objective is to query information about multiple VNF Snapshot Packages ... Pre-conditions: none ... Reference: Clause 12.4.2.3.2 - ETSI GS NFV-SOL 003 [1] v3.3.1 - ... Config ID: Config_prod_VNFM + ... Config ID: Config_prod_NFVO ... Applicability: none ... Post-Conditions: none GET multiple VNF Snapshot Packages with fields attribute selector @@ -98,7 +98,7 @@ GET information about multiple VNF Snapshot Packages with "exclude_default" and ... Test objective: The objective is to query information about multiple VNF Snapshot Packages ... Pre-conditions: none ... Reference: Clause 12.4.2.3.2 - ETSI GS NFV-SOL 003 [1] v3.3.1 - ... Config ID: Config_prod_VNFM + ... Config ID: Config_prod_NFVO ... Applicability: none ... Post-Conditions: none GET multiple VNF Snapshot Packages with exclude_default and fields attribute selector @@ -111,7 +111,7 @@ GET information about multiple VNF Snapshot Packages with "exclude_fields" attri ... Test objective: The objective is to query information about multiple VNF Snapshot Packages ... Pre-conditions: none ... Reference: Clause 12.4.2.3.2 - ETSI GS NFV-SOL 003 [1] v3.3.1 - ... Config ID: Config_prod_VNFM + ... Config ID: Config_prod_NFVO ... Applicability: none ... Post-Conditions: none GET multiple VNF Snapshot Packages with exclude_fields attribute selector @@ -124,7 +124,7 @@ GET VNF Snapshot Packages - Bad Request Response too Big ... Test objective: The objective is test that the retrieval of existing VNF Snapshot Packages list fails because response is too big, and perform the JSON schema validation of the failed operation HTTP response. ... Pre-conditions: none ... Reference: Clause 12.4.2.3.2 - ETSI GS NFV-SOL 003 [1] v3.3.1 - ... Config ID: Config_prod_VNFM + ... Config ID: Config_prod_NFVO ... Applicability: NFVO does not support paged response. ... Post-Conditions: none GET VNF Snapshot Packages without Paging support @@ -137,7 +137,7 @@ GET VNF Snapshot Packages as Paged Response ... Test objective: The objective is to test that GET method retrieves the list of existing VNF Snapshot Packages as paged response. ... Pre-conditions: none ... Reference: Clause 12.4.2.3.2 - ETSI GS NFV-SOL 003 [1] v3.3.1 - ... Config ID: Config_prod_VNFM + ... Config ID: Config_prod_NFVO ... Applicability: NFVO supports paged response. ... Post-Conditions: none GET VNF Snapshot Packages with Paging support @@ -150,7 +150,7 @@ PUT VNF Snapshot Packages - Method not implemented ... Test objective: The objective is to test that PUT method is not implemented ... Pre-conditions: none ... Reference: Clause 12.4.2.3.3 - ETSI GS NFV-SOL 003 [1] v3.3.1 - ... Config ID: Config_prod_VNFM + ... Config ID: Config_prod_NFVO ... Applicability: none ... Post-Conditions: none PUT VNF Snapshot Packages @@ -162,7 +162,7 @@ PATCH VNF Snapshot Packages - Method not implemented ... Test objective: The objective is to test that PATCH method is not implemented ... Pre-conditions: none ... Reference: Clause 12.4.2.3.4 - ETSI GS NFV-SOL 003 [1] v3.3.1 - ... Config ID: Config_prod_VNFM + ... Config ID: Config_prod_NFVO ... Applicability: none ... Post-Conditions: none PATCH VNF Snapshot Packages @@ -174,7 +174,7 @@ DELETE VNF Snapshot Packages - Method not implemented ... Test objective: The objective is to test that DELETE method is not implemented ... Pre-conditions: none ... Reference: Clause 12.4.2.3.5 - ETSI GS NFV-SOL 003 [1] v3.3.1 - ... Config ID: Config_prod_VNFM + ... Config ID: Config_prod_NFVO ... Applicability: none ... Post-Conditions: VNF snapshot package is not deleted DELETE VNF Snapshot Packages diff --git a/SOL003/VNFSnapshotPackageManagement-API/VnfSnapshotPackageManagementKeywords.robot b/SOL003/VNFSnapshotPackageManagement-API/VnfSnapshotPackageManagementKeywords.robot index ac4c4a0fa..0100f7d55 100644 --- a/SOL003/VNFSnapshotPackageManagement-API/VnfSnapshotPackageManagementKeywords.robot +++ b/SOL003/VNFSnapshotPackageManagement-API/VnfSnapshotPackageManagementKeywords.robot @@ -1,6 +1,6 @@ *** Settings *** Resource environment/variables.txt -Library REST ${VNFM_SCHEMA}://${VNFM_HOST}:${VNFM_PORT} ssl_verify=false +Library REST ${NFVO_SCHEMA}://${NFVO_HOST}:${NFVO_PORT} ssl_verify=false Library DependencyLibrary Library JSONLibrary Library JSONSchemaLibrary schemas/ -- GitLab From cdfc8e5433ea9ea61e82dc0380f5be629702eee8 Mon Sep 17 00:00:00 2001 From: hammad zafar Date: Mon, 8 Mar 2021 19:49:41 +0500 Subject: [PATCH 3/6] minor fix in variable name --- .../VnfSnapshotPackageManagementKeywords.robot | 2 +- .../VNFSnapshotPackageManagement-API/environment/variables.txt | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/SOL003/VNFSnapshotPackageManagement-API/VnfSnapshotPackageManagementKeywords.robot b/SOL003/VNFSnapshotPackageManagement-API/VnfSnapshotPackageManagementKeywords.robot index 0100f7d55..2ae5c0aa2 100644 --- a/SOL003/VNFSnapshotPackageManagement-API/VnfSnapshotPackageManagementKeywords.robot +++ b/SOL003/VNFSnapshotPackageManagement-API/VnfSnapshotPackageManagementKeywords.robot @@ -220,7 +220,7 @@ GET individual VNF Snapshot Package with invalid URI Set Headers {"Accept":"${ACCEPT_JSON}"} Set Headers {"Content-Type": "${CONTENT_TYPE_JSON}"} Run Keyword If ${AUTH_USAGE} == 1 Set Headers {"${AUTHORIZATION_HEADER}":"${AUTHORIZATION_TOKEN}"} - Get ${apiRoot}/${apiName}/${apiMajorVersion}/vnf_snapshot_packages/${invalidVnfSnapshotInfoId} + Get ${apiRoot}/${apiName}/${apiMajorVersion}/vnf_snapshot_packages/${invalidVnfSnapshotPkgId} ${outputResponse}= Output response Set Global Variable ${response} ${outputResponse} diff --git a/SOL003/VNFSnapshotPackageManagement-API/environment/variables.txt b/SOL003/VNFSnapshotPackageManagement-API/environment/variables.txt index 845607daf..130ed7b5d 100644 --- a/SOL003/VNFSnapshotPackageManagement-API/environment/variables.txt +++ b/SOL003/VNFSnapshotPackageManagement-API/environment/variables.txt @@ -94,5 +94,5 @@ ${VAR_SEPERATOR} & ${callbackResp} localhost ${vnfSnapshotPkgId} -${invalidVnfSnapshotInfoId} +${invalidVnfSnapshotPkgId} ${vnfSnapshotPkgId_notInAvailableState} \ No newline at end of file -- GitLab From 160f811574312118529a0d2702c1c3eaa28e40ec Mon Sep 17 00:00:00 2001 From: hammad zafar Date: Wed, 10 Mar 2021 13:24:56 +0500 Subject: [PATCH 4/6] minor bug fixes and an additional test for filter based quering of VNFSnapshotPackages resource --- .../IndividualVNFSnapshotPackage.robot | 2 +- .../VNFSnapshotPackages.robot | 13 +++++++++++++ .../VnfSnapshotPackageManagementKeywords.robot | 13 +++++++++++-- .../environment/variables.txt | 2 +- .../schemas/ProblemDetails.schema.json | 1 + 5 files changed, 27 insertions(+), 4 deletions(-) create mode 100644 SOL003/VNFSnapshotPackageManagement-API/schemas/ProblemDetails.schema.json diff --git a/SOL003/VNFSnapshotPackageManagement-API/IndividualVNFSnapshotPackage.robot b/SOL003/VNFSnapshotPackageManagement-API/IndividualVNFSnapshotPackage.robot index 082970684..61a4f53a0 100644 --- a/SOL003/VNFSnapshotPackageManagement-API/IndividualVNFSnapshotPackage.robot +++ b/SOL003/VNFSnapshotPackageManagement-API/IndividualVNFSnapshotPackage.robot @@ -17,7 +17,7 @@ POST Individual VNF Snapshot Package - Method not implemented GET Information about an individual VNF Snapshot Package - SUCCESSFUL [Documentation] Test ID: 7.3.8.3.2 ... Test title: GET Information about an individual VNF Snapshot Package - SUCCESSFUL - ... Test objective: The objective is to create a new VNF Snapshot Package resource + ... Test objective: The objective is to query information about a VNF Snapshot Package resource ... Pre-conditions: none ... Reference: Clause 12.4.3.3.2 - ETSI GS NFV-SOL 003 [1] v3.3.1 ... Config ID: Config_prod_NFVO diff --git a/SOL003/VNFSnapshotPackageManagement-API/VNFSnapshotPackages.robot b/SOL003/VNFSnapshotPackageManagement-API/VNFSnapshotPackages.robot index b5de47fe8..19060b7ab 100644 --- a/SOL003/VNFSnapshotPackageManagement-API/VNFSnapshotPackages.robot +++ b/SOL003/VNFSnapshotPackageManagement-API/VNFSnapshotPackages.robot @@ -179,3 +179,16 @@ DELETE VNF Snapshot Packages - Method not implemented ... Post-Conditions: VNF snapshot package is not deleted DELETE VNF Snapshot Packages Check HTTP Response Status Code Is 405 + +GET information about multiple VNF Snapshot Packages using filter + [Documentation] Test ID: 7.3.8.2.15 + ... Test title: GET information about multiple VNF Snapshot Packages using filter + ... Test objective: The objective is to get information about multiples VNF Snapshot Packages using filter + ... Pre-conditions: none + ... Reference: Clause 12.4.2.3.2 - ETSI GS NFV-SOL 003 [1] v3.3.1 + ... Config ID: Config_prod_NFVO + ... Applicability: none + ... Post-Conditions: none + GET multiple VNF Snapshot Packages using filter + Check HTTP Response Status Code Is 200 + Check HTTP Response Body Json Schema Is VnfSnapshotPkgInfos diff --git a/SOL003/VNFSnapshotPackageManagement-API/VnfSnapshotPackageManagementKeywords.robot b/SOL003/VNFSnapshotPackageManagement-API/VnfSnapshotPackageManagementKeywords.robot index 2ae5c0aa2..9a74ba0f6 100644 --- a/SOL003/VNFSnapshotPackageManagement-API/VnfSnapshotPackageManagementKeywords.robot +++ b/SOL003/VNFSnapshotPackageManagement-API/VnfSnapshotPackageManagementKeywords.robot @@ -120,7 +120,16 @@ GET multiple VNF Snapshot Packages with bad filter Set Headers {"Accept":"${ACCEPT_JSON}"} Set Headers {"Content-Type": "${CONTENT_TYPE_JSON}"} Run Keyword If ${AUTH_USAGE} == 1 Set Headers {"${AUTHORIZATION_HEADER}":"${AUTHORIZATION_TOKEN}"} - GET ${apiRoot}/${apiName}/${apiMajorVersion}/vnf_snapshot_packages?fields=wrong_field + GET ${apiRoot}/${apiName}/${apiMajorVersion}/vnf_snapshot_packages?${NEG_FILTER} + ${outputResponse}= Output response + Set Global Variable ${response} ${outputResponse} + +GET multiple VNF Snapshot Packages using filter + Log Query VNF The GET method queries information about multiple VNF Snapshot Packages. + Set Headers {"Accept":"${ACCEPT_JSON}"} + Set Headers {"Content-Type": "${CONTENT_TYPE_JSON}"} + Run Keyword If ${AUTH_USAGE} == 1 Set Headers {"${AUTHORIZATION_HEADER}":"${AUTHORIZATION_TOKEN}"} + GET ${apiRoot}/${apiName}/${apiMajorVersion}/vnf_snapshot_packages?${POS_FILTER} ${outputResponse}= Output response Set Global Variable ${response} ${outputResponse} @@ -128,7 +137,7 @@ GET multiple VNF Snapshot Packages with all_fields attribute selector Log Query status information about multiple VNF Snapshot Packages, using fields Set Headers {"Accept": "${ACCEPT_JSON}"} Run Keyword If ${AUTH_USAGE} == 1 Set Headers {"${AUTHORIZATION_HEADER}":"${AUTHORIZATION_TOKEN}"} - GET ${apiRoot}/${apiName}/${apiMajorVersion}/vnf_snapshot_packages?exclude_default + GET ${apiRoot}/${apiName}/${apiMajorVersion}/vnf_snapshot_packages?all_fields ${output}= Output response Set Suite Variable ${response} ${output} diff --git a/SOL003/VNFSnapshotPackageManagement-API/environment/variables.txt b/SOL003/VNFSnapshotPackageManagement-API/environment/variables.txt index 130ed7b5d..9cfcb189e 100644 --- a/SOL003/VNFSnapshotPackageManagement-API/environment/variables.txt +++ b/SOL003/VNFSnapshotPackageManagement-API/environment/variables.txt @@ -86,7 +86,7 @@ ${vndEncryptedArtifactID} encryptedId ${length} 1024 -${POS_FILTER} vnfdId=41fdd38a-3d4c-465c-83e0-f80e014425f8 ,vnfProvider=NXW # Positive case, suing compiant fields name for filtering get request +${POS_FILTER} id=41fdd38a-3d4c-465c-83e0-f80e014425f8 ,vnfProvider=NXW # Positive case, suing compiant fields name for filtering get request ${NEG_FILTER} nfvId=41fdd38a-3d4c-465c-83e0-f80e014425f8 # Negative case, using wrong name of field ${fields} softwareImages,additionalArtifacts ${VAR_SEPERATOR} & diff --git a/SOL003/VNFSnapshotPackageManagement-API/schemas/ProblemDetails.schema.json b/SOL003/VNFSnapshotPackageManagement-API/schemas/ProblemDetails.schema.json new file mode 100644 index 000000000..2af3ef9b3 --- /dev/null +++ b/SOL003/VNFSnapshotPackageManagement-API/schemas/ProblemDetails.schema.json @@ -0,0 +1 @@ +{ "description": "The definition of the general \"ProblemDetails\" data structure from IETF RFC 7807 [19] is reproduced inthis structure. Compared to the general framework defined in IETF RFC 7807 [19], the \"status\" and \"detail\" attributes are mandated to be included by the present document, to ensure that the response contains additional textual information about an error. IETF RFC 7807 [19] foresees extensibility of the \"ProblemDetails\" type. It is possible that particular APIs in the present document, or particular implementations, define extensions to define additional attributes that provide more information about the error. The description column only provides some explanation of the meaning to Facilitate understanding of the design. For a full description, see IETF RFC 7807 [19].\n", "type": "object", "required": [ "status", "detail" ], "properties": { "type": { "description": "A URI reference according to IETF RFC 3986 [5] that identifies the problem type. It is encouraged that the URI provides human-readable documentation for the problem (e.g. using HTML) when dereferenced. When this member is not present, its value is assumed to be \"about:blank\".\n", "type": "string", "format": "URI" }, "title": { "description": "A short, human-readable summary of the problem type. It should not change from occurrence to occurrence of the problem, except for purposes of localization. If type is given and other than \"about:blank\", this attribute shall also be provided. A short, human-readable summary of the problem type. It SHOULD NOT change from occurrence to occurrence of the problem, except for purposes of localization (e.g., using proactive content negotiation; see [RFC7231], Section 3.4).\n", "type": "string" }, "status": { "description": "The HTTP status code for this occurrence of the problem. The HTTP status code ([RFC7231], Section 6) generated by the origin server for this occurrence of the problem.\n", "type": "integer" }, "detail": { "description": "A human-readable explanation specific to this occurrence of the problem.\n", "type": "string" }, "instance": { "description": "A URI reference that identifies the specific occurrence of the problem. It may yield further information if dereferenced.\n", "type": "string", "format": "URI" } }} \ No newline at end of file -- GitLab From 4269e6aac1d4165b2b75c9127464fd91cdd9dab2 Mon Sep 17 00:00:00 2001 From: hammad zafar Date: Wed, 10 Mar 2021 15:54:08 +0500 Subject: [PATCH 5/6] minor fix in variable value --- .../VNFSnapshotPackageManagement-API/environment/variables.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/SOL003/VNFSnapshotPackageManagement-API/environment/variables.txt b/SOL003/VNFSnapshotPackageManagement-API/environment/variables.txt index 9cfcb189e..4ccd69c8a 100644 --- a/SOL003/VNFSnapshotPackageManagement-API/environment/variables.txt +++ b/SOL003/VNFSnapshotPackageManagement-API/environment/variables.txt @@ -88,7 +88,7 @@ ${length} 1024 ${POS_FILTER} id=41fdd38a-3d4c-465c-83e0-f80e014425f8 ,vnfProvider=NXW # Positive case, suing compiant fields name for filtering get request ${NEG_FILTER} nfvId=41fdd38a-3d4c-465c-83e0-f80e014425f8 # Negative case, using wrong name of field -${fields} softwareImages,additionalArtifacts +${fields} failureDetails ${VAR_SEPERATOR} & ${callbackResp} localhost -- GitLab From 2d8dc96e075443659452107665086ab8018aa19d Mon Sep 17 00:00:00 2001 From: hammad zafar Date: Wed, 10 Mar 2021 16:43:00 +0500 Subject: [PATCH 6/6] fixed Content-Length and Content-Range checks --- .../IndividualVNFSnapshotPackageArtifact.robot | 1 + .../VNFSnapshotPackageContent.robot | 1 + .../VnfSnapshotPackageManagementKeywords.robot | 8 +++++++- .../environment/variables.txt | 2 +- 4 files changed, 10 insertions(+), 2 deletions(-) diff --git a/SOL003/VNFSnapshotPackageManagement-API/IndividualVNFSnapshotPackageArtifact.robot b/SOL003/VNFSnapshotPackageManagement-API/IndividualVNFSnapshotPackageArtifact.robot index 44da2f1e1..e850c7284 100644 --- a/SOL003/VNFSnapshotPackageManagement-API/IndividualVNFSnapshotPackageArtifact.robot +++ b/SOL003/VNFSnapshotPackageManagement-API/IndividualVNFSnapshotPackageArtifact.robot @@ -40,6 +40,7 @@ GET Individual VNF Snapshot Package Artifact - Partial Content Check HTTP Response Status Code Is 206 Check HTTP Content-Type Header Is Set For Package Artifact Check HTTP Content-Range Header Is Set + Check HTTP Content-Length Header Is Set GET Individual VNF Snapshot Package Artifact - Range Request Not Supported [Documentation] Test ID: 7.3.8.5.4 diff --git a/SOL003/VNFSnapshotPackageManagement-API/VNFSnapshotPackageContent.robot b/SOL003/VNFSnapshotPackageManagement-API/VNFSnapshotPackageContent.robot index 9518e4bbf..458d08b71 100644 --- a/SOL003/VNFSnapshotPackageManagement-API/VNFSnapshotPackageContent.robot +++ b/SOL003/VNFSnapshotPackageManagement-API/VNFSnapshotPackageContent.robot @@ -40,6 +40,7 @@ GET VNF Snapshot Package Content - Partial Content Check HTTP Response Status Code Is 206 Check HTTP Content-Type Header Is Set For Package Content Check HTTP Content-Range Header Is Set + Check HTTP Content-Length Header Is Set GET VNF Snapshot Package Content - Range Request Not Supported [Documentation] Test ID: 7.3.8.4.4 diff --git a/SOL003/VNFSnapshotPackageManagement-API/VnfSnapshotPackageManagementKeywords.robot b/SOL003/VNFSnapshotPackageManagement-API/VnfSnapshotPackageManagementKeywords.robot index 9a74ba0f6..0a68e1451 100644 --- a/SOL003/VNFSnapshotPackageManagement-API/VnfSnapshotPackageManagementKeywords.robot +++ b/SOL003/VNFSnapshotPackageManagement-API/VnfSnapshotPackageManagementKeywords.robot @@ -313,9 +313,15 @@ Check HTTP Content-Type Header Is Set For Package Content Check HTTP Content-Range Header Is Set Log Check Content-Range HTTP Header Should Contain ${response['headers']} Content-Range - Should Be Equal As Strings ${response['headers']['Content-Range']} ${range} + Should Be Equal As Strings ${response['headers']['Content-Range']} ${range}/${full_length} Log Header Content-Range is present +Check HTTP Content-Length Header Is Set + Log Check Content-Length HTTP Header + Should Contain ${response['headers']} Content-Length + Should Be Equal As Strings ${response['headers']['Content-Length']} ${full_length} + Log Header Content-Length is present + PUT VNF Snapshot Package Content log Trying to perform a PUT. This method should not be implemented Set Headers {"Accept":"${ACCEPT_ZIP}"} diff --git a/SOL003/VNFSnapshotPackageManagement-API/environment/variables.txt b/SOL003/VNFSnapshotPackageManagement-API/environment/variables.txt index 4ccd69c8a..c7b18c060 100644 --- a/SOL003/VNFSnapshotPackageManagement-API/environment/variables.txt +++ b/SOL003/VNFSnapshotPackageManagement-API/environment/variables.txt @@ -77,7 +77,7 @@ ${artifactPath} artifactPath ${CONTENT_TYPE_OCTET} application/octet-stream ${NFVO_RANGE_OK} 1 # If 1 means that Range is supported by the NFVO ${range} bytes=0-1023 -${full_size} 2000 # Size of the requested artifact to be downloaded via partial downloads +${full_length} 2000 # Size of the requested artifact to be downloaded via partial downloads ${erroneousRange} bytes=10000000-1000000000 # Requesting a out of range number of bytes ${vnfPackageOctetStreamId} octetStreamPkgId ${vnfdOctetStreamId} octetStreamVnfdId -- GitLab