summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJerry Flood <jf9860@att.com>2017-12-11 21:29:33 -0500
committerJerry Flood <jf9860@att.com>2017-12-11 21:29:57 -0500
commitd818f1484e591f3f3ec04a0bc4ae90eea886fb38 (patch)
tree7949a19bb457d02c6f01f29a6c0412a075550818
parent19345a71787aa318c05a4aa04c1abb014ad37704 (diff)
Complete the vFWCL closed loop test
Issue-ID: TEST-72 Change-Id: Ia14c13b6fd4faf4cb5a3efb1cc26fc78f269ee0d Signed-off-by: Jerry Flood <jf9860@att.com>
-rw-r--r--robot/resources/policy_interface.robot2
-rw-r--r--robot/resources/stack_validation/policy_check_vfw.robot29
-rw-r--r--robot/resources/test_templates/closedloop_test_template.robot1
3 files changed, 21 insertions, 11 deletions
diff --git a/robot/resources/policy_interface.robot b/robot/resources/policy_interface.robot
index e38d9445..1918b48d 100644
--- a/robot/resources/policy_interface.robot
+++ b/robot/resources/policy_interface.robot
@@ -109,7 +109,7 @@ Reboot Drools
${start}= Catenate docker exec -t -u policy drools bash -c "source /opt/app/policy/etc/profile.d/env.sh; policy start"
Wait Until Keyword Succeeds 120 5 sec Open Connection And Log In ${GLOBAL_INJECTED_POLICY_IP_ADDR} root ${GLOBAL_VM_PRIVATE_KEY}
Write ${stop}
- ${status} ${stdout}= Run Keyword And Ignore Error SSHLibrary.Read Until Regexp is running
+ ${status} ${stdout}= Run Keyword And Ignore Error SSHLibrary.Read Until Regexp has stopped
Log ${status}: stdout=${stdout}
${ctrlc}= Evaluate '\x03'
Run Keyword If '${status}' == 'FAIL' Write ${ctrlc}
diff --git a/robot/resources/stack_validation/policy_check_vfw.robot b/robot/resources/stack_validation/policy_check_vfw.robot
index 594b9146..a1daa878 100644
--- a/robot/resources/stack_validation/policy_check_vfw.robot
+++ b/robot/resources/stack_validation/policy_check_vfw.robot
@@ -18,27 +18,38 @@ Resource packet_generator_interface.robot
Resource darkstat_interface.robot
Resource validate_common.robot
Resource ../../resources/test_templates/vnf_orchestration_test_template.robot
+Resource ../../resources/policy_interface.robot
+Resource ../../resources/demo_preload.robot
*** Variables ***
*** Keywords ***
-Policy Check Firewall Stack
+Policy Check FirewallCL Stack
[Documentation] Executes the vFW policy closed loop test.
- [Arguments] ${stack_name} ${policy_rate}
+ [Arguments] ${stacknamemap} ${policy_rate}
Run Openstack Auth Request auth
- ${stack_info}= Wait for Stack to Be Deployed auth ${stack_name}
- ${stack_id}= Get From Dictionary ${stack_info} id
+ ${vsnk_stack_name}= Get From Dictionary ${stacknamemap} vFWSNK
+ ${vpkg_stack_name}= Get From Dictionary ${stacknamemap} vPKG
+ ${vsnk_stack_info}= Wait for Stack to Be Deployed auth ${vsnk_stack_name}
+ ${vpkg_stack_info}= Wait for Stack to Be Deployed auth ${vpkg_stack_name}
${server_list}= Get Openstack Servers auth
Log ${server_list}
- ${vpg_unprotected_ip}= Get From Dictionary ${stack_info} vpg_private_ip_0
- ${vsn_protected_ip}= Get From Dictionary ${stack_info} vsn_private_ip_0
- ${vpg_public_ip}= Get Server Ip ${server_list} ${stack_info} vpg_name_0 network_name=public
- ${vsn_public_ip}= Get Server Ip ${server_list} ${stack_info} vsn_name_0 network_name=public
+ # WIth amsterdam, the generic-vnf-name = the vFW host name
+ ${vfw_name}= Get From Dictionary ${vsnk_stack_info} vfw_name_0
+ ${status} ${generic_vnf}= Run Keyword And Ignore Error Get Service Instance ${vfw_name}
+ Run Keyword If '${status}' == 'FAIL' FAIL VNF Name: ${vfw_name} is not found.
+ ${invariantUUID} ${service} ${customer_id} ${service_instance_id}= Get Generic VNF Info ${generic_vnf}
+ Update vVFWCL Policy ${invariantUUID}
+
+ ${vpg_unprotected_ip}= Get From Dictionary ${vpkg_stack_info} vpg_private_ip_0
+ ${vsn_protected_ip}= Get From Dictionary ${vsnk_stack_info} vsn_private_ip_0
+ ${vpg_public_ip}= Get Server Ip ${server_list} ${vpkg_stack_info} vpg_name_0 network_name=public
+ ${vsn_public_ip}= Get Server Ip ${server_list} ${vsnk_stack_info} vsn_name_0 network_name=public
${upper_bound}= Evaluate ${policy_rate}*2
Wait Until Keyword Succeeds 300s 1s Run VFW Policy Check ${vpg_public_ip} ${policy_rate} ${upper_bound} 1
-Policy Check FirewallCL Stack
+Policy Check Firewall Stack
[Documentation] Executes the vFW policy closed loop test.
[Arguments] ${stack_name} ${policy_rate}
Run Openstack Auth Request auth
diff --git a/robot/resources/test_templates/closedloop_test_template.robot b/robot/resources/test_templates/closedloop_test_template.robot
index db49e317..6f54e98f 100644
--- a/robot/resources/test_templates/closedloop_test_template.robot
+++ b/robot/resources/test_templates/closedloop_test_template.robot
@@ -53,7 +53,6 @@ ${DNSSCALINGSTACK}
*** Keywords ***
VFWCL Policy
Log Suite name ${SUITE NAME} ${TEST NAME} ${PREV TEST NAME}
- Initialize VFWCL Policy
${stacknamemap}= Orchestrate VNF vFWCL closedloop
Policy Check FirewallCL Stack ${stacknamemap} ${VFWPOLICYRATE}
Delete VNF