Revert Add optional parameter in Openstack lib.
[integration/test.git] / csit / libraries / OpenStackOperations.robot
index 5c6fd65ab83b6a62f782d405e5605b9cd3b34925..7e3fe9c9a488e40f206c62f308a9bf5de2ae048e 100644 (file)
@@ -1,6 +1,7 @@
 *** Settings ***
 Documentation     Openstack library. This library is useful for tests to create network, subnet, router and vm instances
 Library           Collections
+Library           Process
 Library           OperatingSystem
 Library           RequestsLibrary
 Library           SSHLibrary
@@ -550,9 +551,9 @@ Get OvsDebugInfo
 
 Get Test Teardown Debugs
     [Arguments]    ${test_name}=${SUITE_NAME}.${TEST_NAME}    ${fail}=${FAIL_ON_EXCEPTIONS}
+    ODLTools.Get All    test_name=${test_name}
     OpenStackOperations.Get OvsDebugInfo
     BuiltIn.Run Keyword And Ignore Error    DataModels.Get Model Dump    ${HA_PROXY_IP}    ${netvirt_data_models}
-    BuiltIn.run Keyword And Ignore Error    ODLTools.Get EOS    ${HA_PROXY_IP}
     KarafKeywords.Fail If Exceptions Found During Test    ${test_name}    fail=${fail}
 
 Get Suite Debugs
@@ -951,17 +952,18 @@ OpenStack CLI Get List
 OpenStack CLI
     [Arguments]    ${cmd}
     [Documentation]    Run the given OpenStack ${cmd} and log the output.
-    ${rc}    ${output} =    OperatingSystem.Run And Return Rc And Output    ${cmd}
-    BuiltIn.Log    ${output}
-    BuiltIn.Should Be True    '${rc}' == '0'
-    [Return]    ${output}
+    ${result} =    Process.Run Process    ${cmd}    shell=True
+    BuiltIn.Log    ${result.stdout}
+    BuiltIn.Log    ${result.stderr}
+    BuiltIn.Should Be True    '${result.rc}' == '0'
+    [Return]    ${result.stdout}
 
 OpenStack CLI With No Log
     [Arguments]    ${cmd}
     [Documentation]    Run the given OpenStack ${cmd} and do not log the output.
-    ${rc}    ${output} =    OperatingSystem.Run And Return Rc And Output    ${cmd}
-    BuiltIn.Should Be True    '${rc}' == '0'
-    [Return]    ${output}
+    ${result} =    Process.Run Process    ${cmd}    shell=True
+    BuiltIn.Should Be True    '${result.rc}' == '0'
+    [Return]    ${result.stdout}
 
 OpenStack Cleanup All
     [Documentation]    Cleanup all Openstack resources with best effort. The keyword will query for all resources
@@ -1008,7 +1010,6 @@ OpenStack Suite Setup
     BuiltIn.Run Keyword If    "${PRE_CLEAN_OPENSTACK_ALL}"=="True"    OpenStack Cleanup All
     OpenStackOperations.Add OVS Logging On All OpenStack Nodes
     Run_Keyword_If_At_Least_Oxygen    Wait Until Keyword Succeeds    60    2    ClusterManagement.Check Status Of Services Is OPERATIONAL    @{NETVIRT_DIAG_SERVICES}
-    ClusterManagement.Dump_Local_Shards_For_Each_Member
     Verify Expected Default Tables On Nodes
 
 OpenStack Suite Teardown