summaryrefslogtreecommitdiffstats
path: root/robot/resources
diff options
context:
space:
mode:
Diffstat (limited to 'robot/resources')
-rw-r--r--robot/resources/asdc_interface.robot8
-rw-r--r--robot/resources/dr_interface.robot24
-rw-r--r--robot/resources/global_properties.robot2
-rw-r--r--robot/resources/nbi_interface.robot2
-rw-r--r--robot/resources/openstack/keystone_interface.robot7
-rw-r--r--robot/resources/sdngc_interface.robot6
-rw-r--r--robot/resources/so_interface.robot15
-rw-r--r--robot/resources/test_templates/vnf_orchestration_test_template.robot3
-rw-r--r--robot/resources/vid/vid_interface.robot5
9 files changed, 58 insertions, 14 deletions
diff --git a/robot/resources/asdc_interface.robot b/robot/resources/asdc_interface.robot
index 382821e9..3e33fded 100644
--- a/robot/resources/asdc_interface.robot
+++ b/robot/resources/asdc_interface.robot
@@ -68,7 +68,7 @@ Distribute Model From ASDC
# on certify it gets a new id
${catalog_service_id}= Certify ASDC Catalog Service ${catalog_service_id}
Approve ASDC Catalog Service ${catalog_service_id}
- : FOR ${DIST_INDEX} IN RANGE 3
+ : FOR ${DIST_INDEX} IN RANGE 2
\ Log Distribution Attempt ${DIST_INDEX}
\ Distribute ASDC Catalog Service ${catalog_service_id}
\ ${catalog_service_resp}= Get ASDC Catalog Service ${catalog_service_id}
@@ -408,6 +408,8 @@ Check Catalog Service Distributed
\ Log ${ELEMENT['omfComponentID']}
\ Log ${ELEMENT['status']}
\ ${SO_COMPLETE} Set Variable If (('${ELEMENT['status']}' == 'DISTRIBUTION_COMPLETE_OK')) or ('${SO_COMPLETE}'=='TRUE') TRUE
+ \ Exit For Loop If ('${SO_COMPLETE}'=='TRUE')
+ \ Exit For Loop If ('${ELEMENT['status']}' == 'DISTRIBUTION_COMPLETE_ERROR')
Should Be True ( '${SO_COMPLETE}'=='TRUE') SO Test
Get Catalog Service Distribution Details
[Documentation] gets an asdc catalog Service distrbution details
@@ -421,13 +423,13 @@ Run ASDC Health Check
${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}
- Should Be Equal As Strings ${resp.status_code} 200
+ Should Be Equal As Strings ${resp.status_code} 200 SDC DOWN
${SDC_DE_HEALTH}= Catenate DOWN
@{ITEMS}= Copy List ${resp.json()['componentsInfo']}
:FOR ${ELEMENT} IN @{ITEMS}
\ Log ${ELEMENT['healthCheckStatus']}
\ ${SDC_DE_HEALTH} Set Variable If (('DE' in '${ELEMENT['healthCheckComponent']}') and ('${ELEMENT['healthCheckStatus']}' == 'UP')) or ('${SDC_DE_HEALTH}'=='UP') UP
- Should Be Equal As Strings ${SDC_DE_HEALTH} UP
+ Should Be Equal As Strings ${SDC_DE_HEALTH} UP SDC_DE DOWN
Run ASDC Get Request
[Documentation] Runs an ASDC get request
[Arguments] ${data_path} ${user}=${ASDC_DESIGNER_USER_ID} ${MY_ASDC_BE_ENDPOINT}=${ASDC_BE_ENDPOINT}
diff --git a/robot/resources/dr_interface.robot b/robot/resources/dr_interface.robot
new file mode 100644
index 00000000..ff57435e
--- /dev/null
+++ b/robot/resources/dr_interface.robot
@@ -0,0 +1,24 @@
+*** Settings ***
+Documentation The main interface for interacting with Data-Router.
+Library RequestsLibrary
+
+Resource global_properties.robot
+
+*** Variables ***
+${DR_HEALTH_CHECK_PATH} /internal/fetchProv
+${DR_ENDPOINT} ${GLOBAL_DMAAP_DR_NODE_SERVER_PROTOCOL}://${GLOBAL_INJECTED_DMAAP_DR_NODE_IP_ADDR}:${GLOBAL_DMAAP_DR_NODE_SERVER_PORT}
+
+
+*** Keywords ***
+Run DR Health Check
+ [Documentation] Runs DR Health check
+ ${resp}= Run DR Get Request ${DR_HEALTH_CHECK_PATH}
+ Should Be Equal As Strings ${resp.status_code} 204
+
+Run DR Get Request
+ [Documentation] Runs DR Get request
+ [Arguments] ${data_path}
+ ${session}= Create Session session ${DR_ENDPOINT}
+ ${resp}= Get Request session ${data_path}
+ Log Received response from data router ${resp.text}
+ [Return] ${resp}
diff --git a/robot/resources/global_properties.robot b/robot/resources/global_properties.robot
index e32b01e9..7d8db8e0 100644
--- a/robot/resources/global_properties.robot
+++ b/robot/resources/global_properties.robot
@@ -6,7 +6,7 @@ Documentation store all properties that can change or are used in multipl
*** Variables ***
${GLOBAL_APPLICATION_ID} robot-ete
-${GLOBAL_MSO_STATUS_PATH} /ecomp/mso/infra/orchestrationRequests/v5/
+${GLOBAL_MSO_STATUS_PATH} /onap/so/infra/orchestrationRequests/v6/
${GLOBAL_SELENIUM_BROWSER} chrome
${GLOBAL_SELENIUM_BROWSER_CAPABILITIES} Create Dictionary
${GLOBAL_SELENIUM_DELAY} 0
diff --git a/robot/resources/nbi_interface.robot b/robot/resources/nbi_interface.robot
index 076ecd20..9d5313de 100644
--- a/robot/resources/nbi_interface.robot
+++ b/robot/resources/nbi_interface.robot
@@ -5,7 +5,7 @@ Library RequestsLibrary
Resource global_properties.robot
*** Variables ***
-${NBI_HEALTH_CHECK_PATH} /nbi/api/v1/status
+${NBI_HEALTH_CHECK_PATH} /nbi/api/v3/status
${NBI_ENDPOINT} ${GLOBAL_NBI_SERVER_PROTOCOL}://${GLOBAL_INJECTED_NBI_IP_ADDR}:${GLOBAL_NBI_SERVER_PORT}
diff --git a/robot/resources/openstack/keystone_interface.robot b/robot/resources/openstack/keystone_interface.robot
index 4749eb08..b18674f7 100644
--- a/robot/resources/openstack/keystone_interface.robot
+++ b/robot/resources/openstack/keystone_interface.robot
@@ -54,7 +54,10 @@ Set Openstack Credentials
[Return] ${user} ${pass}
Get Openstack Credentials
- [Return] ${GLOBAL_INJECTED_OPENSTACK_USERNAME} ${GLOBAL_INJECTED_OPENSTACK_PASSWORD}
+ [Documentation] Returns the Decripted Password and openstack username using same api_key.txt as SO
+ ${DECRYPTED_OPENSTACK_PASSWORD}= Run echo -n ${GLOBAL_INJECTED_OPENSTACK_API_KEY} | xxd -r -p | openssl enc -aes-128-ecb -d -nopad -nosalt -K aa3871669d893c7fb8abbcda31b88b4f | tr -d '\x08'
+ [Return] ${GLOBAL_INJECTED_OPENSTACK_USERNAME} ${DECRYPTED_OPENSTACK_PASSWORD}
+
Get Keystone Url And Path
[Documentation] Handle arbitrary keystone identiit url. Add v2.0 if not present.
@@ -63,4 +66,4 @@ Get Keystone Url And Path
${version}= Evaluate ''
${version}= Set Variable If '${OPENSTACK_KEYSTONE_API_VERSION}' not in '${pieces.path}' ${OPENSTACK_KEYSTONE_API_VERSION} ${version}
${path}= Catenate ${pieces.path}${version}
- [Return] ${url} ${path} \ No newline at end of file
+ [Return] ${url} ${path}
diff --git a/robot/resources/sdngc_interface.robot b/robot/resources/sdngc_interface.robot
index 57198dbe..b311e9bd 100644
--- a/robot/resources/sdngc_interface.robot
+++ b/robot/resources/sdngc_interface.robot
@@ -117,7 +117,7 @@ Preload One Vnf Topology
[Arguments] ${service_type_uuid} ${generic_vnf_name} ${generic_vnf_type} ${vf_module_name} ${vf_module_type} ${service} ${filename} ${uuid}
Return From Keyword If '${filename}' == ''
${data_template}= OperatingSystem.Get File ${PRELOAD_VNF_TOPOLOGY_OPERATION_BODY}/preload.template
- ${parameters}= Get Template Parameters ${filename} ${uuid}
+ ${parameters}= Get Template Parameters ${generic_vnf_name} ${filename} ${uuid}
Set To Dictionary ${parameters} generic_vnf_name=${generic_vnf_name} generic_vnf_type=${generic_vnf_type} service_type=${service_type_uuid} vf_module_name=${vf_module_name} vf_module_type=${vf_module_type}
${data}= Fill JSON Template ${data_template} ${parameters}
${put_resp}= Run SDNGC Post Request ${SDNGC_INDEX_PATH}${PRELOAD_VNF_TOPOLOGY_OPERATION_PATH} ${data}
@@ -126,7 +126,7 @@ Preload One Vnf Topology
Should Be Equal As Strings ${get_resp.status_code} 200
Get Template Parameters
- [Arguments] ${template} ${uuid}
+ [Arguments] ${generic_vnf_name} ${template} ${uuid}
${rest} ${suite}= Split String From Right ${SUITE NAME} . 1
${uuid}= Catenate ${uuid}
${hostid}= Get Substring ${uuid} -4
@@ -147,7 +147,7 @@ Get Template Parameters
# update the value map with unique values.
- Set To Dictionary ${valuemap} uuid=${uuid} hostid=${hostid} ecompnet=${ecompnet}
+ Set To Dictionary ${valuemap} uuid=${uuid} hostid=${hostid} ecompnet=${ecompnet} generic_vnf_name=${generic_vnf_name}
#
# Mash together the defaults dict with the test case dict to create the set of
diff --git a/robot/resources/so_interface.robot b/robot/resources/so_interface.robot
index 70faf3bf..8afcd593 100644
--- a/robot/resources/so_interface.robot
+++ b/robot/resources/so_interface.robot
@@ -46,7 +46,7 @@ Run MSO Get ModelInvariantId
${param_dict}= Create Dictionary serviceModelName ${service_model_name}
${param}= Evaluate urllib.urlencode(${param_dict}) urllib
${data_path}= Catenate SEPARATOR= /ecomp/mso/catalog/v2/serviceVnfs? ${param}
- ${resp}= Run MSO Get Request ${data_path}
+ ${resp}= Run MSO Catalog Get Request ${data_path}
Log ${resp.json()}
# ${resp.json()['serviceVnfs'][0]['vfModules'][0]['vfModuleLabel'] should be 'base_vpkg'
${model_invariant_id}= Set Variable NULL
@@ -69,6 +69,19 @@ Run MSO Get Request
Log Received response from mso ${resp.text}
[Return] ${resp}
+Run MSO Catalog Get Request
+ [Documentation] Runs an MSO get request
+ [Arguments] ${data_path} ${accept}=application/json
+ ${auth}= Create List ${GLOBAL_MSO_CATDB_USERNAME} ${GLOBAL_MSO_PASSWORD}
+ Log Creating session ${SO_CATDB_ENDPOINT}
+ ${session}= Create Session so_catdb ${SO_CATDB_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 so_catdb ${data_path} headers=${headers}
+ Log Received response from so_catdb ${resp.text}
+ [Return] ${resp}
+
+
Poll MSO Get Request
[Documentation] Runs an MSO get request until a certain status is received. valid values are COMPLETE
[Arguments] ${data_path} ${status}
diff --git a/robot/resources/test_templates/vnf_orchestration_test_template.robot b/robot/resources/test_templates/vnf_orchestration_test_template.robot
index 53d56962..3a9c5570 100644
--- a/robot/resources/test_templates/vnf_orchestration_test_template.robot
+++ b/robot/resources/test_templates/vnf_orchestration_test_template.robot
@@ -80,7 +80,8 @@ Orchestrate VNF
\ VLB Closed Loop Hack ${service} ${generic_vnf} ${closedloop_vf_module}
\ Set Test Variable ${STACK_NAME} ${vf_module_name}
\ Append To List ${STACK_NAMES} ${STACK_NAME}
- \ Run Keyword and Ignore Error Execute Heatbridge ${vf_module_name} ${service_instance_id} ${vnf}
+ # TODO: Need to look at a better way to default ipv4_oam_interface search for Heatbridge
+ \ Run Keyword and Ignore Error Execute Heatbridge ${vf_module_name} ${service_instance_id} ${vnf} ipv4_oam_interface
\ Run Keyword and Ignore Error Validate VF Module ${vf_module_name} ${vnf}
[Return] ${vf_module_name} ${service}
diff --git a/robot/resources/vid/vid_interface.robot b/robot/resources/vid/vid_interface.robot
index ec017577..35522793 100644
--- a/robot/resources/vid/vid_interface.robot
+++ b/robot/resources/vid/vid_interface.robot
@@ -100,7 +100,7 @@ Parse Instance Id
${json}= To Json ${request_list[1]}
${request_id}= Catenate ${json['requestReferences']['instanceId']}
[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
@@ -108,7 +108,8 @@ Get Model UUID from VID
Go To ${VID_ENDPOINT}${VID_ENV}/rest/models/services
${resp}= Get Text xpath=//body/pre
${json}= To Json ${resp}
- :for ${dict} in @{json}
+ ${services}= Get From Dictionary ${json} services
+ :for ${dict} in @{services}
\ ${uuid}= Get From DIctionary ${dict} uuid
\ ${inv}= Get From DIctionary ${dict} invariantUUID
\ Return From Keyword If "${invariantUUID}" == "${inv}" ${uuid}