diff options
author | Daniel Rose <dr695h@att.com> | 2018-11-02 18:30:15 +0000 |
---|---|---|
committer | Gerrit Code Review <gerrit@onap.org> | 2018-11-02 18:30:15 +0000 |
commit | 9631964572c232dcfee9f027db8058f7c0b96e25 (patch) | |
tree | 243930f5431022fb4774db5eaf3eeb77554fe52d /robot/resources | |
parent | 423194d1bf638829af0c4bd0065f3d2247dbf463 (diff) | |
parent | 5323bc2f68a6cd5d4114bbbd3e5f9f5da1e83f4e (diff) |
Merge "Fix parsing in closed loop policy checks"
Diffstat (limited to 'robot/resources')
-rw-r--r-- | robot/resources/test_templates/closedloop_test_template.robot | 31 |
1 files changed, 12 insertions, 19 deletions
diff --git a/robot/resources/test_templates/closedloop_test_template.robot b/robot/resources/test_templates/closedloop_test_template.robot index f83ce5b1..fe33e749 100644 --- a/robot/resources/test_templates/closedloop_test_template.robot +++ b/robot/resources/test_templates/closedloop_test_template.robot @@ -55,7 +55,7 @@ VFW Policy Log Suite name ${SUITE NAME} ${TEST NAME} ${PREV TEST NAME} Initialize VFW Policy ${stackname}= Orchestrate VNF vFW closedloop - Policy Check Firewall Stack ${stackname} ${VFWPOLICYRATE} + Policy Check FirewallCL Stack ${stackname} ${VFWPOLICYRATE} Delete VNF VDNS Policy @@ -85,22 +85,17 @@ Get Configs VFW Policy ${json}= Parse Json ${get_resp.content} ${config}= Parse Json ${json[0]["config"]} + ${thresholds}= Get Variable Value ${config["content"]["tca_policy"]["metricsPerEventName"][0]["thresholds"]} # Extract object1 from Array - ${severity}= Get Variable Value ${config["content"]["thresholds"][0]["severity"]} - Should Be Equal ${severity} ${Expected_Severity_1} - ${Thresold_Value}= Get Variable Value ${config["content"]["thresholds"][0]["thresholdValue"]} - Should Be Equal As Integers ${Thresold_Value} ${Expected_Threshold_1} - ${direction}= Get Variable Value ${config["content"]["thresholds"][0]["direction"]} - Should Be Equal ${direction} ${Expected_Direction_1} + Should Be Equal ${thresholds[0]["severity"]} ${Expected_Severity_1} + Should Be Equal As Integers ${thresholds[0]["thresholdValue"]} ${Expected_Threshold_1} + Should Be Equal ${thresholds[0]["direction"]} ${Expected_Direction_1} # Extract object2 from Array - ${severity_1}= Get Variable Value ${config["content"]["thresholds"][1]["severity"]} - Should Be Equal ${severity_1} ${Expected_Severity_2} - ${Thresold_Value_1}= Get Variable Value ${config["content"]["thresholds"][1]["thresholdValue"]} - Should Be Equal As Integers ${Thresold_Value_1} ${Expected_Threshold_2} - ${direction_1}= Get Variable Value ${config["content"]["thresholds"][1]["direction"]} - Should Be Equal ${direction_1} ${Expected_Direction_2} + Should Be Equal ${thresholds[1]["severity"]} ${Expected_Severity_2} + Should Be Equal As Integers ${thresholds[1]["thresholdValue"]} ${Expected_Threshold_2} + Should Be Equal ${thresholds[1]["direction"]} ${Expected_Direction_2} Get Configs VDNS Policy [Documentation] Get Config Policy for VDNS @@ -111,14 +106,12 @@ Get Configs VDNS Policy Should Be Equal As Strings ${get_resp.status_code} 200 ${json}= Parse Json ${get_resp.content} ${config}= Parse Json ${json[0]["config"]} + ${thresholds}= Get Variable Value ${config["content"]["tca_policy"]["metricsPerEventName"][0]["thresholds"]} # Extract object1 from Array - ${severity}= Get Variable Value ${config["content"]["tca_policy"]["metricsPerEventName"][0]["thresholds"][0]["severity"]} - Should Be Equal ${severity} ${Expected_Severity_2} - ${Thresold_Value}= Get Variable Value ${config["content"]["tca_policy"]["metricsPerEventName"][0]["thresholds"][0]["thresholdValue"]} - Should Be Equal As Integers ${Thresold_Value} ${Expected_Threshold_1} - ${direction}= Get Variable Value ${config["content"]["tca_policy"]["metricsPerEventName"][0]["thresholds"][0]["direction"]} - Should Be Equal ${direction} ${Expected_Direction_3} + Should Be Equal ${thresholds[0]["severity"]} ${Expected_Severity_2} + Should Be Equal As Integers ${thresholds[0]["thresholdValue"]} ${Expected_Threshold_1} + Should Be Equal ${thresholds[0]["direction"]} ${Expected_Direction_3} Teardown Closed Loop [Documentation] Tear down a closed loop test case |