summaryrefslogtreecommitdiffstats
path: root/robot/resources/clamp_interface.robot
diff options
context:
space:
mode:
authorDR695H <dr695h@att.com>2019-06-19 21:16:58 -0400
committerDR695H <dr695h@att.com>2019-06-19 21:16:58 -0400
commit369e51562f068d5e653211902efc69220508eca1 (patch)
tree7ac9c6eaabcc18a7a687d03e0a807009aa561f3a /robot/resources/clamp_interface.robot
parent3d12502f70afb8b06fb44065e85630abfdfa7a3e (diff)
move so, clamp, oof to jinja
Issue-ID: TEST-158 Change-Id: I88798326879463103a66a97d4ddbc53e864be01a Signed-off-by: DR695H <dr695h@att.com>
Diffstat (limited to 'robot/resources/clamp_interface.robot')
-rw-r--r--robot/resources/clamp_interface.robot11
1 files changed, 6 insertions, 5 deletions
diff --git a/robot/resources/clamp_interface.robot b/robot/resources/clamp_interface.robot
index b8ec12bf..a83bc4d3 100644
--- a/robot/resources/clamp_interface.robot
+++ b/robot/resources/clamp_interface.robot
@@ -4,9 +4,8 @@ Library RequestsLibrary
Library Collections
Library String
Library ONAPLibrary.JSON
-
+Library ONAPLibrary.Templating
Resource global_properties.robot
-Resource json_templater.robot
*** Variables ***
${CLAMP_HEALTH_CHECK_PATH} /restservices/clds/v1/healthcheck
@@ -15,7 +14,7 @@ ${CLAMP_BASE_PATH} /restservices/clds/v1
${CLAMP_CLIENT_KEY} robot/assets/keys/org.onap.clamp.key.clear.pem
${CLAMP_CLIENT_CERT} robot/assets/keys/org.onap.clamp.cert.pem
-${CLAMP_TEMPLATE_PATH} robot/assets/templates/clamp
+${CLAMP_TEMPLATE_PATH} clamp
*** Keywords ***
@@ -23,7 +22,8 @@ Run CLAMP Create Model
[Documentation] Create a new CLAMP Model
[Arguments] ${model_name} ${template_name}
${dict}= Create Dictionary MODEL_NAME=${model_name} TEMPLATE_NAME=${template_name}
- ${data}= Fill JSON Template File ${CLAMP_TEMPLATE_PATH}/create_model.template ${dict}
+ Create Environment clamp ${GLOBAL_TEMPLATE_FOLDER}
+ ${data}= Apply Template clamp ${CLAMP_TEMPLATE_PATH}/create_model.jinja ${dict}
${data_path}= Set Variable ${CLAMP_BASE_PATH}/clds/model/${model_name}
${resp}= Run CLAMP HTTPS Put Request ${data_path} ${data}
Should Be Equal As Strings ${resp.status_code} 200
@@ -35,7 +35,8 @@ Run CLAMP Save vLB Model
[Documentation] Save CLAMP Model
[Arguments] ${model_name} ${template_name} ${policy_name}
${dict}= Create Dictionary MODEL_NAME=${model_name} TEMPLATE_NAME=${template_name} POLICY_NAME=${policy_name} DOLLAR_SIGN=$
- ${data}= Fill JSON Template File ${CLAMP_TEMPLATE_PATH}/save_model_vlb.template ${dict}
+ Create Environment clamp ${GLOBAL_TEMPLATE_FOLDER}
+ ${data}= Apply Template clamp ${CLAMP_TEMPLATE_PATH}/save_model_vlb.jinja ${dict}
${data_path}= Set Variable ${CLAMP_BASE_PATH}/clds/model/${model_name}
${resp}= Run CLAMP HTTPS Put Request ${data_path} ${data}
Should Be Equal As Strings ${resp.status_code} 200