Update GET examples 74/75874/1
authorBrian Freeman <bf1936@att.com>
Wed, 16 Jan 2019 14:38:46 +0000 (09:38 -0500)
committerBrian Freeman <bf1936@att.com>
Wed, 16 Jan 2019 14:39:15 +0000 (09:39 -0500)
Issue-ID: INT-808
Change-Id: I40225b77baaf52221a25c6a8cf7e496d8a03d15b
Signed-off-by: Brian Freeman <bf1936@att.com>
robot/resources/clamp_interface.robot
robot/testsuites/clamp.robot

index 29365c0..4cf15e8 100644 (file)
@@ -13,10 +13,16 @@ ${CLAMP_CLIENT_CERT}   robot/assets/keys/org.onap.clamp.cert.pem
 
 
 *** Keywords ***
+Run CLAMP Get Properties
+     [Documentation]   get CLAMP Control Loop properties
+     [Arguments]   ${property_id}
+     ${data_path}=   Set Variable   ${CLAMP_BASE_PATH}/clds/properties/${property_id}
+     ${resp}=   Run Clamp HTTPS Get Request    ${data_path}
+
 Run CLAMP Get Control Loop
      [Documentation]   runs CLAMP Open Control Loop based on model name
      [Arguments]   ${model_name}
-     ${data_path}=   Set Variable   ${CLAMP_BASE_PATH}/clds/model-names
+     ${data_path}=   Set Variable   ${CLAMP_BASE_PATH}/clds/model/${model_name}
      ${resp}=   Run Clamp HTTPS Get Request    ${data_path}
 
 Run CLAMP Get Model Names
@@ -36,7 +42,7 @@ Run CLAMP HTTPS Get Request
      ${session}=   Create Client Cert Session  session   ${CLAMP_ENDPOINT}     client_certs=@{client_certs}
      ${resp}=   Get Request     session         ${data_path}
      Should Be Equal As Integers        ${resp.status_code}     200
-     Log    Received response from CLAMP ${resp.text}
+     Log    ${resp.json()}
      [Return]    ${resp}
 
 Run CLAMP Get Request
@@ -47,4 +53,3 @@ Run CLAMP Get Request
      Should Be Equal As Integers        ${resp.status_code}     200
      Log    Received response from CLAMP ${resp.text}
      [Return]    ${resp}
-
index cd85dc6..b97e2b5 100644 (file)
@@ -2,11 +2,12 @@
 Documentation     Testing CLAMP
 ...
 ...               Testing ecomp components are available via calls.
-Test Timeout      10 second
+Test Timeout      120 second
 Resource          ../resources/clamp_interface.robot
 
 *** Test Cases ***
 Basic CLAMP Health Check
     [Tags]    clamp
     Run CLAMP Get Model Names
-
+    Run CLAMP Get Control Loop    CLAMPT2VLB_v2_0_vLB0605c122-90f10
+    Run CLAMP Get Properties    5fcdb3b7-5a5b-45da-83f6-14cce29181c8