Revised timeout for NIC CLI command with WUKS. 36/29836/6
authorAlton Fong <alton.fong@hp.com>
Wed, 18 Nov 2015 02:54:34 +0000 (18:54 -0800)
committerGerrit Code Review <gerrit@opendaylight.org>
Tue, 24 Nov 2015 01:41:56 +0000 (01:41 +0000)
Change-Id: Ia74847e440151c96de77e9a1e5266c890aa4f44d
Signed-off-by: Alton Fong <alton.fong@hp.com>
csit/suites/nic/cli/console.robot

index 34639838cc64445030a298a907debf71e25212af..ec726f5ecc213edae54a1b767666b71b871e2368 100644 (file)
@@ -38,6 +38,7 @@ Verify NIC Command Add and Remove
     ...    and stores the intent ids, then verifies that the intents were added. Finally, it compiles the intents
     ...    to verify that intents were properly merged and also validates intents were removed at the end per the cleanup procedure.
     [Tags]    NIC
+    Wait Until Keyword Succeeds    10 min    5 sec    Verify Intent:Add Command is Availible
     : FOR    ${intent}    IN    @{all_intents}
     \    ${id}=    Add Intent    @{intent}
     \    Append To List    ${all_intents_ids}    ${id}
@@ -71,13 +72,20 @@ Setup NIC Console Environment
 Add Intent
     [Arguments]    ${intent_from}    ${intent_to}    ${intent_permission}
     [Documentation]    Adds an intent to the controller, and returns the id of the intent created.
-    ${output}=    Issue Command On Karaf Console    intent:add -f ${intent_from} -t ${intent_to} -a ${intent_permission}    timeout=60
+    ${output}=    Issue Command On Karaf Console    intent:add -f ${intent_from} -t ${intent_to} -a ${intent_permission}
     Should Contain    ${output}    Intent created
     ${output}=    Fetch From Left    ${output}    )
     ${output_split}=    Split String    ${output}    ${SPACE}
     ${id}=    Get From List    ${output_split}    3
     [Return]    ${id}
 
+Verify Intent:Add Command is Availible
+    [Documentation]    Verifies that odl-nic-console is up and intent:add command is available to be used. 
+    ...    Should be used with the command "Wait Until Keyword Succeeds" to poll until command is availible. 
+    ${output}=    Issue Command On Karaf Console    intent:add
+    Should Not Contain    ${output}    Command not found
+
+
 Verify Intent Added
     [Arguments]    ${id}    ${intent}
     [Documentation]    This will check if the id exists via intent:list -c, then compares intent details with arguments passed in with Add Intent