Add missing models.robot 36/94136/1
authorBrian Freeman <bf1936@att.com>
Thu, 22 Aug 2019 16:03:11 +0000 (11:03 -0500)
committerBrian Freeman <bf1936@att.com>
Thu, 22 Aug 2019 16:03:20 +0000 (11:03 -0500)
Issue-ID: INT-1139
Change-Id: Ib2f2b6370875599304f1516806c27997155cec70
Signed-off-by: Brian Freeman <bf1936@att.com>
robot/resources/aai/models.robot [new file with mode: 0644]

diff --git a/robot/resources/aai/models.robot b/robot/resources/aai/models.robot
new file mode 100644 (file)
index 0000000..d8de2a4
--- /dev/null
@@ -0,0 +1,18 @@
+*** Settings ***
+Documentation    Validate A&AI Models
+
+Resource          aai_interface.robot
+Library    Collections
+Library    ONAPLibrary.AAI    WITH NAME    AAI
+
+*** Variables ***
+${INDEX_PATH}     /aai/v16
+${MODELS_SPEC_PATH}    /service-design-and-creation/models/
+
+*** Keywords ***
+Validate Size Of AAI Models
+    [Documentation]    Query and Validates A&AI Models 
+    [Arguments]     ${min_size}=100
+    ${resp}=    AAI.Run Get Request      ${AAI_FRONTEND_ENDPOINT}    ${INDEX_PATH}${MODELS_SPEC_PATH}   auth=${GLOBAL_AAI_AUTHENTICATION}
+    ${count}=   Evaluate    sys.getsizeof(${resp.json()})    sys
+    Should Be True    ${count} > ${min_size}