3 Library RequestsLibrary
4 Library OperatingSystem
6 Library ../../../scripts/clamp/python-lib/CustomSeleniumLibrary.py
12 ${SELENIUM_SPEED_FAST} .2 seconds
13 ${SELENIUM_SPEED_SLOW} .5 seconds
14 ${BASE_URL} https://localhost:8443
17 Get Requests health check ok
18 ${resp}= Get Request ${clamp_session} /restservices/clds/v1/healthcheck
19 Should Be Equal As Strings ${resp.status_code} 200
22 # Next line is to be enabled for Headless tests only (jenkins?). To see the tests disable the line.
23 Start Virtual Display 1920 1080
24 Set Selenium Speed ${SELENIUM_SPEED_SLOW}
25 Open Browser ${BASE_URL}/designer/index.html browser=firefox
27 Reply to authentication popup
28 Run Keyword And Ignore Error Insert into prompt ${login} ${passw}
31 Good Login to Clamp UI and Verify logged in
32 Set Window Size 1920 1080
34 Should Be Equal CLDS ${title}
35 Wait Until Element Is Visible xpath=//*[@class="navbar-brand logo_name ng-binding"] timeout=60
36 Element Text Should Be xpath=//*[@class="navbar-brand logo_name ng-binding"] expected=Hello:admin
39 # Wait Until Element Is Visible xpath=//*[@id="navbar"]/ul/li[1]/a timeout=60
40 # Click Element xpath=//*[@id="navbar"]/ul/li[1]/a
41 # Wait Until Element Is Visible locator=Open CL timeout=60
42 # Click Element locator=Open CL
43 # Select From List By Label id=modelName TCAModel1
44 # Click Button locator=OK
45 # Element Should Contain xpath=//*[@id="modeler_name"] Closed Loop Modeler - TCAModel1
46 # Element Should Contain xpath=//*[@id="status_clds"] DESIGN
49 # Wait Until Element Is Visible xpath=//*[@id="navbar"]/ul/li[2]/a timeout=60
50 # Click Element xpath=//*[@id="navbar"]/ul/li[2]/a
51 # Wait Until Element Is Visible locator=Validation Test timeout=60
52 # Click Element locator=Validation Test
53 # Wait Until Element Is Visible xpath=//*[@id="alert_message_"] timeout=60
54 # Element Text Should Be xpath=//*[@id="alert_message_"] expected=Action Successful: test
55 # Element Should Contain xpath=//*[@id="status_clds"] DESIGN
58 # Wait Until Element Is Visible xpath=//*[@id="navbar"]/ul/li[2]/a timeout=60
59 # Click Element xpath=//*[@id="navbar"]/ul/li[2]/a
60 # Wait Until Element Is Visible locator=Submit timeout=60
61 # Click Element locator=Submit
62 # Click Button locator=Yes
63 # Wait Until Element Is Visible xpath=//*[@id="alert_message_"] timeout=60
64 # Element Text Should Be xpath=//*[@id="alert_message_"] expected=Action Successful: submit
65 # Element Should Contain xpath=//*[@id="status_clds"] DISTRIBUTED
68 # Wait Until Element Is Visible xpath=//*[@id="navbar"]/ul/li[2]/a timeout=60
69 # Click Element xpath=//*[@id="navbar"]/ul/li[2]/a
70 # Wait Until Element Is Visible locator=Resubmit timeout=60
71 # Click Element locator=Resubmit
72 # Click Button locator=Yes
73 # Wait Until Element Is Visible xpath=//*[@id="alert_message_"] timeout=60
74 # Element Text Should Be xpath=//*[@id="alert_message_"] expected=Action Successful: resubmit
75 # Element Should Contain xpath=//*[@id="status_clds"] DISTRIBUTED
78 # Wait Until Element Is Visible xpath=//*[@id="navbar"]/ul/li[2]/a timeout=60
79 # Click Element xpath=//*[@id="navbar"]/ul/li[2]/a
80 # Wait Until Element Is Visible locator=Deploy timeout=60
81 # Click Element locator=Deploy
82 ## Wait Until Element Is Visible xpath=//*[@id="deployProperties"] timeout=60
83 ## Input Text xpath=//*[@id="deployProperties"] text={}
84 # Click Button locator=Deploy
85 # Click Button locator=Yes
86 # Wait Until Element Is Visible xpath=//*[@id="alert_message_"] timeout=60
87 # Element Text Should Be xpath=//*[@id="alert_message_"] expected=Action Successful: deploy
88 # Element Should Contain xpath=//*[@id="status_clds"] ACTIVE
91 # Wait Until Element Is Visible xpath=//*[@id="navbar"]/ul/li[2]/a timeout=60
92 # Click Element xpath=//*[@id="navbar"]/ul/li[2]/a
93 # Wait Until Element Is Visible locator=Update timeout=60
94 # Click Element locator=Update
95 # Click Button locator=Yes
96 # Wait Until Element Is Visible xpath=//*[@id="alert_message_"] timeout=60
97 # Element Text Should Be xpath=//*[@id="alert_message_"] expected=Action Successful: update
98 # Element Should Contain xpath=//*[@id="status_clds"] ACTIVE
101 # Wait Until Element Is Visible xpath=//*[@id="navbar"]/ul/li[2]/a timeout=60
102 # Click Element xpath=//*[@id="navbar"]/ul/li[2]/a
103 # Wait Until Element Is Visible locator=Stop timeout=60
104 # Click Element locator=Stop
105 # Click Button locator=Yes
106 # Wait Until Element Is Visible xpath=//*[@id="alert_message_"] timeout=60
107 # Element Text Should Be xpath=//*[@id="alert_message_"] expected=Action Successful: stop
108 # Element Should Contain xpath=//*[@id="status_clds"] STOPPED
111 # Wait Until Element Is Visible xpath=//*[@id="navbar"]/ul/li[2]/a timeout=60
112 # Click Element xpath=//*[@id="navbar"]/ul/li[2]/a
113 # Wait Until Element Is Visible locator=Restart timeout=60
114 # Click Element locator=Restart
115 # Click Button locator=Yes
116 # Wait Until Element Is Visible xpath=//*[@id="alert_message_"] timeout=60
117 # Element Text Should Be xpath=//*[@id="alert_message_"] expected=Action Successful: restart
118 # Element Should Contain xpath=//*[@id="status_clds"] ACTIVE
121 # Wait Until Element Is Visible xpath=//*[@id="navbar"]/ul/li[2]/a timeout=60
122 # Click Element xpath=//*[@id="navbar"]/ul/li[2]/a
123 # Wait Until Element Is Visible locator=UnDeploy timeout=60
124 # Click Element locator=UnDeploy
125 # Click Button locator=Yes
126 # Wait Until Element Is Visible xpath=//*[@id="alert_message_"] timeout=60
127 # Element Text Should Be xpath=//*[@id="alert_message_"] expected=Action Successful: undeploy
128 # Element Should Contain xpath=//*[@id="status_clds"] DISTRIBUTED