added stein in exclusion
[integration/test.git] / csit / libraries / Tempest.robot
index 08fa3614238baa46961514a1525943ae07573735..57e446d28de8dfb61fa2ca9b35820077fb990508 100644 (file)
@@ -7,10 +7,9 @@ Resource          SSHKeywords.robot
 Resource          ../variables/Variables.robot
 
 *** Variables ***
-@{stable/newton_EXCLUSION_REGEXES}    ${EMPTY}
-@{stable/ocata_EXCLUSION_REGEXES}    ${EMPTY}
-@{stable/pike_EXCLUSION_REGEXES}    ${EMPTY}
 @{stable/queens_EXCLUSION_REGEXES}    ${EMPTY}
+@{stable/rocky_EXCLUSION_REGEXES}    ${EMPTY}
+@{stable/stein_EXCLUSION_REGEXES}    ${EMPTY}
 @{master_EXCLUSION_REGEXES}    ${EMPTY}
 ${BLACKLIST_FILE}    /tmp/blacklist.txt
 ${TEMPEST_DIR}    /opt/stack/tempest
@@ -36,7 +35,8 @@ Run Tempest Tests Without Debug
     ...    explicitly set to False.
     BuiltIn.Return From Keyword If    "skip_if_${OPENSTACK_BRANCH}" in @{TEST_TAGS}
     BuiltIn.Return From Keyword If    "skip_if_${SECURITY_GROUP_MODE}" in @{TEST_TAGS}
-    ${tempest_conn_id} =    SSHLibrary.Open Connection    ${OS_CONTROL_NODE_IP}    prompt=${DEFAULT_LINUX_PROMPT_STRICT}
+    BuiltIn.Return From Keyword If    "skip_if_${ODL_SNAT_MODE}" in @{TEST_TAGS}
+    ${tempest_conn_id} =    SSHLibrary.Open Connection    ${OS_CNTL_IP}    prompt=${DEFAULT_LINUX_PROMPT_STRICT}
     SSHKeywords.Flexible SSH Login    ${OS_USER}    ${DEVSTACK_SYSTEM_PASSWORD}
     DevstackUtils.Write Commands Until Prompt    source ${DEVSTACK_DEPLOY_PATH}/openrc admin admin
     DevstackUtils.Write Commands Until Prompt    cd ${TEMPEST_DIRectory}
@@ -46,7 +46,7 @@ Run Tempest Tests Without Debug
     # There are tons of deprecation error messages when we use ostestr in our CSIT environment (openstack via devstack)
     # The robot log files are very large and one culprit is all these deprecation warnings. If we redirect stderr to
     # /dev/null we should be able to ignore them. We will miss any other errors, however.
-    ${output} =    DevstackUtils.Write Commands Until Prompt And Log    ostestr --regex ${tempest_regex} 2>/dev/null    timeout=${timeout}
+    ${output} =    DevstackUtils.Write Commands Until Prompt And Log    ostestr --regex ${tempest_regex}    timeout=${timeout}
     SSHLibrary.Close Connection
     BuiltIn.Should Contain    ${output}    Failed: 0
 
@@ -58,7 +58,8 @@ Run Tempest Tests With Debug
     ...    test cases with a single command. Essentially, this keyword only handles one breakpoint at a single teardown.
     BuiltIn.Return From Keyword If    "skip_if_${OPENSTACK_BRANCH}" in @{TEST_TAGS}
     BuiltIn.Return From Keyword If    "skip_if_${SECURITY_GROUP_MODE}" in @{TEST_TAGS}
-    ${tempest_conn_id} =    SSHLibrary.Open Connection    ${OS_CONTROL_NODE_IP}    prompt=${DEFAULT_LINUX_PROMPT_STRICT}
+    BuiltIn.Return From Keyword If    "skip_if_${ODL_SNAT_MODE}" in @{TEST_TAGS}
+    ${tempest_conn_id} =    SSHLibrary.Open Connection    ${OS_CNTL_IP}    prompt=${DEFAULT_LINUX_PROMPT_STRICT}
     SSHKeywords.Flexible SSH Login    ${OS_USER}    ${DEVSTACK_SYSTEM_PASSWORD}
     DevstackUtils.Write Commands Until Prompt    source ${DEVSTACK_DEPLOY_PATH}/openrc admin admin
     DevstackUtils.Write Commands Until Prompt    cd ${TEMPEST_DIRectory}
@@ -90,8 +91,12 @@ Log In To Tempest Executor And Setup Test Environment
     OpenStackOperations.Create Network    ${EXTERNAL_NET_NAME}    --external --default --provider-network-type flat --provider-physical-network ${PUBLIC_PHYSICAL_NETWORK}
     OpenStackOperations.Create Subnet    ${EXTERNAL_NET_NAME}    ${EXTERNAL_SUBNET_NAME}    ${EXTERNAL_SUBNET}    --gateway ${EXTERNAL_GATEWAY} --allocation-pool ${EXTERNAL_SUBNET_ALLOCATION_POOL}
     OpenStackOperations.List Networks
-    ${control_node_conn_id} =    SSHLibrary.Open Connection    ${OS_CONTROL_NODE_IP}    prompt=${DEFAULT_LINUX_PROMPT_STRICT}
+    ${control_node_conn_id} =    SSHLibrary.Open Connection    ${OS_CNTL_IP}    prompt=${DEFAULT_LINUX_PROMPT_STRICT}
     SSHKeywords.Flexible SSH Login    ${OS_USER}
+    DevstackUtils.Write Commands Until Prompt And Log    sudo pip install -U --verbose pip    timeout=120s
+    DevstackUtils.Write Commands Until Prompt And Log    sudo pip install -U --verbose os-testr>=1.0.0    timeout=120s
+    DevstackUtils.Write Commands Until Prompt And Log    ostestr --version
+    DevstackUtils.Write Commands Until Prompt And Log    testr init
     DevstackUtils.Write Commands Until Prompt    source ${DEVSTACK_DEPLOY_PATH}/openrc admin admin
     DevstackUtils.Write Commands Until Prompt    sudo rm -rf /opt/stack/tempest/.testrepository
     ${net_id} =    OpenStackOperations.Get Net Id    ${EXTERNAL_NET_NAME}
@@ -126,7 +131,8 @@ Create Blacklist File
     ...    line will be created in the required ${BLACKLIST_FILE} location. This file is pushed to the OS_CONTROL_NODE
     ...    which is assumed to be the tempest executor.
     OperatingSystem.Create File    ${BLACKLIST_FILE}
-    : FOR    ${exclusion}    IN    @{${OPENSTACK_BRANCH}_EXCLUSION_REGEXES}
-    \    OperatingSystem.Append To File    ${BLACKLIST_FILE}    ${exclusion}\n
+    FOR    ${exclusion}    IN    @{${OPENSTACK_BRANCH}_EXCLUSION_REGEXES}
+        OperatingSystem.Append To File    ${BLACKLIST_FILE}    ${exclusion}\n
+    END
     OperatingSystem.Log File    ${BLACKLIST_FILE}
-    SSHKeywords.Copy File To Remote System    ${OS_CONTROL_NODE_IP}    ${BLACKLIST_FILE}    ${BLACKLIST_FILE}
+    SSHKeywords.Copy File To Remote System    ${OS_CNTL_IP}    ${BLACKLIST_FILE}    ${BLACKLIST_FILE}