TEST-5 - stack deployment timeout 67/2267/2
authorJerry Flood <jf9860@att.com>
Mon, 20 Mar 2017 20:59:23 +0000 (16:59 -0400)
committerJerry Flood <jf9860@att.com>
Mon, 20 Mar 2017 21:36:31 +0000 (17:36 -0400)
Change-Id: I62e2dc40016d5cded99e39eec1b4e6d380bfbffa
Signed-off-by: Jerry Flood <jf9860@att.com>
robot/resources/global_properties.robot
robot/resources/openstack/heat_interface.robot
robot/resources/vid/create_service_instance.robot
robot/resources/vid/create_vid_vnf.robot
robot/resources/vid/teardown_vid.robot
robot/resources/vid/vid_interface.robot

index 819f56a..442a69c 100644 (file)
@@ -18,5 +18,9 @@ ${GLOBAL_OPENSTACK_NOVA_SERVICE_TYPE}    compute
 ${GLOBAL_OPENSTACK_NEUTRON_SERVICE_TYPE}    network
 ${GLOBAL_OPENSTACK_GLANCE_SERVICE_TYPE}    image
 ${GLOBAL_OPENSTACK_KEYSTONE_SERVICE_TYPE}    identity
+${GLOBAL_OPENSTACK_STACK_DEPLOYMENT_TIMEOUT}    600s
 ${GLOBAL_AAI_CLOUD_OWNER}    Rackspace
-${GLOBAL_BUILD_NUMBER}    0
\ No newline at end of file
+${GLOBAL_BUILD_NUMBER}    0
+${GLOBAL_VID_UI_TIMEOUT_SHORT}    20s
+${GLOBAL_VID_UI_TIMEOUT_MEDIUM}    60s
+${GLOBAL_VID_UI_TIMEOUT_LONG}    120s
index 32f3fde..b23cb75 100644 (file)
@@ -78,7 +78,7 @@ Get Stack Resources
     [Return]    ${resp.json()}
 
 Wait for Stack to Be Deployed
-    [Arguments]    ${alias}   ${stack_name}    ${timeout}=600s
+    [Arguments]    ${alias}   ${stack_name}    ${timeout}=${GLOBAL_OPENSTACK_STACK_DEPLOYMENT_TIMEOUT}
     ${stack_info}=    Wait Until Keyword Succeeds    ${timeout}    30 sec    Get Deployed Stack    ${alias}    ${stack_name}
     ${status}=   Get From Dictionary    ${stack_info}    stack_status
     Should Be Equal    ${status}    CREATE_COMPLETE
index 204b7d6..7cdafe0 100644 (file)
@@ -19,14 +19,14 @@ Create VID Service Instance
     Wait Until Keyword Succeeds    300s    1s    Wait For Model    ${service_model_type}
     Press Key    xpath=//tr[td/span/text() = '${service_model_type}']/td/button[text() = 'Deploy' and not(@disabled)]    \\13
     ${uuid}=    Generate UUID
-    Wait Until Page Contains Element    xpath=//input[@parameter-name='Instance Name']    120s
-    Wait Until Element Is Visible    xpath=//input[@parameter-name='Instance Name']    120s
+    Wait Until Page Contains Element    xpath=//input[@parameter-name='Instance Name']    ${GLOBAL_VID_UI_TIMEOUT_LONG}
+    Wait Until Element Is Visible    xpath=//input[@parameter-name='Instance Name']    ${GLOBAL_VID_UI_TIMEOUT_LONG}
     Xpath Should Match X Times    //input[@parameter-name='Instance Name']    1
     Input Text When Enabled    //input[@parameter-name='Instance Name']    ${service_name}
     Select From List When Enabled    //select[@prompt='Select Subscriber Name']    ${customer_name}
     Select From List WHen Enabled    //select[@prompt='Select Service Type']     ${service_type}
     Click On Button When Enabled    //div[@class = 'buttonRow']/button[text() = 'Confirm']
-       Wait Until Element Contains    xpath=//div[@ng-controller= 'msoCommitController']/pre[@class = 'log ng-binding']    requestId    timeout=120s
+       Wait Until Element Contains    xpath=//div[@ng-controller= 'msoCommitController']/pre[@class = 'log ng-binding']    requestId    timeout=${GLOBAL_VID_UI_TIMEOUT_LONG}
     ${response text}=    Get Text    xpath=//div[@ng-controller= 'msoCommitController']/pre[@class = 'log ng-binding']
     Click On Button When Enabled    //div[@class = 'buttonRow']/button[text() = 'Close']
     ${request_id}=    Parse Request Id    ${response text}
@@ -39,15 +39,15 @@ Wait For Model
     [Arguments]   ${service_model_type}
     Click Element    partial link=Browse SDC Service
     Page Should Contain Element    xpath=//div/h1[text() = 'Browse SDC Service Models']
-    Wait Until Page Contains Element    xpath=//button[text() = 'Deploy']    240s
+    Wait Until Page Contains Element    xpath=//button[text() = 'Deploy']    ${GLOBAL_VID_UI_TIMEOUT_LONG}
     Input Text When Enabled    //input[@ng-model='searchString']    ${service_model_type}
-    Wait Until Element Is Visible    xpath=//tr[td/span/text() = '${service_model_type}']/td/button[contains(text(),'Deploy')]    10s
+    Wait Until Element Is Visible    xpath=//tr[td/span/text() = '${service_model_type}']/td/button[contains(text(),'Deploy')]    ${GLOBAL_VID_UI_TIMEOUT_SHORT}
 
 Delete Service Instance By GUI
     [Arguments]    ${service_instance_id}    ${customer_name}
     Click On Element When Visible    xpath=//a/span[@class='glyphicon glyphicon-remove']
-    Click On Button When Visible    xpath=//div[@class='buttonRow']/button[@ngx-enabled='true']
-    Wait Until Element Contains    xpath=//div[@ng-controller='deletionDialogController']//div[@ng-controller= 'msoCommitController']/pre[@class = 'log ng-binding']   requestId    timeout=120s
+    Click On Button When Enabled    xpath=//div[@class='buttonRow']/button[@ngx-enabled='true']
+    Wait Until Element Contains    xpath=//div[@ng-controller='deletionDialogController']//div[@ng-controller= 'msoCommitController']/pre[@class = 'log ng-binding']   requestId    timeout=${GLOBAL_VID_UI_TIMEOUT_LONG}
     ${response text}=    Get Text    xpath=//div[@ng-controller='deletionDialogController']//div[@ng-controller= 'msoCommitController']/pre[@class = 'log ng-binding']
     ${request_id}=    Parse Request Id     ${response text}
     Poll MSO Get Request    ${GLOBAL_MSO_STATUS_PATH}${request_id}   COMPLETE
index 7417772..371ad70 100644 (file)
@@ -17,24 +17,20 @@ Create VID VNF
     [Arguments]    ${service_instance_id}    ${service_instance_name}    ${product_family}    ${lcp_region}    ${tenant}   ${vnf_type}
     Go To VID HOME
     Click Link       xpath=//div[@heading = 'Search for Existing Service Instances']/a
-    Wait Until Page Contains    Please search by    timeout=60s
-    #Wait Until Page Contains Element    xpath=//div[@class='statusLine aaiHidden']    timeout=60s
-    #Wait Until Element Is Not Visible    xpath=//div[@class='statusLine aaiHidden']    timeout=60s
+    Wait Until Page Contains    Please search by    timeout=${GLOBAL_VID_UI_TIMEOUT_MEDIUM}
 
     # If we don't wait for this control to be enabled, the submit results in a 'not found' pop-up (UnexpectedAlertPresentException)
     Input Text When Enabled    //input[@name='selectedServiceInstance']    ${service_instance_id}
     Click Button    button=Submit
-    Wait Until Page Contains Element    link=View/Edit    timeout=60s
+    Wait Until Page Contains Element    link=View/Edit    timeout=${GLOBAL_VID_UI_TIMEOUT_MEDIUM}
     Click Element     xpath=//a[contains(text(), 'View/Edit')]
-    Wait Until Page Contains    View/Edit Service Instance     timeout=60s
-    #Wait Until Page Contains Element    xpath=//div[@class='statusLine aaiVisible']    timeout=120s
-    #Wait Until Element Is Not Visible    xpath=//div[@class='statusLine aaiVisible']    timeout=60s
+    Wait Until Page Contains    View/Edit Service Instance     timeout=${GLOBAL_VID_UI_TIMEOUT_MEDIUM}
     Click Element    button=Add VNF
 
     # This is where firefox breaks. Th elink never becomes visible when run with the script.
     Click Element    link=${vnf_type}
-    Wait Until Page Contains Element    xpath=//input[@parameter-id='instanceName']    20s
-    Wait Until Element Is Enabled    xpath=//input[@parameter-id='instanceName']    20s
+    Wait Until Page Contains Element    xpath=//input[@parameter-id='instanceName']    ${GLOBAL_VID_UI_TIMEOUT_SHORT}
+    Wait Until Element Is Enabled    xpath=//input[@parameter-id='instanceName']    ${GLOBAL_VID_UI_TIMEOUT_SHORT}
 
     ## Without this sleep, the input text below gets immediately wiped out.
     ## Wait Until Angular Ready just sleeps for its timeout value
@@ -44,12 +40,12 @@ Create VID VNF
     Select From List By Label    xpath=//select[@parameter-id='lcpRegion']    ${lcp_region}
     Select From List By Label    xpath=//select[@parameter-id='tenant']    ${tenant}
     Click Element    button=Confirm
-       Wait Until Element Contains    xpath=//div[@ng-controller= 'msoCommitController']/pre[@class = 'log ng-binding']    Status: OK (200)    timeout=120
+       Wait Until Element Contains    xpath=//div[@ng-controller= 'msoCommitController']/pre[@class = 'log ng-binding']    Status: OK (200)    timeout=${GLOBAL_VID_UI_TIMEOUT_LONG}
     ${response text}=    Get Text    xpath=//div[@ng-controller= 'msoCommitController']/pre[@class = 'log ng-binding']
        Should Not Contain    ${response text}    FAILED
     Click Element    button=Close
     ${instance_id}=    Parse Instance Id     ${response text}
-    Wait Until Page Contains    ${service_instance_name}    60s
+    Wait Until Page Contains    ${service_instance_name}    ${GLOBAL_VID_UI_TIMEOUT_MEDIUM}
     [Return]     ${instance_id}
 
 Delete VID VNF
@@ -57,21 +53,21 @@ Delete VID VNF
     Go To VID HOME
     Click Link       xpath=//div[@heading = 'Search for Existing Service Instances']/a
     Wait Until Page Contains    Please search by    timeout=60s
-    Wait Until Page Contains Element    xpath=//div[@class='statusLine aaiHidden']    timeout=60s
-    Wait Until Element Is Not Visible    xpath=//div[@class='statusLine aaiHidden']    timeout=60s
+    Wait Until Page Contains Element    xpath=//div[@class='statusLine aaiHidden']    timeout=${GLOBAL_VID_UI_TIMEOUT_MEDIUM}
+    Wait Until Element Is Not Visible    xpath=//div[@class='statusLine aaiHidden']    timeout=${GLOBAL_VID_UI_TIMEOUT_MEDIUM}
 
     # If we don't wait for this control to be enabled, the submit results in a 'not found' pop-up (UnexpectedAlertPresentException)
     Input Text When Enabled    //input[@name='selectedServiceInstance']    ${service_instance_id}
     Click Button    button=Submit
-    Wait Until Page Contains Element    link=View/Edit    timeout=60s
+    Wait Until Page Contains Element    link=View/Edit    timeout=${GLOBAL_VID_UI_TIMEOUT_MEDIUM}
     Click Element     link=View/Edit
-    Wait Until Page Contains    View/Edit Service Instance     timeout=60s
-    Wait Until Page Contains Element    xpath=//div[@class='statusLine']    timeout=120s
-    Wait Until Element Is Not Visible    xpath=//div[@class='statusLine aaiHidden']    timeout=60s
+    Wait Until Page Contains    View/Edit Service Instance     timeout=${GLOBAL_VID_UI_TIMEOUT_MEDIUM}
+    Wait Until Page Contains Element    xpath=//div[@class='statusLine']    timeout=${GLOBAL_VID_UI_TIMEOUT_LONG}
+    Wait Until Element Is Not Visible    xpath=//div[@class='statusLine aaiHidden']    timeout=${GLOBAL_VID_UI_TIMEOUT_MEDIUM}
 
 
 
-    Click On Element When Visible    xpath=//li/div[contains(.,'${vnf_instance_id}')]/a/span[@class='glyphicon glyphicon-remove']    timeout=120s
+    Click On Element When Visible    xpath=//li/div[contains(.,'${vnf_instance_id}')]/a/span[@class='glyphicon glyphicon-remove']    timeout=${GLOBAL_VID_UI_TIMEOUT_LONG}
     Select From List By Label    xpath=//select[@parameter-id='lcpRegion']    ${lcp_region}
     Select From List By Label    xpath=//select[@parameter-id='tenant']    ${tenant}
     Click Element    xpath=//div[@class='buttonRow']/button[@ngx-enabled='true']
@@ -85,24 +81,25 @@ Create VID VNF module
     [Arguments]    ${service_instance_id}    ${vf_module_name}    ${lcp_region}    ${TENANT}    ${VNF_TYPE}
     Go To VID HOME
     Click Link       xpath=//div[@heading = 'Search for Existing Service Instances']/a
-    Wait Until Page Contains    Please search by    timeout=60s
-    Wait Until Page Contains Element    xpath=//div[@class='statusLine aaiHidden']    timeout=60s
+    Wait Until Page Contains    Please search by    timeout=${GLOBAL_VID_UI_TIMEOUT_MEDIUM}
+    Wait Until Page Contains Element    xpath=//div[@class='statusLine aaiHidden']    timeout=${GLOBAL_VID_UI_TIMEOUT_MEDIUM}
 
      # If we don't wait for this control to be enabled, the submit results in a 'not found' pop-up (UnexpectedAlertPresentException)
     Input Text When Enabled    //input[@name='selectedServiceInstance']    ${service_instance_id}
     Click Button    button=Submit
-    Wait Until Page Contains Element    link=View/Edit    timeout=60s
+    Wait Until Page Contains Element    link=View/Edit    timeout=${GLOBAL_VID_UI_TIMEOUT_MEDIUM}
     Click Element     link=View/Edit
-    Wait Until Page Contains    View/Edit Service Instance     timeout=60s
-    Wait Until Page Contains Element    xpath=//div[@class='statusLine']    timeout=120s
-    Wait Until Element Is Not Visible    xpath=//div[@class='statusLine aaiHidden']    timeout=120s
-    Wait Until Element Is Visible    button=Add VF-Module   timeout=120s
+    Wait Until Keyword Succeeds   300s   5s   Wait For Add VF Module
+    #Wait Until Page Contains    View/Edit Service Instance     timeout=60s
+    #Wait Until Page Contains Element    xpath=//div[@class='statusLine']    timeout=120s
+    #Wait Until Element Is Not Visible    xpath=//div[@class='statusLine aaiHidden']    timeout=120s
+    #Wait Until Element Is Visible    button=Add VF-Module   timeout=120s
     Click Element    button=Add VF-Module
 
     # This is where firefox breaks. Th elink never becomes visible when run with the script.
     Click Element    link=${vnf_type}
-    Wait Until Page Contains Element    xpath=//input[@parameter-id='instanceName']    20s
-    Wait Until Element Is Enabled    xpath=//input[@parameter-id='instanceName']    20s
+    Wait Until Page Contains Element    xpath=//input[@parameter-id='instanceName']    ${GLOBAL_VID_UI_TIMEOUT_SHORT}
+    Wait Until Element Is Enabled    xpath=//input[@parameter-id='instanceName']    ${GLOBAL_VID_UI_TIMEOUT_SHORT}
 
     ## Without this sleep, the input text below gets immediately wiped out.
     ## Wait Until Angular Ready just sleeps for its timeout value
@@ -111,7 +108,7 @@ Create VID VNF module
     Select From List By Label    xpath=//select[@parameter-id='lcpRegion']    ${lcp_region}
     Select From List By Label    xpath=//select[@parameter-id='tenant']    ${tenant}
     Click Element    button=Confirm
-       Wait Until Element Contains    xpath=//div[@ng-controller= 'msoCommitController']/pre[@class = 'log ng-binding']    requestId    timeout=120
+       Wait Until Element Contains    xpath=//div[@ng-controller= 'msoCommitController']/pre[@class = 'log ng-binding']    requestId    timeout=${GLOBAL_VID_UI_TIMEOUT_LONG}
     ${response text}=    Get Text    xpath=//div[@ng-controller= 'msoCommitController']/pre[@class = 'log ng-binding']
     Click Element    button=Close
     ${instance_id}=    Parse Instance Id     ${response text}
@@ -119,4 +116,14 @@ Create VID VNF module
     ${request_id}=    Parse Request Id     ${response text}
     Poll MSO Get Request    ${GLOBAL_MSO_STATUS_PATH}${request_id}   COMPLETE
 
-    [Return]     ${instance_id}
\ No newline at end of file
+    [Return]     ${instance_id}
+
+Wait For Add VF Module
+    [Documentation]   Retry by refresh if the ADD VF-Module is not visible
+    Wait Until Page Contains    View/Edit Service Instance     timeout=${GLOBAL_VID_UI_TIMEOUT_MEDIUM}
+    Wait Until Page Contains Element    xpath=//div[@class='statusLine']    timeout=${GLOBAL_VID_UI_TIMEOUT_MEDIUM}
+    Wait Until Element Is Not Visible    xpath=//div[@class='statusLine aaiHidden']    timeout=${GLOBAL_VID_UI_TIMEOUT_MEDIUM}
+    ${status}   ${value}   Run Keyword And Ignore Error   Wait Until Element Is Visible    button=Add VF-Module   timeout=${GLOBAL_VID_UI_TIMEOUT_SHORT}
+    Return From Keyword If   '${status}' == 'PASS'
+    Reload Page
+    Fail    Retry
index 8840854..b57cd1d 100644 (file)
@@ -4,7 +4,7 @@ Library             ExtendedSelenium2Library
 Library            Collections
 Library         String
 Library              StringTemplater
-Library                  UUID      
+Library                  UUID
 Resource        vid_interface.robot
 Resource        create_vid_vnf.robot
 Resource        create_service_instance.robot
@@ -14,21 +14,21 @@ ${VID_ENV}            /vid
 ${VID_SERVICE_MODELS_SEARCH_CUST}  ${GLOBAL_VID_SERVER}${VID_ENV}/serviceModels.htm#/instances/subdetails?selectedSubscriber=\${customer_id}
 ${VID_SERVICE_MODELS_SEARCH_URL}  ${GLOBAL_VID_SERVER}${VID_ENV}/serviceModels.htm#/instances/services
 *** Keywords ***
-    
-Teardown VID 
+
+Teardown VID
     [Documentation]   Teardown the VID This assumes that the any runnign stacks have been torn down
-    [Arguments]    ${service_instance_id}    ${lcp_region}    ${tenant}  
-    Return From Keyword If   len('${service_instance_id}') == 0       
+    [Arguments]    ${service_instance_id}    ${lcp_region}    ${tenant}
+    Return From Keyword If   len('${service_instance_id}') == 0
     # Keep going to the VID service instance until we get the pop-up alert that there is no service instance
     Wait Until Keyword Succeeds    300s    1s    Delete VID    ${service_instance_id}    ${lcp_region}    ${tenant}
-    
 
-Delete VID   
+
+Delete VID
     [Documentation]    Teardown the next VID entity that has a Remove icon.
     [Arguments]    ${service_instance_id}    ${lcp_region}    ${tenant}
-    # For vLB closed loop, we may have 2 vf modules and the vDNS one needs to be removed first.     
+    # For vLB closed loop, we may have 2 vf modules and the vDNS one needs to be removed first.
     ${remove_order}=    Create List    vDNS_Ete   Vfmodule_Ete
-    
+
     # FAIL status is returned in ${vfmodule} because FAIL are ignored during teardown
     ${status}    ${vfmodule}=   Run Keyword and Ignore Error   Delete Next VID Entity    ${service_instance_id}    ${lcp_region}    ${tenant}   ${remove_order}
     Return From Keyword If    '${status}' == 'FAIL'
@@ -37,41 +37,41 @@ Delete VID
     Run Keyword If   'Vfmodule_Ete' in '${vfmodule}'    Execute Reverse Heatbridge
     Fail    Continue with Next Remove
 
-Delete Next VID Entity  
+Delete Next VID Entity
     [Documentation]    Teardown the next VID entity that has a Remove icon.
-    [Arguments]    ${service_instance_id}    ${lcp_region}    ${tenant}   ${remove_order}    
+    [Arguments]    ${service_instance_id}    ${lcp_region}    ${tenant}   ${remove_order}
     ${vfmodule}=    Catenate
     Go To    ${VID_SERVICE_MODELS_SEARCH_URL}
-    Wait Until Page Contains    Please search by    timeout=60s
-    Wait Until Page Contains Element    xpath=//div[@class='statusLine aaiHidden']    timeout=60s
-    Wait Until Element Is Not Visible    xpath=//div[@class='statusLine aaiHidden']    timeout=60s
-    
-    # If we don't wait for this control to be enabled, the submit results in a 'not found' pop-up (UnexpectedAlertPresentException) 
+    Wait Until Page Contains    Please search by    timeout=${GLOBAL_VID_UI_TIMEOUT_MEDIUM}
+    Wait Until Page Contains Element    xpath=//div[@class='statusLine aaiHidden']    timeout=${GLOBAL_VID_UI_TIMEOUT_MEDIUM}
+    Wait Until Element Is Not Visible    xpath=//div[@class='statusLine aaiHidden']    timeout=${GLOBAL_VID_UI_TIMEOUT_MEDIUM}
+
+    # If we don't wait for this control to be enabled, the submit results in a 'not found' pop-up (UnexpectedAlertPresentException)
     Input Text When Enabled    //input[@name='selectedServiceInstance']    ${service_instance_id}
 
     # When Handle alert detects a pop-up. it will return FAIL and we are done
     # Return from Keyword is required because FAIL is inored during teardown
     ${status}   ${value}   Run Keyword And Ignore Error    Handle Alert
     Return From Keyword If   '${status}' == 'FAIL'   ${status}
-    ${status}   ${value}   Run Keyword And Ignore Error    Wait Until Page Contains Element    link=View/Edit    timeout=60s
+    ${status}   ${value}   Run Keyword And Ignore Error    Wait Until Page Contains Element    link=View/Edit    timeout=${GLOBAL_VID_UI_TIMEOUT_MEDIUM}
     Return From Keyword If   '${status}' == 'FAIL'   ${status}
 
 
-    Click Element     link=View/Edit   
-    Wait Until Page Contains    View/Edit Service Instance     timeout=60s
-    Wait Until Element Is Visible    xpath=//a/span[@class='glyphicon glyphicon-remove']    timeout=120s
-    
-    :for   ${remove_first}    in    @{remove_order}  
+    Click Element     link=View/Edit
+    Wait Until Page Contains    View/Edit Service Instance     timeout=${GLOBAL_VID_UI_TIMEOUT_MEDIUM}
+    Wait Until Element Is Visible    xpath=//a/span[@class='glyphicon glyphicon-remove']    timeout=${GLOBAL_VID_UI_TIMEOUT_LONG}
+
+    :for   ${remove_first}    in    @{remove_order}
     \    ${remove_xpath}=    Set Variable   //li/div[contains(.,'${remove_first}')]/a/span[@class='glyphicon glyphicon-remove']
     \    ${status}    ${data}=   Run Keyword And Ignore Error    Page Should Contain Element     xpath=${remove_xpath}
-    \    Exit For Loop If    '${status}' == 'PASS'   
+    \    Exit For Loop If    '${status}' == 'PASS'
     \   ${remove_xpath}=    Set Variable   //li/div/a/span[@class='glyphicon glyphicon-remove']
-    Click On Element When Visible    xpath=${remove_xpath}    
+    Click On Element When Visible    xpath=${remove_xpath}
 
     ${status}   ${value}=   Run Keyword and Ignore Error   Wait Until Page Contains Element     xpath=//select[@parameter-id='lcpRegion']
-    Run Keyword If   '${status}'=='PASS'   Select From List By Label    xpath=//select[@parameter-id='lcpRegion']    ${lcp_region}      
+    Run Keyword If   '${status}'=='PASS'   Select From List By Label    xpath=//select[@parameter-id='lcpRegion']    ${lcp_region}
     Run Keyword If   '${status}'=='PASS'   Select From List By Label    xpath=//select[@parameter-id='tenant']    ${tenant}
-    ${status}   ${vfmodule}=    Run Keyword And Ignore Error    Get Text    xpath=//td[contains(text(), 'Vf Module Name')]/../td[2]      
+    ${status}   ${vfmodule}=    Run Keyword And Ignore Error    Get Text    xpath=//td[contains(text(), 'Vf Module Name')]/../td[2]
     Click Element    xpath=//div[@class='buttonRow']/button[@ngx-enabled='true']
     #//*[@id="mContent"]/div/div/div/div/table/tbody/tr/td/div/div[2]/div/div[1]/div[5]/button[1]
     Wait Until Page Contains    100 %     300s
@@ -80,12 +80,11 @@ Delete Next VID Entity
     Click Element    xpath=//div[@class='ng-scope']/div[@class = 'buttonRow']/button[text() = 'Close']
     Poll MSO Get Request    ${GLOBAL_MSO_STATUS_PATH}${request_id}   COMPLETE
     [Return]   ${vfmodule}
-  
+
 Handle Alert
     [Documentation]   When service instance has been deleted, an alert will be triggered on the search to end the loop
     ...   The various Alert keywords did not prevent the alert exception on the Click ELement, hence this roundabout way of handling the alert
-    Run Keyword And Ignore Error    Click Element    button=Submit   
+    Run Keyword And Ignore Error    Click Element    button=Submit
     ${status}   ${t}=    Run Keyword And Ignore Error    Get Alert Message
-    Return From Keyword If   '${status}' == 'FAIL'    
+    Return From Keyword If   '${status}' == 'FAIL'
     Fail    ${t}
-    
\ No newline at end of file
index 78b8148..1a45071 100644 (file)
@@ -4,7 +4,7 @@ Library             ExtendedSelenium2Library
 Library    Collections
 Library         String
 Library              RequestsLibrary
-Library                  UUID      
+Library                  UUID
 Resource        ../global_properties.robot
 Resource        ../browser_setup.robot
 
@@ -31,8 +31,8 @@ Run VID Get Request
     ${headers}=  Create Dictionary     username=${GLOBAL_VID_HEALTH_USERNAME}    password=${GLOBAL_VID_HEALTH_PASSWORD}    Accept=application/json    Content-Type=application/json    X-TransactionId=${GLOBAL_APPLICATION_ID}-${uuid}    X-FromAppId=${GLOBAL_APPLICATION_ID}
     ${resp}=   Get Request     vid     ${data_path}     headers=${headers}
     Log    Received response from vid ${resp.text}
-    [Return]    ${resp}   
-    
+    [Return]    ${resp}
+
 Login To VID GUI
     [Documentation]   Logs in to VID GUI
     # Setup Browser Now being managed by test case
@@ -47,55 +47,49 @@ Login To VID GUI
     Input Text    xpath=//input[@ng-model='loginId']    ${GLOBAL_VID_USERNAME}
     Input Password    xpath=//input[@ng-model='password']    ${GLOBAL_VID_PASSWORD}
     Click Button    xpath=//input[@id='loginBtn']
-    Wait Until Page Contains Element    xpath=//div[@class='applicationWindow']    ${GLOBAL_SELENIUM_BROWSER_WAIT_TIMEOUT}    
+    Wait Until Page Contains Element    xpath=//div[@class='applicationWindow']    ${GLOBAL_SELENIUM_BROWSER_WAIT_TIMEOUT}
     Log    Logged in to ${GLOBAL_VID_SERVER}${VID_ENV}
 
 Go To VID HOME
     [Documentation]    Naviage to VID Home
     Go To    ${VID_HOME_URL}
-    Wait Until Page Contains Element    xpath=//div[@class='applicationWindow']    ${GLOBAL_SELENIUM_BROWSER_WAIT_TIMEOUT}    
-        
+    Wait Until Page Contains Element    xpath=//div[@class='applicationWindow']    ${GLOBAL_SELENIUM_BROWSER_WAIT_TIMEOUT}
+
 Click On Button When Enabled
-    [Arguments]     ${xpath}    ${timeout}=60s
+    [Arguments]     ${xpath}    ${timeout}=${GLOBAL_VID_UI_TIMEOUT_MEDIUM}
     Wait Until Page Contains Element    xpath=${xpath}    ${timeout}
     Wait Until Element Is Enabled    xpath=${xpath}    ${timeout}
     Click Button      xpath=${xpath}
 
-Click On Button When Visible
-    [Arguments]     ${xpath}    ${timeout}=60s
-    Wait Until Page Contains Element    xpath=${xpath}    ${timeout}
-    Wait Until Element Is Visible    xpath=${xpath}    ${timeout}
-    Click Button      xpath=${xpath}
-   
 Click On Element When Visible
-    [Arguments]     ${xpath}    ${timeout}=60s
+    [Arguments]     ${xpath}    ${timeout}=${GLOBAL_VID_UI_TIMEOUT_MEDIUM}
     Wait Until Page Contains Element    xpath=${xpath}    ${timeout}
     Wait Until Element Is Visible    xpath=${xpath}    ${timeout}
     Click Element      xpath=${xpath}
-    
+
 Select From List When Enabled
-    [Arguments]     ${xpath}    ${value}    ${timeout}=60s
+    [Arguments]     ${xpath}    ${value}    ${timeout}=${GLOBAL_VID_UI_TIMEOUT_MEDIUM}
     Wait Until Page Contains Element    xpath=${xpath}    ${timeout}
     Wait Until Element Is Enabled    xpath=${xpath}    ${timeout}
-    Select From List     xpath=${xpath}    ${value}   
-    
-Input Text When Enabled        
-    [Arguments]     ${xpath}    ${value}    ${timeout}=60s
+    Select From List     xpath=${xpath}    ${value}
+
+Input Text When Enabled
+    [Arguments]     ${xpath}    ${value}    ${timeout}=${GLOBAL_VID_UI_TIMEOUT_MEDIUM}
     Wait Until Page Contains Element    xpath=${xpath}    ${timeout}
     Wait Until Element Is Enabled    xpath=${xpath}    ${timeout}
     Input Text    xpath=${xpath}    ${value}
-    
+
 Parse Request Id
-    [Arguments]    ${mso_response_text}                                        
+    [Arguments]    ${mso_response_text}
        ${request_list}=     Split String    ${mso_response_text}    202)\n    1
-       ${clean_string}=    Replace String    ${request_list[1]}    \n    ${empty}   
-    ${json}=    To Json    ${clean_string} 
+       ${clean_string}=    Replace String    ${request_list[1]}    \n    ${empty}
+    ${json}=    To Json    ${clean_string}
     ${request_id}=    Catenate    ${json['requestReferences']['requestId']}
     [Return]    ${request_id}
-    
+
 Parse Instance Id
-    [Arguments]    ${mso_response_text}                                        
+    [Arguments]    ${mso_response_text}
        ${request_list}=     Split String    ${mso_response_text}    202)\n    1
-    ${json}=    To Json    ${request_list[1]} 
+    ${json}=    To Json    ${request_list[1]}
     ${request_id}=    Catenate    ${json['requestReferences']['instanceId']}
     [Return]    ${request_id}
\ No newline at end of file