Commit da3aeb89 authored by Najam UI Hassan's avatar Najam UI Hassan
Browse files

new test cases added in VNFpackageArtifact

parent 9105303c
Loading
Loading
Loading
Loading
+77 −0
Original line number Diff line number Diff line
@@ -281,3 +281,80 @@ DELETE Individual OnBoarded VNF Package Artifact - Method not implemented
    Check HTTP Response Status Code Is    405
    Check Postcondition OnBoarded VNF Package Artifact Exist

GET Individual VNF Package Artifact with security information
    [Documentation]    Test ID: 7.3.3.5.23
    ...    Test title: GET Individual VNF Package Artifact with security information
    ...    Test objective: The objective is to test the retrieval of an individual VNF package artifact shall include in the ZIP archive the security information when requested with "include_signature" parameter 
    ...    Pre-conditions: One or more VNF packages are onboarded in the NFVO.
    ...    Reference: Clause 10.4.6.3.2 - ETSI GS NFV-SOL 003 [1] v2.6.1
    ...    Config ID: Config_prod_NFVO
    ...    Applicability: The NFVO cannot determine the content type of the artifact
    ...    Post-Conditions: none
    GET Individual VNF Package Artifact with security information
    Check HTTP Response Status Code Is    200
    Check HTTP Response Header Content-Type Is    application/zip

GET Individual OnBoarded VNF Package Artifact with security information
    [Documentation]    Test ID: 7.3.3.5.24
    ...    Test title: GET Individual OnBoarded VNF Package Artifact with security information
    ...    Test objective: The objective is to test the retrieval of an individual OnBoarded VNF package artifact shall include in the ZIP archive the security information when requested with "include_signature" parameter 
    ...    Pre-conditions: One or more VNF packages are onboarded in the NFVO.
    ...    Reference: Clause 10.4.6.3.2 - ETSI GS NFV-SOL 003 [1] v2.6.1
    ...    Config ID: Config_prod_NFVO
    ...    Applicability: The NFVO cannot determine the content type of the artifact
    ...    Post-Conditions: none
    GET Individual OnBoarded VNF Package Artifact with security information 
    Check HTTP Response Status Code Is    200
    Check HTTP Response Header Content-Type Is    application/zip
    
GET Individual VNF Package Artifact with encrypted artifact
    [Documentation]    Test ID: 7.3.3.5.25
    ...    Test title: GET Individual VNF Package Artifact with encrypted artifact
    ...    Test objective: The objective is to test the retrieval of an individual VNF package artifact shall include an encrypted artifact 
    ...    Pre-conditions: One or more VNF packages are onboarded in the NFVO.
    ...    Reference: Clause 10.4.6.3.2 - ETSI GS NFV-SOL 003 [1] v2.6.1
    ...    Config ID: Config_prod_NFVO
    ...    Applicability: The NFVO cannot determine the content type of the artifact
    ...    Post-Conditions: none
    GET Individual VNF Package Artifact with encrypted artifact
    Check HTTP Response Status Code Is    200
    Check HTTP Response Header Content-Type Is    application/cms

GET Individual OnBoarded VNF Package Artifact with encrypted artifact
    [Documentation]    Test ID: 7.3.3.5.26
    ...    Test title: GET Individual OnBoarded VNF Package Artifact with encrypted artifact
    ...    Test objective: The objective is to test the retrieval of an individual OnBoarded VNF package artifact shall include an encrypted artifact 
    ...    Pre-conditions: One or more VNF packages are onboarded in the NFVO.
    ...    Reference: Clause 10.4.6.3.2 - ETSI GS NFV-SOL 003 [1] v2.6.1
    ...    Config ID: Config_prod_NFVO
    ...    Applicability: The NFVO cannot determine the content type of the artifact
    ...    Post-Conditions: none
    GET Individual OnBoarded VNF Package Artifact with encrypted artifact 
    Check HTTP Response Status Code Is    200
    Check HTTP Response Header Content-Type Is    application/cms
    
GET Individual VNF Package Artifact - Not Acceptable
    [Documentation]    Test ID: 7.3.3.5.27
    ...    Test title: GET Individual VNF Package Artifact with invalid Range Request
    ...    Test objective: The objective is to test that the retrieval of an individual VNF package artifact fails when related request contained an "Accept" header not compatible with the Content type "application/zip" but the "include_signatures" flag was provided
    ...    Pre-conditions: One or more VNF packages are onboarded in the NFVO.
    ...    Reference: Clause 10.4.6.3.2 - ETSI GS NFV-SOL 003 [1] v2.6.1
    ...    Config ID: Config_prod_NFVO
    ...    Applicability: none
    ...    Post-Conditions: none      
    GET Individual VNF Package Artifact with incompatable header
    Check HTTP Response Status Code Is    406
    Check HTTP Response Body Json Schema Is   ProblemDetails
    
GET Individual OnBoarded VNF Package Artifact - Not Acceptable
    [Documentation]    Test ID: 7.3.3.5.28
    ...    Test title: GET Individual OnBoarded VNF Package Artifact with invalid Range Request
    ...    Test objective: The objective is to test that the retrieval of an individual OnBoarded VNF package artifact fails when related request contained an "Accept" header not compatible with the Content type "application/zip" but the "include_signatures" flag was provided
    ...    Pre-conditions: One or more VNF packages are onboarded in the NFVO.
    ...    Reference: Clause 10.4.6.3.2 - ETSI GS NFV-SOL 003 [1] v2.6.1
    ...    Config ID: Config_prod_NFVO
    ...    Applicability: none
    ...    Post-Conditions: none      
    GET Individual OnBoarded VNF Package Artifact with incompatable header
    Check HTTP Response Status Code Is    406
    Check HTTP Response Body Json Schema Is   ProblemDetails
 No newline at end of file
+46 −0
Original line number Diff line number Diff line
@@ -1166,3 +1166,49 @@ Get multi file VNFD in Individual VNF Package with security information
    GET    ${apiRoot}/${apiName}/${apiVersion}/vnf_packages/${vnfPkgZipVNFD}/vnfd/include_signatures
    ${output}=    Output    response
    Set Suite Variable    ${response}    ${output}
    
GET Individual VNF Package Artifact with security information 
    Log    Trying to get a VNF Package Artifact
    Set Headers    {"Accept": "${ACCEPT_ZIP}"}
    Run Keyword If    ${AUTH_USAGE} == 1    Set Headers    {"Authorization": "${AUTHORIZATION}"}
    GET    ${apiRoot}/${apiName}/${apiVersion}/vnf_packages/${vndId}/artifacts/${artifactPath}/include_signatures
    ${output}=    Output    response
    Set Suite Variable    ${response}    ${output}

GET Individual OnBoarded VNF Package Artifact with security information  
    Log    Trying to get a VNF Package Artifact
    Set Headers    {"Accept": "${ACCEPT_ZIP}"}
    Run Keyword If    ${AUTH_USAGE} == 1    Set Headers    {"Authorization": "${AUTHORIZATION}"}
    GET    ${apiRoot}/${apiName}/${apiVersion}/onboarded_vnf_packages/${vndId}/artifacts/${artifactPath}/include_signatures
    ${output}=    Output    response
    Set Suite Variable    ${response}    ${output}
    
GET Individual VNF Package Artifact with encrypted artifact
    Log    Trying to get a VNF Package Artifact
    Run Keyword If    ${AUTH_USAGE} == 1    Set Headers    {"Authorization": "${AUTHORIZATION}"}
    GET    ${apiRoot}/${apiName}/${apiVersion}/vnf_packages/${vndEncryptedArtifactID}/artifacts/${artifactPath}
    ${output}=    Output    response
    Set Suite Variable    ${response}    ${output}

GET Individual OnBoarded VNF Package Artifact with encrypted artifact
    Log    Trying to get a VNF Package Artifact
    Run Keyword If    ${AUTH_USAGE} == 1    Set Headers    {"Authorization": "${AUTHORIZATION}"}
    GET    ${apiRoot}/${apiName}/${apiVersion}/onboarded_vnf_packages/${vndEncryptedArtifactID}/artifacts/${artifactPath}
    ${output}=    Output    response
    Set Suite Variable    ${response}    ${output}
    
GET Individual VNF Package Artifact with incompatable header
    Log    Trying to get a VNF Package Artifact
    Set Headers    {"Accept": "${ACCEPT_PLAIN}"}
    Run Keyword If    ${AUTH_USAGE} == 1    Set Headers    {"Authorization": "${AUTHORIZATION}"}
    GET    ${apiRoot}/${apiName}/${apiVersion}/vnf_packages/${vndId}/artifacts/${artifactPath}/include_signatures
    ${output}=    Output    response
    Set Suite Variable    ${response}    ${output}

GET Individual OnBoarded VNF Package Artifact with incompatable header  
    Log    Trying to get a VNF Package Artifact
    Set Headers    {"Accept": "${ACCEPT_PLAIN}"}
    Run Keyword If    ${AUTH_USAGE} == 1    Set Headers    {"Authorization": "${AUTHORIZATION}"}
    GET    ${apiRoot}/${apiName}/${apiVersion}/onboarded_vnf_packages/${vndId}/artifacts/${artifactPath}/include_signatures
    ${output}=    Output    response
    Set Suite Variable    ${response}    ${output}
 No newline at end of file
+1 −0
Original line number Diff line number Diff line
@@ -7,3 +7,4 @@ ${erroneousRange} bytes=10000000-1000000000 # Requesting a out of range nu
${erroneousVnfPkgId}    erroneousPkgId
${vnfPackageOctetStreamId}    octetStreamPkgId
${vnfdOctetStreamId}    octetStreamVnfdId
${vndEncryptedArtifactID}    encryptedId
 No newline at end of file