diff options
author | Daniel Rose <dr695h@att.com> | 2017-07-27 20:23:07 +0000 |
---|---|---|
committer | Gerrit Code Review <gerrit@onap.org> | 2017-07-27 20:23:07 +0000 |
commit | 8d6913f1a512f6185b7dd00ca688f71cafebefff (patch) | |
tree | 4eefa49340698a7818304eea2b606199e19c75fd | |
parent | 41e03d2a96990ed8e2eb0e42f0a28deeb3981064 (diff) | |
parent | bf5a3a3745c9669dd6eeea3d2ef5b3bbaa3e9f74 (diff) |
Merge "[TEST-45] support injectable ips"
-rw-r--r-- | robot/resources/aai/aai_interface.robot | 10 | ||||
-rw-r--r-- | robot/resources/appc_interface.robot | 10 | ||||
-rw-r--r-- | robot/resources/asdc_interface.robot | 31 | ||||
-rw-r--r-- | robot/resources/dcae_interface.robot | 5 | ||||
-rw-r--r-- | robot/resources/demo_preload.robot | 46 | ||||
-rw-r--r-- | robot/resources/heatbridge.robot | 2 | ||||
-rw-r--r-- | robot/resources/mr_interface.robot | 4 | ||||
-rw-r--r-- | robot/resources/mso_interface.robot | 11 | ||||
-rw-r--r-- | robot/resources/openstack/keystone_interface.robot | 2 | ||||
-rw-r--r-- | robot/resources/policy_interface.robot | 18 | ||||
-rw-r--r-- | robot/resources/portal_interface.robot | 3 | ||||
-rw-r--r-- | robot/resources/sdngc_interface.robot | 4 | ||||
-rw-r--r-- | robot/resources/vid/teardown_vid.robot | 3 | ||||
-rw-r--r-- | robot/resources/vid/vid_interface.robot | 56 |
14 files changed, 107 insertions, 98 deletions
diff --git a/robot/resources/aai/aai_interface.robot b/robot/resources/aai/aai_interface.robot index 49f98f0c..790fa66f 100644 --- a/robot/resources/aai/aai_interface.robot +++ b/robot/resources/aai/aai_interface.robot @@ -8,6 +8,8 @@ Resource ../global_properties.robot *** Variables *** ${AAI_HEALTH_PATH} /aai/util/echo?action=long ${VERSIONED_INDEX_PATH} /aai/v8 +${AAI_FRONTEND_ENDPOINT} ${GLOBAL_AAI_SERVER_PROTOCOL}://${GLOBAL_INJECTED_AAI1_IP_ADDR}:${GLOBAL_AAI_SERVER_PORT} + *** Keywords *** Run A&AI Health Check @@ -20,7 +22,7 @@ Run A&AI Get Request [Arguments] ${data_path} Disable Warnings ${auth}= Create List ${GLOBAL_AAI_USERNAME} ${GLOBAL_AAI_PASSWORD} - ${session}= Create Session aai ${GLOBAL_AAI_SERVER_URL} auth=${auth} + ${session}= Create Session aai ${AAI_FRONTEND_ENDPOINT} auth=${auth} ${uuid}= Generate UUID ${headers}= Create Dictionary Accept=application/json Content-Type=application/json X-TransactionId=${GLOBAL_APPLICATION_ID}-${uuid} X-FromAppId=${GLOBAL_APPLICATION_ID} ${resp}= Get Request aai ${data_path} headers=${headers} @@ -32,7 +34,7 @@ Run A&AI Put Request [Arguments] ${data_path} ${data} Disable Warnings ${auth}= Create List ${GLOBAL_AAI_USERNAME} ${GLOBAL_AAI_PASSWORD} - ${session}= Create Session aai ${GLOBAL_AAI_SERVER_URL} auth=${auth} + ${session}= Create Session aai ${AAI_FRONTEND_ENDPOINT} auth=${auth} ${uuid}= Generate UUID ${headers}= Create Dictionary Accept=application/json Content-Type=application/json X-TransactionId=${GLOBAL_APPLICATION_ID}-${uuid} X-FromAppId=${GLOBAL_APPLICATION_ID} ${resp}= Put Request aai ${data_path} data=${data} headers=${headers} @@ -44,7 +46,7 @@ Run A&AI Post Request [Arguments] ${data_path} ${data} Disable Warnings ${auth}= Create List ${GLOBAL_AAI_USERNAME} ${GLOBAL_AAI_PASSWORD} - ${session}= Create Session aai ${GLOBAL_AAI_SERVER_URL} auth=${auth} + ${session}= Create Session aai ${AAI_FRONTEND_ENDPOINT} auth=${auth} ${uuid}= Generate UUID ${headers}= Create Dictionary Accept=application/json Content-Type=application/json X-TransactionId=${GLOBAL_APPLICATION_ID}-${uuid} X-FromAppId=${GLOBAL_APPLICATION_ID} ${resp}= Post Request aai ${data_path} data=${data} headers=${headers} @@ -56,7 +58,7 @@ Run A&AI Delete Request [Arguments] ${data_path} ${resource_version} Disable Warnings ${auth}= Create List ${GLOBAL_AAI_USERNAME} ${GLOBAL_AAI_PASSWORD} - ${session}= Create Session aai ${GLOBAL_AAI_SERVER_URL} auth=${auth} + ${session}= Create Session aai ${AAI_FRONTEND_ENDPOINT} auth=${auth} ${uuid}= Generate UUID ${headers}= Create Dictionary Accept=application/json Content-Type=application/json X-TransactionId=${GLOBAL_APPLICATION_ID}-${uuid} X-FromAppId=${GLOBAL_APPLICATION_ID} ${resp}= Delete Request aai ${data_path}?resource-version=${resource_version} headers=${headers} diff --git a/robot/resources/appc_interface.robot b/robot/resources/appc_interface.robot index 2dbd979b..289d1d7c 100644 --- a/robot/resources/appc_interface.robot +++ b/robot/resources/appc_interface.robot @@ -11,6 +11,8 @@ ${APPC_INDEX_PATH} /restconf ${APPC_HEALTHCHECK_OPERATION_PATH} /operations/SLI-API:healthcheck ${APPC_CREATE_MOUNTPOINT_PATH} /config/network-topology:network-topology/topology/topology-netconf/node/ ${APPC_MOUNT_XML} robot/assets/templates/appc/vnf_mount.template +${APPC_ENDPOINT} ${GLOBAL_APPC_SERVER_PROTOCOL}://${GLOBAL_INJECTED_APPC_IP_ADDR}:${GLOBAL_APPC_SERVER_PORT} + *** Keywords *** Run APPC Health Check @@ -23,8 +25,8 @@ Run APPC Post Request [Documentation] Runs an APPC post request [Arguments] ${data_path} ${data} ${content}=json ${auth}= Create List ${GLOBAL_APPC_USERNAME} ${GLOBAL_APPC_PASSWORD} - Log Creating session ${GLOBAL_APPC_SERVER} - ${session}= Create Session appc ${GLOBAL_APPC_SERVER} auth=${auth} + Log Creating session ${APPC_ENDPOINT} + ${session}= Create Session appc ${APPC_ENDPOINT} auth=${auth} ${uuid}= Generate UUID ${headers}= Create Dictionary Accept=application/${content} Content-Type=application/${content} X-TransactionId=${GLOBAL_APPLICATION_ID}-${uuid} X-FromAppId=${GLOBAL_APPLICATION_ID} ${resp}= Post Request appc ${data_path} data=${data} headers=${headers} @@ -35,8 +37,8 @@ Run APPC Put Request [Documentation] Runs an APPC post request [Arguments] ${data_path} ${data} ${content}=xml ${auth}= Create List ${GLOBAL_APPC_USERNAME} ${GLOBAL_APPC_PASSWORD} - Log Creating session ${GLOBAL_APPC_SERVER} - ${session}= Create Session appc ${GLOBAL_APPC_SERVER} auth=${auth} + Log Creating session ${APPC_ENDPOINT} + ${session}= Create Session appc ${APPC_ENDPOINT} auth=${auth} ${uuid}= Generate UUID ${headers}= Create Dictionary Accept=application/${content} Content-Type=application/${content} X-TransactionId=${GLOBAL_APPLICATION_ID}-${uuid} X-FromAppId=${GLOBAL_APPLICATION_ID} ${resp}= Put Request appc ${data_path} data=${data} headers=${headers} diff --git a/robot/resources/asdc_interface.robot b/robot/resources/asdc_interface.robot index bf851d82..463fb6ba 100644 --- a/robot/resources/asdc_interface.robot +++ b/robot/resources/asdc_interface.robot @@ -44,6 +44,9 @@ ${ASDC_CATALOG_RESOURCE_TEMPLATE} robot/assets/templates/asdc/catalog_resourc ${ASDC_USER_REMARKS_TEMPLATE} robot/assets/templates/asdc/user_remarks.template ${ASDC_CATALOG_SERVICE_TEMPLATE} robot/assets/templates/asdc/catalog_service.template ${ASDC_RESOURCE_INSTANCE_TEMPLATE} robot/assets/templates/asdc/resource_instance.template +${ASDC_FE_ENDPOINT} ${GLOBAL_ASDC_SERVER_PROTOCOL}://${GLOBAL_INJECTED_SDC_IP_ADDR}:${GLOBAL_ASDC_FE_PORT} +${ASDC_BE_ENDPOINT} ${GLOBAL_ASDC_SERVER_PROTOCOL}://${GLOBAL_INJECTED_SDC_IP_ADDR}:${GLOBAL_ASDC_BE_PORT} + *** Keywords *** Distribute Model From ASDC [Documentation] goes end to end creating all the asdc objects based ona model and distributing it to the systems. it then returns the service name, vf name and vf module name @@ -397,7 +400,7 @@ Get Catalog Service Distribution Details [Return] ${resp.json()} Run ASDC Health Check [Documentation] Runs a ASDC health check - ${session}= Create Session asdc ${GLOBAL_ASDC_SERVER}:${GLOBAL_ASDC_FE_PORT} + ${session}= Create Session asdc ${ASDC_FE_ENDPOINT} ${uuid}= Generate UUID ${headers}= Create Dictionary Accept=application/json Content-Type=application/json X-TransactionId=${GLOBAL_APPLICATION_ID}-${uuid} X-FromAppId=${GLOBAL_APPLICATION_ID} ${resp}= Get Request asdc ${ASDC_HEALTH_CHECK_PATH} headers=${headers} @@ -410,8 +413,8 @@ Run ASDC Get Request [Documentation] Runs an ASDC get request [Arguments] ${data_path} ${user}=${ASDC_DESIGNER_USER_ID} ${auth}= Create List ${GLOBAL_ASDC_BE_USERNAME} ${GLOBAL_ASDC_BE_PASSWORD} - Log Creating session ${GLOBAL_ASDC_SERVER} - ${session}= Create Session asdc ${GLOBAL_ASDC_SERVER}:${GLOBAL_ASDC_BE_PORT} auth=${auth} + Log Creating session ${ASDC_BE_ENDPOINT} + ${session}= Create Session asdc ${ASDC_BE_ENDPOINT} auth=${auth} ${uuid}= Generate UUID ${headers}= Create Dictionary Accept=application/json Content-Type=application/json USER_ID=${user} X-TransactionId=${GLOBAL_APPLICATION_ID}-${uuid} X-FromAppId=${GLOBAL_APPLICATION_ID} ${resp}= Get Request asdc ${data_path} headers=${headers} @@ -421,8 +424,8 @@ Run ASDC Put Request [Documentation] Runs an ASDC put request [Arguments] ${data_path} ${data} ${user}=${ASDC_DESIGNER_USER_ID} ${auth}= Create List ${GLOBAL_ASDC_BE_USERNAME} ${GLOBAL_ASDC_BE_PASSWORD} - Log Creating session ${GLOBAL_ASDC_SERVER} - ${session}= Create Session asdc ${GLOBAL_ASDC_SERVER}:${GLOBAL_ASDC_BE_PORT} auth=${auth} + Log Creating session ${ASDC_BE_ENDPOINT} + ${session}= Create Session asdc ${ASDC_BE_ENDPOINT} auth=${auth} ${uuid}= Generate UUID ${headers}= Create Dictionary Accept=application/json Content-Type=application/json USER_ID=${user} X-TransactionId=${GLOBAL_APPLICATION_ID}-${uuid} X-FromAppId=${GLOBAL_APPLICATION_ID} ${resp}= Put Request asdc ${data_path} data=${data} headers=${headers} @@ -432,8 +435,8 @@ Run ASDC Post Files Request [Documentation] Runs an ASDC post request [Arguments] ${data_path} ${files} ${user}=${ASDC_DESIGNER_USER_ID} ${auth}= Create List ${GLOBAL_ASDC_BE_USERNAME} ${GLOBAL_ASDC_BE_PASSWORD} - Log Creating session ${GLOBAL_ASDC_SERVER} - ${session}= Create Session asdc ${GLOBAL_ASDC_SERVER}:${GLOBAL_ASDC_BE_PORT} auth=${auth} + Log Creating session ${ASDC_BE_ENDPOINT} + ${session}= Create Session asdc ${ASDC_BE_ENDPOINT} auth=${auth} ${uuid}= Generate UUID ${headers}= Create Dictionary Accept=application/json Content-Type=multipart/form-data USER_ID=${user} X-TransactionId=${GLOBAL_APPLICATION_ID}-${uuid} X-FromAppId=${GLOBAL_APPLICATION_ID} ${resp}= Post Request asdc ${data_path} files=${files} headers=${headers} @@ -443,8 +446,8 @@ Run ASDC Post Request [Documentation] Runs an ASDC post request [Arguments] ${data_path} ${data} ${user}=${ASDC_DESIGNER_USER_ID} ${auth}= Create List ${GLOBAL_ASDC_BE_USERNAME} ${GLOBAL_ASDC_BE_PASSWORD} - Log Creating session ${GLOBAL_ASDC_SERVER} - ${session}= Create Session asdc ${GLOBAL_ASDC_SERVER}:${GLOBAL_ASDC_BE_PORT} auth=${auth} + Log Creating session ${ASDC_BE_ENDPOINT} + ${session}= Create Session asdc ${ASDC_BE_ENDPOINT} auth=${auth} ${uuid}= Generate UUID ${headers}= Create Dictionary Accept=application/json Content-Type=application/json USER_ID=${user} X-TransactionId=${GLOBAL_APPLICATION_ID}-${uuid} X-FromAppId=${GLOBAL_APPLICATION_ID} ${resp}= Post Request asdc ${data_path} data=${data} headers=${headers} @@ -454,8 +457,8 @@ Run ASDC Delete Request [Documentation] Runs an ASDC delete request [Arguments] ${data_path} ${user}=${ASDC_DESIGNER_USER_ID} ${auth}= Create List ${GLOBAL_ASDC_BE_USERNAME} ${GLOBAL_ASDC_BE_PASSWORD} - Log Creating session ${GLOBAL_ASDC_SERVER} - ${session}= Create Session asdc ${GLOBAL_ASDC_SERVER}:${GLOBAL_ASDC_BE_PORT} auth=${auth} + Log Creating session ${ASDC_BE_ENDPOINT} + ${session}= Create Session asdc ${ASDC_BE_ENDPOINT} auth=${auth} ${uuid}= Generate UUID ${headers}= Create Dictionary Accept=application/json Content-Type=application/json USER_ID=${user} X-TransactionId=${GLOBAL_APPLICATION_ID}-${uuid} X-FromAppId=${GLOBAL_APPLICATION_ID} ${resp}= Delete Request asdc ${data_path} headers=${headers} @@ -466,11 +469,11 @@ Open ASDC GUI [Arguments] ${PATH} ## Setup Browever now being managed by the test case ##Setup Browser - Go To ${GLOBAL_ASDC_SERVER}${PATH} + Go To ${ASDC_FE_ENDPOINT}${PATH} Maximize Browser Window Set Selenium Speed ${GLOBAL_SELENIUM_DELAY} Set Browser Implicit Wait ${GLOBAL_SELENIUM_BROWSER_IMPLICIT_WAIT} - Log Logging in to ${GLOBAL_ASDC_SERVER}${PATH} + Log Logging in to ${ASDC_FE_ENDPOINT}${PATH} Title Should Be ASDC Wait Until Page Contains Element xpath=//div/a[text()='SDC'] ${GLOBAL_SELENIUM_BROWSER_WAIT_TIMEOUT} - Log Logged in to ${GLOBAL_PORTAL_SERVER}${PATH} + Log Logged in to ${ASDC_FE_ENDPOINT}${PATH} diff --git a/robot/resources/dcae_interface.robot b/robot/resources/dcae_interface.robot index 62a13af5..392a2b04 100644 --- a/robot/resources/dcae_interface.robot +++ b/robot/resources/dcae_interface.robot @@ -9,13 +9,14 @@ Resource global_properties.robot *** Variables *** ${DCAE_HEALTH_CHECK_BODY} robot/assets/dcae/dcae_healthcheck.json ${DCAE_HEALTH_CHECK_PATH} /gui +${DCAE_ENDPOINT} ${GLOBAL_DCAE_SERVER_PROTOCOL}://${GLOBAL_INJECTED_DCAE_IP_ADDR}:${GLOBAL_DCAE_SERVER_PORT} *** Keywords *** Run DCAE Health Check [Documentation] Runs a DCAE health check ${auth}= Create List ${GLOBAL_DCAE_USERNAME} ${GLOBAL_DCAE_PASSWORD} - Log Creating session ${GLOBAL_DCAE_SERVER} - ${session}= Create Session dcae ${GLOBAL_DCAE_SERVER} auth=${auth} + Log Creating session ${DCAE_ENDPOINT} + ${session}= Create Session dcae ${DCAE_ENDPOINT} auth=${auth} ${uuid}= Generate UUID ${data}= OperatingSystem.Get File ${DCAE_HEALTH_CHECK_BODY} ${headers}= Create Dictionary X-ECOMP-Client-Version=ONAP-R2 action=getTable Accept=application/json Content-Type=application/json X-TransactionId=${GLOBAL_APPLICATION_ID}-${uuid} X-FromAppId=${GLOBAL_APPLICATION_ID} diff --git a/robot/resources/demo_preload.robot b/robot/resources/demo_preload.robot index 00671baa..cb41c573 100644 --- a/robot/resources/demo_preload.robot +++ b/robot/resources/demo_preload.robot @@ -4,6 +4,7 @@ Documentation This test template encapsulates the VNF Orchestration use case. Resource test_templates/model_test_template.robot Resource test_templates/vnf_orchestration_test_template.robot Resource asdc_interface.robot +Resource vid/vid_interface.robot Library UUID Library Collections @@ -104,51 +105,6 @@ Get Persona Model Id ${persona_model_id}= Get From DIctionary ${resp.json()['service-instance'][0]} persona-model-id [Return] ${persona_model_id} - -Get Model UUID from VID - [Documentation] Must use UI since rest call get redirect to portal and get DNS error - ... Search all services and match on the invariantUUID - [Arguments] ${invariantUUID} - Go To ${GLOBAL_VID_SERVER}${VID_ENV}/rest/models/services - ${resp}= Get Text xpath=//body/pre - ${json}= To Json ${resp} - :for ${dict} in @{json} - \ ${uuid}= Get From DIctionary ${dict} uuid - \ ${inv}= Get From DIctionary ${dict} invariantUUID - \ Return From Keyword If "${invariantUUID}" == "${inv}" ${uuid} - [Return] "" - - -Get Module Names from VID - [Documentation] Must use UI since rest call get redirect to portal and get DNS error - ... Given the invariantUUID of the model, mock up the vf_modules list passed to Preload VNF - [Arguments] ${invariantUUID} - ${id}= Get Model UUID from VID ${invariantUUID} - Go To ${GLOBAL_VID_SERVER}${VID_ENV}/rest/models/services/${id} - ${resp}= Get Text xpath=//body/pre - ${json}= To Json ${resp} - ${modules}= Create List - ${vnfs}= Get From Dictionary ${json} vnfs - ${keys}= Get Dictionary Keys ${vnfs} - :for ${key} in @{keys} - \ Add VFModule ${vnfs['${key}']} ${modules} - [Return] ${modules} - -Add VFModule - [Documentation] Dig the vf module names from the VID service model - [Arguments] ${vnf} ${modules} - ${vfModules}= Get From Dictionary ${vnf} vfModules - ${keys}= Get Dictionary Keys ${vfModules} - :for ${key} in @{keys} - \ ${module}= Get From Dictionary ${vfModules} ${key} - \ ${dict}= Create Dictionary name=${module['name']} - \ Append to List ${modules} ${dict} - - - - - - APPC Mount Point [Arguments] ${vf_module_name} Run Openstack Auth Request auth diff --git a/robot/resources/heatbridge.robot b/robot/resources/heatbridge.robot index 3ddeff11..c96ee410 100644 --- a/robot/resources/heatbridge.robot +++ b/robot/resources/heatbridge.robot @@ -38,7 +38,7 @@ Execute Heatbridge ${stack_id}= Get From Dictionary ${stack_info} id ${tenant_id}= Get From Dictionary ${stack_info} OS::project_id ${vnf_id}= Get From Dictionary ${stack_info} vnf_id - ${openstack_identity_url}= Catenate ${GLOBAL_OPENSTACK_KEYSTONE_SERVER}/v2.0 + ${openstack_identity_url}= Catenate ${GLOBAL_INJECTED_KEYSTONE}/v2.0 ${region}= Get Openstack Region ${user} ${pass}= Get Openstack Credentials Init Bridge ${openstack_identity_url} ${user} ${pass} ${tenant_id} ${region} ${GLOBAL_AAI_CLOUD_OWNER} diff --git a/robot/resources/mr_interface.robot b/robot/resources/mr_interface.robot index 11c9348f..717fc7c8 100644 --- a/robot/resources/mr_interface.robot +++ b/robot/resources/mr_interface.robot @@ -8,6 +8,8 @@ Resource global_properties.robot *** Variables *** ${MR_HEALTH_CHECK_PATH} /topics +${MR_ENDPOINT} ${GLOBAL_MR_SERVER_PROTOCOL}://${GLOBAL_INJECTED_MR_IP_ADDR}:${GLOBAL_MR_SERVER_PROTOCOL} + *** Keywords *** Run MR Health Check @@ -19,7 +21,7 @@ Run MR Health Check Run MR Get Request [Documentation] Runs MR Get request [Arguments] ${data_path} - ${session}= Create Session mr ${GLOBAL_MR_SERVER} + ${session}= Create Session mr ${MR_ENDPOINT} ${uuid}= Generate UUID ${headers}= Create Dictionary Accept=application/json Content-Type=application/json X-TransactionId=${GLOBAL_APPLICATION_ID}-${uuid} X-FromAppId=${GLOBAL_APPLICATION_ID} ${resp}= Get Request mr ${data_path} headers=${headers} diff --git a/robot/resources/mso_interface.robot b/robot/resources/mso_interface.robot index b6a53b40..cf6aa643 100644 --- a/robot/resources/mso_interface.robot +++ b/robot/resources/mso_interface.robot @@ -8,12 +8,13 @@ Resource global_properties.robot Resource ../resources/json_templater.robot *** Variables *** ${MSO_HEALTH_CHECK_PATH} /ecomp/mso/infra/globalhealthcheck +${MSO_ENDPOINT} ${GLOBAL_MSO_SERVER_PROTOCOL}://${GLOBAL_INJECTED_MSO_IP_ADDR}:${GLOBAL_MSO_SERVER_PORT} *** Keywords *** Run MSO Health Check [Documentation] Runs an MSO global health check ${auth}= Create List ${GLOBAL_MSO_USERNAME} ${GLOBAL_MSO_PASSWORD} - ${session}= Create Session mso ${GLOBAL_MSO_SERVER} + ${session}= Create Session mso ${MSO_ENDPOINT} ${uuid}= Generate UUID ${headers}= Create Dictionary Accept=text/html Content-Type=text/html X-TransactionId=${GLOBAL_APPLICATION_ID}-${uuid} X-FromAppId=${GLOBAL_APPLICATION_ID} ${resp}= Get Request mso ${MSO_HEALTH_CHECK_PATH} headers=${headers} @@ -23,8 +24,8 @@ Run MSO Get Request [Documentation] Runs an MSO get request [Arguments] ${data_path} ${accept}=application/json ${auth}= Create List ${GLOBAL_MSO_USERNAME} ${GLOBAL_MSO_PASSWORD} - Log Creating session ${GLOBAL_MSO_SERVER} - ${session}= Create Session mso ${GLOBAL_MSO_SERVER} auth=${auth} + Log Creating session ${MSO_ENDPOINT} + ${session}= Create Session mso ${MSO_ENDPOINT} auth=${auth} ${uuid}= Generate UUID ${headers}= Create Dictionary Accept=${accept} Content-Type=application/json X-TransactionId=${GLOBAL_APPLICATION_ID}-${uuid} X-FromAppId=${GLOBAL_APPLICATION_ID} ${resp}= Get Request mso ${data_path} headers=${headers} @@ -35,8 +36,8 @@ Poll MSO Get Request [Documentation] Runs an MSO get request until a certain status is received. valid values are COMPLETE [Arguments] ${data_path} ${status} ${auth}= Create List ${GLOBAL_MSO_USERNAME} ${GLOBAL_MSO_PASSWORD} - Log Creating session ${GLOBAL_MSO_SERVER} - ${session}= Create Session mso ${GLOBAL_MSO_SERVER} auth=${auth} + Log Creating session ${MSO_ENDPOINT} + ${session}= Create Session mso ${MSO_ENDPOINT} auth=${auth} ${uuid}= Generate UUID ${headers}= Create Dictionary Accept=application/json Content-Type=application/json X-TransactionId=${GLOBAL_APPLICATION_ID}-${uuid} X-FromAppId=${GLOBAL_APPLICATION_ID} #do this until it is done diff --git a/robot/resources/openstack/keystone_interface.robot b/robot/resources/openstack/keystone_interface.robot index ef9eca36..1243a193 100644 --- a/robot/resources/openstack/keystone_interface.robot +++ b/robot/resources/openstack/keystone_interface.robot @@ -20,7 +20,7 @@ Run Openstack Auth Request [Documentation] Runs an Openstack Auth Request and returns the token and service catalog. you need to include the token in future request's x-auth-token headers. Service catalog describes what can be called [Arguments] ${alias} ${username}= ${password}= ${username} ${password}= Set Openstack Credentials ${username} ${password} - ${session}= Create Session keystone ${GLOBAL_OPENSTACK_KEYSTONE_SERVER} verify=True + ${session}= Create Session keystone ${GLOBAL_INJECTED_KEYSTONE} verify=True ${uuid}= Generate UUID ${data_template}= OperatingSystem.Get File ${OPENSTACK_KEYSTONE_AUTH_BODY_FILE} ${arguments}= Create Dictionary username=${username} password=${password} tenantName=${GLOBAL_OPENSTACK_TENANT_NAME} diff --git a/robot/resources/policy_interface.robot b/robot/resources/policy_interface.robot index 3bd51f5a..a622ae6c 100644 --- a/robot/resources/policy_interface.robot +++ b/robot/resources/policy_interface.robot @@ -9,14 +9,16 @@ Resource global_properties.robot *** Variables *** ${POLICY_HEALTH_CHECK_PATH} /healthcheck +${POLICY_ENDPOINT} ${GLOBAL_POLICY_SERVER_PROTOCOL}://${GLOBAL_INJECTED_POLICY_IP_ADDR}:${GLOBAL_POLICY_SERVER_PORT} +${POLICY_HEALTHCHECK_ENDPOINT} ${GLOBAL_POLICY_SERVER_PROTOCOL}://${GLOBAL_INJECTED_POLICY_IP_ADDR}:${GLOBAL_POLICY_HEALTHCHECK_PORT} *** Keywords *** Run Policy Health Check [Documentation] Runs Policy Health check ${auth}= Create List ${GLOBAL_POLICY_USERNAME} ${GLOBAL_POLICY_PASSWORD} - Log Creating session ${GLOBAL_POLICY_SERVER_URL} - ${session}= Create Session policy ${GLOBAL_POLICY_HEALTHCHECK_URL} auth=${auth} + Log Creating session ${POLICY_ENDPOINT} + ${session}= Create Session policy ${POLICY_HEALTHCHECK_ENDPOINT} auth=${auth} ${headers}= Create Dictionary Accept=application/json Content-Type=application/json ${resp}= Get Request policy ${POLICY_HEALTH_CHECK_PATH} headers=${headers} Log Received response from policy ${resp.text} @@ -30,8 +32,8 @@ Run Policy Health Check Run Policy Put Request [Documentation] Runs Policy Put request [Arguments] ${data_path} ${data} - Log Creating session ${GLOBAL_POLICY_SERVER_URL} - ${session}= Create Session policy ${GLOBAL_POLICY_SERVER_URL} + Log Creating session ${POLICY_ENDPOINT} + ${session}= Create Session policy ${POLICY_ENDPOINT} ${headers}= Create Dictionary Accept=application/json Content-Type=application/json Authorization=Basic ${GLOBAL_POLICY_AUTH} ClientAuth=${GLOBAL_POLICY_CLIENTAUTH} Environment=TEST ${resp}= Put Request policy ${data_path} data=${data} headers=${headers} Log Received response from policy ${resp.text} @@ -40,8 +42,8 @@ Run Policy Put Request Run Policy Delete Request [Documentation] Runs Policy Delete request [Arguments] ${data_path} ${data} - Log Creating session ${GLOBAL_POLICY_SERVER_URL} - ${session}= Create Session policy ${GLOBAL_POLICY_SERVER_URL} + Log Creating session ${POLICY_ENDPOINT} + ${session}= Create Session policy ${POLICY_ENDPOINT} ${headers}= Create Dictionary Accept=application/json Content-Type=application/json Authorization=Basic ${GLOBAL_POLICY_AUTH} ClientAuth=${GLOBAL_POLICY_CLIENTAUTH} Environment=TEST ${resp}= Delete Request policy ${data_path} data=${data} headers=${headers} Log Received response from policy ${resp.text} @@ -50,8 +52,8 @@ Run Policy Delete Request Run Policy Get Configs Request [Documentation] Runs Policy Get Configs request [Arguments] ${data_path} ${data} - Log Creating session ${GLOBAL_POLICY_SERVER_URL} - ${session}= Create Session policy ${GLOBAL_POLICY_SERVER_URL} + Log Creating session ${POLICY_ENDPOINT} + ${session}= Create Session policy ${POLICY_ENDPOINT} ${headers}= Create Dictionary Accept=application/json Content-Type=application/json Authorization=Basic ${GLOBAL_POLICY_AUTH} ClientAuth=${GLOBAL_POLICY_CLIENTAUTH} ${resp}= Post Request policy ${data_path} data=${data} headers=${headers} Log Received response from policy ${resp.text} diff --git a/robot/resources/portal_interface.robot b/robot/resources/portal_interface.robot index 7d53b378..29205292 100644 --- a/robot/resources/portal_interface.robot +++ b/robot/resources/portal_interface.robot @@ -8,6 +8,7 @@ Resource global_properties.robot *** Variables *** ${PORTAL_HEALTH_CHECK_PATH} /ECOMPPORTAL/portalApi/healthCheck +${PORTAL_ENDPOINT} ${GLOBAL_PORTAL_SERVER_PROTOCOL}://${GLOBAL_INJECTED_PORTAL_IP_ADDR}:${GLOBAL_PORTAL_SERVER_PORT} *** Keywords *** Run Portal Health Check @@ -19,7 +20,7 @@ Run Portal Health Check Run Portal Get Request [Documentation] Runs Portal Get request [Arguments] ${data_path} - ${session}= Create Session portal ${GLOBAL_PORTAL_SERVER} + ${session}= Create Session portal ${PORTAL_ENDPOINT} ${uuid}= Generate UUID ${headers}= Create Dictionary Accept=application/json Content-Type=application/json X-TransactionId=${GLOBAL_APPLICATION_ID}-${uuid} X-FromAppId=${GLOBAL_APPLICATION_ID} ${resp}= Get Request portal ${data_path} headers=${headers} diff --git a/robot/resources/sdngc_interface.robot b/robot/resources/sdngc_interface.robot index ee8d09e8..bb330b3f 100644 --- a/robot/resources/sdngc_interface.robot +++ b/robot/resources/sdngc_interface.robot @@ -19,8 +19,8 @@ ${PRELOAD_VNF_CONFIG_PATH} /config/VNF-API:preload-vnfs/vnf-preload-list ${PRELOAD_VNF_TOPOLOGY_OPERATION_BODY} robot/assets/templates/sdnc/ ${SDNGC_INDEX_PATH} /restconf ${SDNCGC_HEALTHCHECK_OPERATION_PATH} /operations/SLI-API:healthcheck -${SDNGC_REST_ENDPOINT} ${GLOBAL_SDNGC_SERVER}:${GLOBAL_SDNGC_REST_PORT} -${SDNGC_ADMIN_ENDPOINT} ${GLOBAL_SDNGC_SERVER}:${GLOBAL_SDNGC_ADMIN_PORT} +${SDNGC_REST_ENDPOINT} ${GLOBAL_SDNGC_SERVER_PROTOCOL}://${GLOBAL_INJECTED_SDNC_IP_ADDR}:${GLOBAL_SDNGC_REST_PORT} +${SDNGC_ADMIN_ENDPOINT} ${GLOBAL_SDNGC_SERVER_PROTOCOL}://${GLOBAL_INJECTED_SDNC_IP_ADDR}:${GLOBAL_SDNGC_ADMIN_PORT} ${SDNGC_ADMIN_SIGNUP_URL} ${SDNGC_ADMIN_ENDPOINT}/signup ${SDNGC_ADMIN_LOGIN_URL} ${SDNGC_ADMIN_ENDPOINT}/login ${SDNGC_ADMIN_VNF_PROFILE_URL} ${SDNGC_ADMIN_ENDPOINT}/mobility/getVnfProfile diff --git a/robot/resources/vid/teardown_vid.robot b/robot/resources/vid/teardown_vid.robot index b57cd1d4..df40b9ea 100644 --- a/robot/resources/vid/teardown_vid.robot +++ b/robot/resources/vid/teardown_vid.robot @@ -11,8 +11,7 @@ Resource create_service_instance.robot *** Variables *** ${VID_ENV} /vid -${VID_SERVICE_MODELS_SEARCH_CUST} ${GLOBAL_VID_SERVER}${VID_ENV}/serviceModels.htm#/instances/subdetails?selectedSubscriber=\${customer_id} -${VID_SERVICE_MODELS_SEARCH_URL} ${GLOBAL_VID_SERVER}${VID_ENV}/serviceModels.htm#/instances/services +${VID_SERVICE_MODELS_SEARCH_URL} ${GLOBAL_VID_SERVER_PROTOCOL}://${GLOBAL_INJECTED_VID_IP_ADDR}:${GLOBAL_VID_SERVER_PORT}${VID_ENV}/serviceModels.htm#/instances/services *** Keywords *** Teardown VID diff --git a/robot/resources/vid/vid_interface.robot b/robot/resources/vid/vid_interface.robot index 788df0aa..896c3693 100644 --- a/robot/resources/vid/vid_interface.robot +++ b/robot/resources/vid/vid_interface.robot @@ -10,10 +10,11 @@ Resource ../browser_setup.robot *** Variables *** ${VID_ENV} /vid -${VID_LOGIN_URL} ${GLOBAL_VID_SERVER}${VID_ENV}/login.htm +${VID_ENDPOINT} ${GLOBAL_VID_SERVER_PROTOCOL}://${GLOBAL_INJECTED_VID_IP_ADDR}:${GLOBAL_VID_SERVER_PORT} +${VID_LOGIN_URL} ${VID_ENDPOINT}${VID_ENV}/login.htm ${VID_HEALTHCHECK_PATH} ${VID_ENV}/api/v2/users -${VID_HOME_URL} ${GLOBAL_VID_SERVER}${VID_ENV}/welcome.htm -${VID_SERVICE_MODELS_URL} ${GLOBAL_VID_SERVER}${VID_ENV}/serviceModels.htm#/models/services +${VID_HOME_URL} ${VID_ENDPOINT}${VID_ENV}/welcome.htm +${VID_SERVICE_MODELS_URL} ${VID_ENDPOINT}${VID_ENV}/serviceModels.htm#/models/services *** Keywords *** Run VID Health Check @@ -26,8 +27,8 @@ Run VID Get Request [Documentation] Runs an VID get request [Arguments] ${data_path} ${auth}= Create List ${GLOBAL_VID_HEALTH_USERNAME} ${GLOBAL_VID_HEALTH_PASSWORD} - Log Creating session ${GLOBAL_VID_SERVER} - ${session}= Create Session vid ${GLOBAL_VID_SERVER} auth=${auth} + Log Creating session ${VID_ENDPOINT} + ${session}= Create Session vid ${VID_ENDPOINT} auth=${auth} ${uuid}= Generate UUID ${headers}= Create Dictionary username=${GLOBAL_VID_HEALTH_USERNAME} password=${GLOBAL_VID_HEALTH_PASSWORD} Accept=application/json Content-Type=application/json X-TransactionId=${GLOBAL_APPLICATION_ID}-${uuid} X-FromAppId=${GLOBAL_APPLICATION_ID} ${resp}= Get Request vid ${data_path} headers=${headers} @@ -42,14 +43,14 @@ Login To VID GUI Maximize Browser Window Set Selenium Speed ${GLOBAL_SELENIUM_DELAY} Set Browser Implicit Wait ${GLOBAL_SELENIUM_BROWSER_IMPLICIT_WAIT} - Log Logging in to ${GLOBAL_VID_SERVER}${VID_ENV} + Log Logging in to ${VID_ENDPOINT}${VID_ENV} Handle Proxy Warning Title Should Be Login Input Text xpath=//input[@id='loginId'] ${GLOBAL_VID_USERNAME} Input Password xpath=//input[@id='password'] ${GLOBAL_VID_PASSWORD} Click Button xpath=//input[@id='loginBtn'] Wait Until Page Contains Welcome to VID ${GLOBAL_SELENIUM_BROWSER_WAIT_TIMEOUT} - Log Logged in to ${GLOBAL_VID_SERVER}${VID_ENV} + Log Logged in to ${VID_ENDPOINT}${VID_ENV} Go To VID HOME [Documentation] Naviage to VID Home @@ -98,4 +99,43 @@ Parse Instance Id ${request_list}= Split String ${mso_response_text} 202)\n 1 ${json}= To Json ${request_list[1]} ${request_id}= Catenate ${json['requestReferences']['instanceId']} - [Return] ${request_id}
\ No newline at end of file + [Return] ${request_id} + +Get Model UUID from VID + [Documentation] Must use UI since rest call get redirect to portal and get DNS error + ... Search all services and match on the invariantUUID + [Arguments] ${invariantUUID} + Go To ${VID_ENDPOINT}${VID_ENV}/rest/models/services + ${resp}= Get Text xpath=//body/pre + ${json}= To Json ${resp} + :for ${dict} in @{json} + \ ${uuid}= Get From DIctionary ${dict} uuid + \ ${inv}= Get From DIctionary ${dict} invariantUUID + \ Return From Keyword If "${invariantUUID}" == "${inv}" ${uuid} + [Return] "" + + +Get Module Names from VID + [Documentation] Must use UI since rest call get redirect to portal and get DNS error + ... Given the invariantUUID of the model, mock up the vf_modules list passed to Preload VNF + [Arguments] ${invariantUUID} + ${id}= Get Model UUID from VID ${invariantUUID} + Go To ${VID_ENDPOINT}${VID_ENV}/rest/models/services/${id} + ${resp}= Get Text xpath=//body/pre + ${json}= To Json ${resp} + ${modules}= Create List + ${vnfs}= Get From Dictionary ${json} vnfs + ${keys}= Get Dictionary Keys ${vnfs} + :for ${key} in @{keys} + \ Add VFModule ${vnfs['${key}']} ${modules} + [Return] ${modules} + +Add VFModule + [Documentation] Dig the vf module names from the VID service model + [Arguments] ${vnf} ${modules} + ${vfModules}= Get From Dictionary ${vnf} vfModules + ${keys}= Get Dictionary Keys ${vfModules} + :for ${key} in @{keys} + \ ${module}= Get From Dictionary ${vfModules} ${key} + \ ${dict}= Create Dictionary name=${module['name']} + \ Append to List ${modules} ${dict} |