Commit 39ecb40e authored by Elian Kraja's avatar Elian Kraja
Browse files

Added schema for SOL005 NSDManagement-API, SOL005/NSPerformanceManagement-API...

Added schema for SOL005 NSDManagement-API, SOL005/NSPerformanceManagement-API and  SOL005/VNFPackageManagement-API without refs
parent 6e2862b6
Loading
Loading
Loading
Loading
+1 −1
Original line number Original line Diff line number Diff line
@@ -22,7 +22,7 @@ GET Single PNF Descriptor
    Log  Validation of Content-Type : OK
    Log  Validation of Content-Type : OK
   Log    Trying to validate response
   Log    Trying to validate response
   ${result}=    Output    response body
   ${result}=    Output    response body
   Validate Json    NsdInfo.schema.json    ${result}
   Validate Json    PnfdInfo.schema.json    ${result}
   Log    Validation OK
   Log    Validation OK




+1 −7
Original line number Original line Diff line number Diff line
@@ -41,13 +41,7 @@ DELETE Subscription
    DELETE    ${apiRoot}/${apiName}/${apiVersion}/subscriptions/${subscriptionId}
    DELETE    ${apiRoot}/${apiName}/${apiVersion}/subscriptions/${subscriptionId}
    Integer    response status    204
    Integer    response status    204
    Log    Received 204 No Content as expected
    Log    Received 204 No Content as expected
    Comment    Log    Trying to get the deleted element

    Comment    Create HTTP Context    ${NFVO_HOST}:${NFVO_PORT}    ${NFVO_SCHEMA}
    Comment    Set Request Header    Accept    ${ACCEPT_JSON}
    Comment    Run Keyword If    ${AUTH_USAGE} == 1    Set Request Header    Authorization    ${AUTHORIZATION}
    Comment    GET    ${apiRoot}/${apiName}/${apiVersion}/subscriptions/${subscriptionId}
    Comment    Response Status Code Should Equal    404
    Comment    Log    The subscriptionId is not present in database


DELETE Subscription - Negative (Not Found)
DELETE Subscription - Negative (Not Found)
    Log    Trying to perform a DELETE on a subscriptionId which doesn't exist
    Log    Trying to perform a DELETE on a subscriptionId which doesn't exist
+1 −1
Original line number Original line Diff line number Diff line
@@ -101,7 +101,7 @@ Post PNFD Onboard Failure Notification
    Clear Requests  ${callback_endpoint}
    Clear Requests  ${callback_endpoint}
    
    
Post PNFD Onboard Notification
Post PNFD Onboard Notification
    ${json}=	Get File	schemas/OPNFDOnboardingNotification.schema.json
    ${json}=	Get File	schemas/PNFDOnboardingNotification.schema.json
    ${BODY}=	evaluate	json.loads('''${json}''')	json
    ${BODY}=	evaluate	json.loads('''${json}''')	json
    Log  Creating mock request and response to handle  NSD Onboard Notification
    Log  Creating mock request and response to handle  NSD Onboard Notification
    &{req}=  Create Mock Request Matcher	POST  ${callback_endpoint}  body_type="JSON_SCHEMA"    body=${BODY}
    &{req}=  Create Mock Request Matcher	POST  ${callback_endpoint}  body_type="JSON_SCHEMA"    body=${BODY}
+1 −38
Original line number Original line Diff line number Diff line
@@ -116,44 +116,7 @@ GET all PNF Descriptors - all_fields
    Validate Json    PnfdInfos.schema.json    ${result}
    Validate Json    PnfdInfos.schema.json    ${result}
    Log    PnfdInfos schema validated
    Log    PnfdInfos schema validated
    ${links}=    Get Value From Json    ${result}    $.._links
    ${links}=    Get Value From Json    ${result}    $.._links
    Validate Json    links.schema.json    ${links[0]}
    Should Not Be Empty    ${links}    
    Log    Validation for _links schema OK

GET all PNF Descriptors - exclude_default
    Log    Trying to get all PNF Descriptors present in the NFVO Catalogue, using exclude_default filter.
    Set Headers    {"Accept": "${ACCEPT_JSON}"}
    Run Keyword If    ${AUTH_USAGE} == 1    Set Headers    {"Authorization": "${AUTHORIZATION}"}
    GET    ${apiRoot}/${apiName}/${apiVersion}/pnf_descriptors?exclude_default
    Integer    response status    200
    ${contentType}=    Output    response headers Content-Type
    Should Contain    ${contentType}    application/json
    Log    Trying to validate response
    ${result}=    Output    response body
    Validate Json    PnfdInfos.schema.json    ${result}
    Log    PnfdInfo schema validated
    Log    Checking missing information for _links element
    ${links}=    Get Value From Json    ${result}    $.._links
    Should Be Empty    ${links}
    Log    _links element is missing as excepted


GET all PNF Descriptors - exclude_fields
    Log    Trying to get all PNF descriptors present in the NFVO Catalogue, using filter params
    Pass Execution If    ${NFVO_FIELDS} == 0    The NFVO is not able to use exclude_fields option
    Set Headers    {"Accept": "${ACCEPT_JSON}"}
    Run Keyword If    ${AUTH_USAGE} == 1    Set Headers    {"Authorization": "${AUTHORIZATION}"}
    GET    ${apiRoot}/${apiName}/${apiVersion}/pnf_descriptors?exclude_fields=${fields}
    Integer    response status    200
    ${contentType}=    Output    response headers Content-Type
    Should Contain    ${contentType}    application/json
    Log    Trying to validate response
    ${result}=    Output    response body
    Validate Json    PnfdInfos.schema.json    ${result}
    Log    PnfdInfo schema validated
    Log    Checking missing information for _links element
    ${links}=    Get Value From Json    ${result}    $.._links
    Should Be Empty    ${links}
    Log    _links element is missing as excepted


POST a new PNF Descriptor
POST a new PNF Descriptor
    Log    Creating a new PNF descriptor
    Log    Creating a new PNF descriptor
+16606 −0

File added.

Preview size limit exceeded, changes collapsed.

Loading