2 Documentation Creates VID Service Instance
4 ... Creates VID Service Instance
6 Library ExtendedSelenium2Library
11 Resource ../mso_interface.robot
12 Resource vid_interface.robot
15 Create VID Service Instance
16 [Documentation] Creates a service instance using VID
17 [Arguments] ${customer_name} ${service_model_type} ${service_type} ${service_name}
19 Wait Until Keyword Succeeds 300s 1s Wait For Model ${service_model_type}
20 Press Key xpath=//tr[td/span/text() = '${service_model_type}']/td/button[text() = 'Deploy' and not(@disabled)] \\13
21 ${uuid}= Generate UUID
22 Wait Until Page Contains Element xpath=//input[@parameter-name='Instance Name'] 120s
23 Wait Until Element Is Visible xpath=//input[@parameter-name='Instance Name'] 120s
24 Xpath Should Match X Times //input[@parameter-name='Instance Name'] 1
25 Input Text When Enabled //input[@parameter-name='Instance Name'] ${service_name}
26 Select From List When Enabled //select[@prompt='Select Subscriber Name'] ${customer_name}
27 Select From List WHen Enabled //select[@prompt='Select Service Type'] ${service_type}
28 Click On Button When Enabled //div[@class = 'buttonRow']/button[text() = 'Confirm']
29 Wait Until Element Contains xpath=//div[@ng-controller= 'msoCommitController']/pre[@class = 'log ng-binding'] requestId timeout=120s
30 ${response text}= Get Text xpath=//div[@ng-controller= 'msoCommitController']/pre[@class = 'log ng-binding']
31 Click On Button When Enabled //div[@class = 'buttonRow']/button[text() = 'Close']
32 ${request_id}= Parse Request Id ${response text}
33 ${service_instance_id}= Parse Instance Id ${response text}
34 Poll MSO Get Request ${GLOBAL_MSO_STATUS_PATH}${request_id} COMPLETE
35 [return] ${service_instance_id}
38 [Documentation] Distributed model may not yet be available. Kepp trying until it shows up.
39 [Arguments] ${service_model_type}
40 Click Element partial link=Browse SDC Service
41 Page Should Contain Element xpath=//div/h1[text() = 'Browse SDC Service Models']
42 Wait Until Page Contains Element xpath=//button[text() = 'Deploy'] 240s
43 Input Text When Enabled //input[@ng-model='searchString'] ${service_model_type}
44 Wait Until Element Is Visible xpath=//tr[td/span/text() = '${service_model_type}']/td/button[contains(text(),'Deploy')] 10s
46 Delete Service Instance By GUI
47 [Arguments] ${service_instance_id} ${customer_name}
48 Click On Element When Visible xpath=//a/span[@class='glyphicon glyphicon-remove']
49 Click On Button When Visible xpath=//div[@class='buttonRow']/button[@ngx-enabled='true']
50 Wait Until Element Contains xpath=//div[@ng-controller='deletionDialogController']//div[@ng-controller= 'msoCommitController']/pre[@class = 'log ng-binding'] requestId timeout=120s
51 ${response text}= Get Text xpath=//div[@ng-controller='deletionDialogController']//div[@ng-controller= 'msoCommitController']/pre[@class = 'log ng-binding']
52 ${request_id}= Parse Request Id ${response text}
53 Poll MSO Get Request ${GLOBAL_MSO_STATUS_PATH}${request_id} COMPLETE
56 Search Service Instance
57 [Arguments] ${service_instance_id} ${customer_name}
58 Click Link xpath=//div[@heading = 'Search for Existing Service Instances']/a
59 Input Text When Enabled //input[@name='selectedServiceInstance'] ${service_instance_id}
60 Click On Button When Enabled //button[text() = 'Submit']