Commit 2e6b7da1 authored by Laurent Vreck's avatar Laurent Vreck
Browse files

Merge branch '3.3.1-dev' into 'Release-3'

Merge "3.3.1 dev" into "release 3" master

See merge request !199
parents ec254083 88e90d66
Loading
Loading
Loading
Loading
+1 −1
Original line number Original line Diff line number Diff line
@@ -3,4 +3,4 @@
/red.xml
/red.xml
build/
build/
dist/
dist/
/libspecs/
libspecs/

.jenkins.sh

0 → 100644
+44 −0
Original line number Original line Diff line number Diff line
#!/bin/bash
# Copyright ETSI 2018
# See: https://forge.etsi.org/etsi-forge-copyright-statement.txt

#set -vx
#set -e

cd "$(dirname "$0")"

run_dir="$(pwd)"

echo "Using git branch $GIT_BRANCH"

bash ./scripts/build-container.sh
ret=$?
if [ "$ret" != "0" ]; then
     echo "build-container.sh failed"
     exit -1
fi

bash ./scripts/run-container.sh "${run_dir}" "$GIT_BRANCH"
ret=$?
if [ "$ret" != "0" ]; then
     echo "run-container.sh failed"
     exit -1
fi

if [[ "$GIT_BRANCH" =~ .*fix-plu$ ]]; then

	apiTestsVersion=$(echo $GIT_BRANCH | cut -d'/' -f 2)
	apiTestsVersion=$(echo $apiTestsVersion | cut -d'-' -f 1)
	echo apiTestsVersion
	
	curl -X POST \
     -F token=${ROBOT_HIVE_TAP_TT_TOKEN} \
     -F ref=master \
     -F "variables[API_TESTS_VERSION]=$apiTestsVersion" \
     -F "variables[TEST_SUITE]=NFV" \
     https://forge.etsi.org/rep/api/v4/projects/484/trigger/pipeline
fi
ret=$?
echo "Final validation result: $ret"
exit $ret
+9 −11
Original line number Original line Diff line number Diff line
# NFV API Conformance Test Specification (NFV-TST 010)
# NFV API Conformance Test Specification (NFV-TST 010)


This repository hosts the NFV API Conformance test specification for 
This repository hosts the NFV API Conformance test specification for 
the APIs defined in ETSI NFV GS [SOL002](https://www.etsi.org/deliver/etsi_gs/NFV-SOL/001_099/002/02.07.01_60/gs_NFV-SOL002v020701p.pdf), 
the APIs defined in ETSI NFV GS [SOL002](https://www.etsi.org/deliver/etsi_gs/NFV-SOL/001_099/002/03.03.01_60/gs_NFV-SOL002v030301p.pdf), 
[SOL003](https://www.etsi.org/deliver/etsi_gs/NFV-SOL/001_099/003/02.07.01_60/gs_NFV-SOL003v020701p.pdf), 
[SOL003](https://www.etsi.org/deliver/etsi_gs/NFV-SOL/001_099/003/03.03.01_60/gs_NFV-SOL003v030301p.pdf), 
[SOL005](https://www.etsi.org/deliver/etsi_gs/NFV-SOL/001_099/005/02.07.01_60/gs_NFV-SOL005v020701p.pdf), in their versions 
[SOL005](https://www.etsi.org/deliver/etsi_gs/NFV-SOL/001_099/005/03.03.01_60/gs_NFV-SOL005v030301p.pdf),
v2.7.1.
[SOL009](https://www.etsi.org/deliver/etsi_gs/NFV-SOL/001_099/009/03.03.01_60/gs_NFV-SOL009v030301p.pdf),
[SOL011](https://www.etsi.org/deliver/etsi_gs/NFV-SOL/001_099/011/03.03.01_60/gs_NFV-SOL011v030301p.pdf), in their versions 
v3.3.1 and [SOL012](https://www.etsi.org/deliver/etsi_gs/NFV-SOL/001_099/012/03.04.01_60/gs_NFV-SOL012v030401p.pdf) in its version v3.4.1.


More information and download is available at [DGS/NFV-TST010ed271](https://portal.etsi.org/webapp/WorkProgram/Report_WorkItem.asp?WKI_ID=58931).
More information and download is available at [DGS/NFV-TST010ed331](https://portal.etsi.org/webapp/WorkProgram/Report_WorkItem.asp?WKI_ID=58931).

**{- Disclaimer: The content of this repository is related to a DRAFT, i.e. a working document, of ETSI ISG NFV.-}**

{-It is provided for information only and is still under development. The content may be updated, replaced, or removed at any time. Do not use as reference material.-}

The latest draft may be downloaded at the [ISG NFV open area](https://docbox.etsi.org/isg/nfv/open/Drafts/).


## Overview
## Overview


@@ -28,3 +24,5 @@ Please report errors, bugs or other issues [here](https://forge.etsi.org/rep/nfv


ETSI Forge uses Gitlab to manage submissions to the repository.
ETSI Forge uses Gitlab to manage submissions to the repository.
For more information on setting up your environment and contributing, you may refer to the [ETSI Forge wiki](https://forge.etsi.org/wiki/index.php/Main_Page).
For more information on setting up your environment and contributing, you may refer to the [ETSI Forge wiki](https://forge.etsi.org/wiki/index.php/Main_Page).

+1 −8
Original line number Original line Diff line number Diff line
@@ -2,12 +2,5 @@


This folder includes the NFV API conformance test descriptions for NFV SOL002 APIs.
This folder includes the NFV API conformance test descriptions for NFV SOL002 APIs.


The reference spec version is v2.7.1: https://www.etsi.org/deliver/etsi_gs/NFV-SOL/001_099/002/02.07.01_60/gs_NFV-SOL002v020701p.pdf
The reference spec version is v3.3.1: https://www.etsi.org/deliver/etsi_gs/NFV-SOL/001_099/002/03.03.01_60/gs_NFV-SOL002v030301p.pdf
## License

Any software in this repository is released under the ETSI Software License.
Licensing information is available in the attached LICENSE file.


Copyright (c) ETSI 2018
+210 −210
Original line number Original line Diff line number Diff line
@@ -11,7 +11,7 @@ POST API Version - Method not implemented
    ...    Test title: POST API version - Method not implemented
    ...    Test title: POST API version - Method not implemented
    ...    Test objective: The objective is to test that POST method is not implemented
    ...    Test objective: The objective is to test that POST method is not implemented
    ...    Pre-conditions: none
    ...    Pre-conditions: none
    ...    Reference: Clause 9.3.3.3.1 - ETSI GS NFV-SOL 013 v2.6.1
    ...    Reference: Clause 9.3.3.3.1 - ETSI GS NFV-SOL 013 v3.3.1
    ...    Config ID: Config_prod_VNFM
    ...    Config ID: Config_prod_VNFM
    ...    Applicability: none
    ...    Applicability: none
    ...    Post-Conditions: none    
    ...    Post-Conditions: none    
@@ -23,7 +23,7 @@ GET API Version
    ...    Test title: GET API Version
    ...    Test title: GET API Version
    ...    Test objective: The objective is to test that GET method successfully return ApiVersionInformation
    ...    Test objective: The objective is to test that GET method successfully return ApiVersionInformation
    ...    Pre-conditions: none
    ...    Pre-conditions: none
    ...    Reference: Clause 9.3.3.3.2 - ETSI GS NFV-SOL 013 v2.6.1
    ...    Reference: Clause 9.3.3.3.2 - ETSI GS NFV-SOL 013 v3.3.1
    ...    Config ID: Config_prod_VNFM
    ...    Config ID: Config_prod_VNFM
    ...    Applicability: none
    ...    Applicability: none
    ...    Post-Conditions: none 
    ...    Post-Conditions: none 
@@ -36,7 +36,7 @@ PUT API Version - Method not implemented
    ...    Test title: PUT API Version - Method not implemented
    ...    Test title: PUT API Version - Method not implemented
    ...    Test objective: The objective is to test that PUT method is not implemented
    ...    Test objective: The objective is to test that PUT method is not implemented
    ...    Pre-conditions: none
    ...    Pre-conditions: none
    ...    Reference: Clause 9.3.3.3.3 - ETSI GS NFV-SOL 013 v2.6.1
    ...    Reference: Clause 9.3.3.3.3 - ETSI GS NFV-SOL 013 v3.3.1
    ...    Config ID: Config_prod_VNFM
    ...    Config ID: Config_prod_VNFM
    ...    Applicability: none
    ...    Applicability: none
    ...    Post-Conditions: none 
    ...    Post-Conditions: none 
@@ -48,7 +48,7 @@ PATCH API Version - Method not implemented
    ...    Test title: PATCH API Version - Method not implemented
    ...    Test title: PATCH API Version - Method not implemented
    ...    Test objective: The objective is to test that PATCH method is not implemented
    ...    Test objective: The objective is to test that PATCH method is not implemented
    ...    Pre-conditions: none
    ...    Pre-conditions: none
    ...    Reference: Clause 9.3.3.3.4 - ETSI GS NFV-SOL 013 v2.6.1
    ...    Reference: Clause 9.3.3.3.4 - ETSI GS NFV-SOL 013 v3.3.1
    ...    Config ID: Config_prod_VNFM
    ...    Config ID: Config_prod_VNFM
    ...    Applicability: none
    ...    Applicability: none
    ...    Post-Conditions: none 
    ...    Post-Conditions: none 
@@ -60,7 +60,7 @@ DELETE API Version - Method not implemented
    ...    Test title: DELETE API Version - Method not implemented
    ...    Test title: DELETE API Version - Method not implemented
    ...    Test objective: The objective is to test that DELETE method is not implemented
    ...    Test objective: The objective is to test that DELETE method is not implemented
    ...    Pre-conditions: none
    ...    Pre-conditions: none
    ...    Reference: Clause 9.3.3.3.5 - ETSI GS NFV-SOL 013 v2.6.1
    ...    Reference: Clause 9.3.3.3.5 - ETSI GS NFV-SOL 013 v3.3.1
    ...    Config ID: Config_prod_VNFM
    ...    Config ID: Config_prod_VNFM
    ...    Applicability: none
    ...    Applicability: none
    ...    Post-Conditions: none 
    ...    Post-Conditions: none 
@@ -72,7 +72,7 @@ POST API Version with apiMajorVerion - Method not implemented
    ...    Test title: POST API version with apiMajorVerion - Method not implemented
    ...    Test title: POST API version with apiMajorVerion - Method not implemented
    ...    Test objective: The objective is to test that POST method is not implemented
    ...    Test objective: The objective is to test that POST method is not implemented
    ...    Pre-conditions: none
    ...    Pre-conditions: none
    ...    Reference: Clause 9.3.3.3.1 - ETSI GS NFV-SOL 013 v2.6.1
    ...    Reference: Clause 9.3.3.3.1 - ETSI GS NFV-SOL 013 v3.3.1
    ...    Config ID: Config_prod_VNFM
    ...    Config ID: Config_prod_VNFM
    ...    Applicability: none
    ...    Applicability: none
    ...    Post-Conditions: none    
    ...    Post-Conditions: none    
@@ -84,7 +84,7 @@ GET API Version with apiMajorVerion
    ...    Test title: GET API Version with apiMajorVerion
    ...    Test title: GET API Version with apiMajorVerion
    ...    Test objective: The objective is to test that GET method successfully return ApiVersionInformation
    ...    Test objective: The objective is to test that GET method successfully return ApiVersionInformation
    ...    Pre-conditions: none
    ...    Pre-conditions: none
    ...    Reference: Clause 9.3.3.3.2 - ETSI GS NFV-SOL 013 v2.6.1
    ...    Reference: Clause 9.3.3.3.2 - ETSI GS NFV-SOL 013 v3.3.1
    ...    Config ID: Config_prod_VNFM
    ...    Config ID: Config_prod_VNFM
    ...    Applicability: none
    ...    Applicability: none
    ...    Post-Conditions: none 
    ...    Post-Conditions: none 
@@ -97,7 +97,7 @@ PUT API Version with apiMajorVerion - Method not implemented
    ...    Test title: PUT API Version with apiMajorVerion - Method not implemented
    ...    Test title: PUT API Version with apiMajorVerion - Method not implemented
    ...    Test objective: The objective is to test that PUT method is not implemented
    ...    Test objective: The objective is to test that PUT method is not implemented
    ...    Pre-conditions: none
    ...    Pre-conditions: none
    ...    Reference: Clause 9.3.3.3.3 - ETSI GS NFV-SOL 013 v2.6.1
    ...    Reference: Clause 9.3.3.3.3 - ETSI GS NFV-SOL 013 v3.3.1
    ...    Config ID: Config_prod_VNFM
    ...    Config ID: Config_prod_VNFM
    ...    Applicability: none
    ...    Applicability: none
    ...    Post-Conditions: none 
    ...    Post-Conditions: none 
@@ -109,7 +109,7 @@ PATCH API Version with apiMajorVerion - Method not implemented
    ...    Test title: PATCH API Version with apiMajorVerion - Method not implemented
    ...    Test title: PATCH API Version with apiMajorVerion - Method not implemented
    ...    Test objective: The objective is to test that PATCH method is not implemented
    ...    Test objective: The objective is to test that PATCH method is not implemented
    ...    Pre-conditions: none
    ...    Pre-conditions: none
    ...    Reference: Clause 9.3.3.3.4 - ETSI GS NFV-SOL 013 v2.6.1
    ...    Reference: Clause 9.3.3.3.4 - ETSI GS NFV-SOL 013 v3.3.1
    ...    Config ID: Config_prod_VNFM
    ...    Config ID: Config_prod_VNFM
    ...    Applicability: none
    ...    Applicability: none
    ...    Post-Conditions: none 
    ...    Post-Conditions: none 
@@ -121,7 +121,7 @@ DELETE API Version with apiMajorVerion - Method not implemented
    ...    Test title: DELETE API Version with apiMajorVerion - Method not implemented
    ...    Test title: DELETE API Version with apiMajorVerion - Method not implemented
    ...    Test objective: The objective is to test that DELETE method is not implemented
    ...    Test objective: The objective is to test that DELETE method is not implemented
    ...    Pre-conditions: none
    ...    Pre-conditions: none
    ...    Reference: Clause 9.3.3.3.5 - ETSI GS NFV-SOL 013 v2.6.1
    ...    Reference: Clause 9.3.3.3.5 - ETSI GS NFV-SOL 013 v3.3.1
    ...    Config ID: Config_prod_VNFM
    ...    Config ID: Config_prod_VNFM
    ...    Applicability: none
    ...    Applicability: none
    ...    Post-Conditions: none 
    ...    Post-Conditions: none 
@@ -131,71 +131,71 @@ DELETE API Version with apiMajorVerion - Method not implemented
*** Keywords ***
*** Keywords ***
POST API Version
POST API Version
    Set Headers    {"Accept":"${ACCEPT}"} 
    Set Headers    {"Accept":"${ACCEPT}"} 
    Run Keyword If    ${AUTH_USAGE} == 1    Set Headers    {"Authorization":"${AUTHORIZATION}"}
    Run Keyword If    ${AUTH_USAGE} == 1    Set Headers    {"${AUTHORIZATION_HEADER}":"${AUTHORIZATION_TOKEN}"}
    Post    ${apiRoot}/${apiName}/api_version
    Post    ${apiRoot}/${apiName}/api_versions
    ${outputResponse}=    Output    response
    ${outputResponse}=    Output    response
	Set Global Variable    ${response}    ${outputResponse} 
	Set Global Variable    ${response}    ${outputResponse} 
	
	
GET API Version
GET API Version
    Set Headers    {"Accept":"${ACCEPT}"} 
    Set Headers    {"Accept":"${ACCEPT}"} 
    Run Keyword If    ${AUTH_USAGE} == 1    Set Headers    {"Authorization":"${AUTHORIZATION}"}
    Run Keyword If    ${AUTH_USAGE} == 1    Set Headers    {"${AUTHORIZATION_HEADER}":"${AUTHORIZATION_TOKEN}"}
    Get    ${apiRoot}/${apiName}/api_version
    Get    ${apiRoot}/${apiName}/api_versions
    ${outputResponse}=    Output    response
    ${outputResponse}=    Output    response
	Set Global Variable    ${response}    ${outputResponse} 
	Set Global Variable    ${response}    ${outputResponse} 
	
	
PUT API Version
PUT API Version
    Set Headers    {"Accept":"${ACCEPT}"} 
    Set Headers    {"Accept":"${ACCEPT}"} 
    Run Keyword If    ${AUTH_USAGE} == 1    Set Headers    {"Authorization":"${AUTHORIZATION}"}
    Run Keyword If    ${AUTH_USAGE} == 1    Set Headers    {"${AUTHORIZATION_HEADER}":"${AUTHORIZATION_TOKEN}"}
    Put    ${apiRoot}/${apiName}/api_version
    Put    ${apiRoot}/${apiName}/api_versions
    ${outputResponse}=    Output    response
    ${outputResponse}=    Output    response
	Set Global Variable    ${response}    ${outputResponse} 
	Set Global Variable    ${response}    ${outputResponse} 
	
	
PATCH API Version
PATCH API Version
    Set Headers    {"Accept":"${ACCEPT}"} 
    Set Headers    {"Accept":"${ACCEPT}"} 
    Run Keyword If    ${AUTH_USAGE} == 1    Set Headers    {"Authorization":"${AUTHORIZATION}"}
    Run Keyword If    ${AUTH_USAGE} == 1    Set Headers    {"${AUTHORIZATION_HEADER}":"${AUTHORIZATION_TOKEN}"}
    Patch    ${apiRoot}/${apiName}/api_version
    Patch    ${apiRoot}/${apiName}/api_versions
    ${outputResponse}=    Output    response
    ${outputResponse}=    Output    response
	Set Global Variable    ${response}    ${outputResponse} 
	Set Global Variable    ${response}    ${outputResponse} 
	
	
DELETE API Version
DELETE API Version
    Set Headers    {"Accept":"${ACCEPT}"} 
    Set Headers    {"Accept":"${ACCEPT}"} 
    Run Keyword If    ${AUTH_USAGE} == 1    Set Headers    {"Authorization":"${AUTHORIZATION}"}
    Run Keyword If    ${AUTH_USAGE} == 1    Set Headers    {"${AUTHORIZATION_HEADER}":"${AUTHORIZATION_TOKEN}"}
    Delete    ${apiRoot}/${apiName}/api_version
    Delete    ${apiRoot}/${apiName}/api_versions
    ${outputResponse}=    Output    response
    ${outputResponse}=    Output    response
	Set Global Variable    ${response}    ${outputResponse} 
	Set Global Variable    ${response}    ${outputResponse} 
	
	
POST API Version with apiMajorVersion
POST API Version with apiMajorVersion
    Set Headers    {"Accept":"${ACCEPT}"} 
    Set Headers    {"Accept":"${ACCEPT}"} 
    Run Keyword If    ${AUTH_USAGE} == 1    Set Headers    {"Authorization":"${AUTHORIZATION}"}
    Run Keyword If    ${AUTH_USAGE} == 1    Set Headers    {"${AUTHORIZATION_HEADER}":"${AUTHORIZATION_TOKEN}"}
    Post    ${apiRoot}/${apiName}/v1/api_version
    Post    ${apiRoot}/${apiName}/${apiMajorVersion}/api_versions
    ${outputResponse}=    Output    response
    ${outputResponse}=    Output    response
	Set Global Variable    ${response}    ${outputResponse} 
	Set Global Variable    ${response}    ${outputResponse} 
	
	
GET API Version with apiMajorVersion
GET API Version with apiMajorVersion
    Set Headers    {"Accept":"${ACCEPT}"} 
    Set Headers    {"Accept":"${ACCEPT}"} 
    Run Keyword If    ${AUTH_USAGE} == 1    Set Headers    {"Authorization":"${AUTHORIZATION}"}
    Run Keyword If    ${AUTH_USAGE} == 1    Set Headers    {"${AUTHORIZATION_HEADER}":"${AUTHORIZATION_TOKEN}"}
    Get    ${apiRoot}/${apiName}/v1/api_version
    Get    ${apiRoot}/${apiName}/${apiMajorVersion}/api_versions
    ${outputResponse}=    Output    response
    ${outputResponse}=    Output    response
	Set Global Variable    ${response}    ${outputResponse} 
	Set Global Variable    ${response}    ${outputResponse} 
	
	
PUT API Version with apiMajorVersion
PUT API Version with apiMajorVersion
    Set Headers    {"Accept":"${ACCEPT}"} 
    Set Headers    {"Accept":"${ACCEPT}"} 
    Run Keyword If    ${AUTH_USAGE} == 1    Set Headers    {"Authorization":"${AUTHORIZATION}"}
    Run Keyword If    ${AUTH_USAGE} == 1    Set Headers    {"${AUTHORIZATION_HEADER}":"${AUTHORIZATION_TOKEN}"}
    Put    ${apiRoot}/${apiName}/v1/api_version
    Put    ${apiRoot}/${apiName}/${apiMajorVersion}/api_versions
    ${outputResponse}=    Output    response
    ${outputResponse}=    Output    response
	Set Global Variable    ${response}    ${outputResponse} 
	Set Global Variable    ${response}    ${outputResponse} 
	
	
PATCH API Version with apiMajorVersion
PATCH API Version with apiMajorVersion
    Set Headers    {"Accept":"${ACCEPT}"} 
    Set Headers    {"Accept":"${ACCEPT}"} 
    Run Keyword If    ${AUTH_USAGE} == 1    Set Headers    {"Authorization":"${AUTHORIZATION}"}
    Run Keyword If    ${AUTH_USAGE} == 1    Set Headers    {"${AUTHORIZATION_HEADER}":"${AUTHORIZATION_TOKEN}"}
    Patch    ${apiRoot}/${apiName}/v1/api_version
    Patch    ${apiRoot}/${apiName}/${apiMajorVersion}/api_versions
    ${outputResponse}=    Output    response
    ${outputResponse}=    Output    response
	Set Global Variable    ${response}    ${outputResponse} 
	Set Global Variable    ${response}    ${outputResponse} 
	
	
DELETE API Version with apiMajorVersion
DELETE API Version with apiMajorVersion
    Set Headers    {"Accept":"${ACCEPT}"} 
    Set Headers    {"Accept":"${ACCEPT}"} 
    Run Keyword If    ${AUTH_USAGE} == 1    Set Headers    {"Authorization":"${AUTHORIZATION}"}
    Run Keyword If    ${AUTH_USAGE} == 1    Set Headers    {"${AUTHORIZATION_HEADER}":"${AUTHORIZATION_TOKEN}"}
    Delete    ${apiRoot}/${apiName}/v1/api_version
    Delete    ${apiRoot}/${apiName}/${apiMajorVersion}/api_versions
    ${outputResponse}=    Output    response
    ${outputResponse}=    Output    response
	Set Global Variable    ${response}    ${outputResponse} 
	Set Global Variable    ${response}    ${outputResponse} 


@@ -206,6 +206,6 @@ Check HTTP Response Status Code Is


Check HTTP Response Body Json Schema Is
Check HTTP Response Body Json Schema Is
    [Arguments]    ${input}
    [Arguments]    ${input}
    ${schema} =    Catenate    ${input}    .schema.json
    ${schema} =    Catenate    SEPARATOR=    ${input}    .schema.json
    Validate Json    ${schema}    ${response['body']}
    Validate Json    ${schema}    ${response['body']}
    Log    Json Schema Validation OK
    Log    Json Schema Validation OK
 No newline at end of file
Loading