aboutsummaryrefslogtreecommitdiffstats
path: root/robot/resources/demo_preload.robot
diff options
context:
space:
mode:
Diffstat (limited to 'robot/resources/demo_preload.robot')
-rw-r--r--robot/resources/demo_preload.robot20
1 files changed, 13 insertions, 7 deletions
diff --git a/robot/resources/demo_preload.robot b/robot/resources/demo_preload.robot
index cb41c573..406f8f0e 100644
--- a/robot/resources/demo_preload.robot
+++ b/robot/resources/demo_preload.robot
@@ -19,6 +19,8 @@ ${ADD_DEMO_CUSTOMER_BODY} robot/assets/templates/aai/add_demo_customer.templat
${AAI_INDEX_PATH} /aai/v8
${VF_MODULES_NAME} _Demo_VFModules.json
${FILE_CACHE} /share/
+${DEMO_PREFIX} demo
+
*** Keywords ***
Load Customer And Models
@@ -39,8 +41,10 @@ Load Models
[Documentation] Use openECOMP to Orchestrate a service.
[Arguments] ${customer_name}
Set Test Variable ${CUSTOMER_NAME} ${customer_name}
- ${status} ${value}= Run Keyword And Ignore Error Distribute Model vFW demoVFW
- ${status} ${value}= Run Keyword And Ignore Error Distribute Model vLB demoVLB
+ ${status} ${value}= Run Keyword And Ignore Error Distribute Model vFWCL ${DEMO_PREFIX}VFWCL
+ ${status} ${value}= Run Keyword And Ignore Error Distribute Model vLB ${DEMO_PREFIX}VLB
+ ${status} ${value}= Run Keyword And Ignore Error Distribute Model vCPE ${DEMO_PREFIX}VCPE
+ ##${status} ${value}= Run Keyword And Ignore Error Distribute Model vIMS ${DEMO_PREFIX}VIMS
Distribute Model
[Arguments] ${service} ${modelName}
@@ -49,15 +53,17 @@ Distribute Model
Create Customer For VNF Demo
[Documentation] Create demo customer for the demo
[Arguments] ${customer_name} ${customer_id} ${customer_type} ${clouder_owner} ${cloud_region_id} ${tenant_id}
+ Create Service If Not Exists vFWCL
+ Create Service If Not Exists vLB
+ Create Service If Not Exists vCPE
+ Create Service If Not Exists vIMS
${data_template}= OperatingSystem.Get File ${ADD_DEMO_CUSTOMER_BODY}
${arguments}= Create Dictionary subscriber_name=${customer_name} global_customer_id=${customer_id} subscriber_type=${customer_type} cloud_owner=${clouder_owner} cloud_region_id=${cloud_region_id} tenant_id=${tenant_id}
- Set To Dictionary ${arguments} service1=vFW service2=vLB
+ Set To Dictionary ${arguments} service1=vFWCL service2=vLB service3=vCPE service4=vIMS
${data}= Fill JSON Template ${data_template} ${arguments}
${put_resp}= Run A&AI Put Request ${INDEX PATH}${ROOT_CUSTOMER_PATH}${customer_id} ${data}
${status_string}= Convert To String ${put_resp.status_code}
- Should Match Regexp ${status_string} ^(201|412)$
- Create Service If Not Exists vFW
- Create Service If Not Exists vLB
+ Should Match Regexp ${status_string} ^(200|201|412)$
Preload User Model
[Documentation] Preload the demo data for the passed VNF with the passed module name
@@ -102,7 +108,7 @@ Get Persona Model Id
[Documentation] Query and Validates A&AI Service Instance
[Arguments] ${service_instance_id} ${service_type} ${customer_id}
${resp}= Run A&AI Get Request ${INDEX PATH}${CUSTOMER SPEC PATH}${customer_id}${SERVICE SUBSCRIPTIONS}${service_type}${SERVICE INSTANCE}${service_instance_id}
- ${persona_model_id}= Get From DIctionary ${resp.json()['service-instance'][0]} persona-model-id
+ ${persona_model_id}= Get From DIctionary ${resp.json()['service-instance'][0]} model-invariant-id
[Return] ${persona_model_id}
APPC Mount Point