kishore | 328996f | 2017-09-08 17:15:42 -0500 | [diff] [blame] | 1 | *** Settings *** |
| 2 | Documentation This is RobotFrame work script |
CHINTAMANI | af44d44 | 2018-04-25 12:38:44 -0400 | [diff] [blame] | 3 | Library ExtendedSelenium2Library |
| 4 | Library OperatingSystem |
| 5 | Library eteutils/RequestsClientCert.py |
| 6 | Library RequestsLibrary |
| 7 | Library eteutils/UUID.py |
| 8 | Library DateTime |
| 9 | Library Collections |
| 10 | Library eteutils/OSUtils.py |
| 11 | Library eteutils/StringTemplater.py |
| 12 | Library String |
| 13 | Library XvfbRobot |
| 14 | Resource json_templater.robot |
kishore | 328996f | 2017-09-08 17:15:42 -0500 | [diff] [blame] | 15 | |
| 16 | *** Variables *** |
kishore | 4089a33 | 2017-10-18 17:02:53 -0500 | [diff] [blame] | 17 | ${PORTAL_URL} http://portal.api.simpledemo.onap.org:8989 |
| 18 | ${PORTAL_ENV} /ONAPPORTAL |
kishore | 6eebdba | 2017-10-03 11:12:57 -0500 | [diff] [blame] | 19 | ${PORTAL_LOGIN_URL} ${PORTAL_URL}${PORTAL_ENV}/login.htm |
| 20 | ${PORTAL_HOME_PAGE} ${PORTAL_URL}${PORTAL_ENV}/applicationsHome |
| 21 | ${PORTAL_MICRO_ENDPOINT} ${PORTAL_URL}${PORTAL_ENV}/commonWidgets |
| 22 | ${PORTAL_HOME_URL} ${PORTAL_URL}${PORTAL_ENV}/applicationsHome |
kishore | 5ea942b | 2017-10-14 22:19:45 -0500 | [diff] [blame] | 23 | ${App_First_Name} demoapp |
kishore | 6eebdba | 2017-10-03 11:12:57 -0500 | [diff] [blame] | 24 | ${App_Last_Name} demo |
kishore | 5ea942b | 2017-10-14 22:19:45 -0500 | [diff] [blame] | 25 | ${App_Email_Address} demoapp@onap.com |
| 26 | ${App_LoginID} demoapp |
kishore | 6eebdba | 2017-10-03 11:12:57 -0500 | [diff] [blame] | 27 | ${App_Loginpwd} demo123456! |
| 28 | ${App_LoginPwdCheck} demo123456! |
kishore | 5ea942b | 2017-10-14 22:19:45 -0500 | [diff] [blame] | 29 | ${Sta_First_Name} demosta |
kishore | 6eebdba | 2017-10-03 11:12:57 -0500 | [diff] [blame] | 30 | ${Sta_Last_Name} demo |
kishore | 5ea942b | 2017-10-14 22:19:45 -0500 | [diff] [blame] | 31 | ${Sta_Email_Address} demosta@onap.com |
| 32 | ${Sta_LoginID} demosta |
kishore | 6eebdba | 2017-10-03 11:12:57 -0500 | [diff] [blame] | 33 | ${Sta_Loginpwd} demo123456! |
| 34 | ${Sta_LoginPwdCheck} demo123456! |
| 35 | ${Test_First_Name} portal |
| 36 | ${Test_Last_Name} demo |
| 37 | ${Test_Email_Address} portal@onap.com |
| 38 | ${Test_LoginID} portal |
| 39 | ${Test_Loginpwd} demo123456! |
| 40 | ${Test_LoginPwdCheck} demo123456! |
| 41 | ${Existing_User} portal |
kishore | 4089a33 | 2017-10-18 17:02:53 -0500 | [diff] [blame] | 42 | ${PORTAL_HEALTH_CHECK_PATH} /ONAPPORTAL/portalApi/healthCheck |
kishore | 6eebdba | 2017-10-03 11:12:57 -0500 | [diff] [blame] | 43 | ${PORTAL_ASSETS_DIRECTORY} ${CURDIR} |
| 44 | ${GLOBAL_APPLICATION_ID} robot-functional |
| 45 | ${GLOBAL_PORTAL_ADMIN_USER} demo |
| 46 | ${GLOBAL_PORTAL_ADMIN_PWD} demo123456! |
CHINTAMANI | af44d44 | 2018-04-25 12:38:44 -0400 | [diff] [blame] | 47 | ${AppAccountName} testApp |
| 48 | ${AppUserName} testApp |
| 49 | ${AppPassword} testApp123! |
kishore | 6eebdba | 2017-10-03 11:12:57 -0500 | [diff] [blame] | 50 | ${GLOBAL_MSO_STATUS_PATH} /ecomp/mso/infra/orchestrationRequests/v2/ |
| 51 | ${GLOBAL_SELENIUM_BROWSER} chrome |
| 52 | ${GLOBAL_SELENIUM_BROWSER_CAPABILITIES} Create Dictionary |
| 53 | ${GLOBAL_SELENIUM_DELAY} 0 |
| 54 | ${GLOBAL_SELENIUM_BROWSER_IMPLICIT_WAIT} 5 |
| 55 | ${GLOBAL_SELENIUM_BROWSER_WAIT_TIMEOUT} 15 |
| 56 | ${GLOBAL_OPENSTACK_HEAT_SERVICE_TYPE} orchestration |
| 57 | ${GLOBAL_OPENSTACK_CINDER_SERVICE_TYPE} volume |
| 58 | ${GLOBAL_OPENSTACK_NOVA_SERVICE_TYPE} compute |
| 59 | ${GLOBAL_OPENSTACK_NEUTRON_SERVICE_TYPE} network |
| 60 | ${GLOBAL_OPENSTACK_GLANCE_SERVICE_TYPE} image |
| 61 | ${GLOBAL_OPENSTACK_KEYSTONE_SERVICE_TYPE} identity |
| 62 | ${GLOBAL_BUILD_NUMBER} 0 |
| 63 | ${GLOBAL_VM_PRIVATE_KEY} ${EXECDIR}/robot/assets/keys/robot_ssh_private_key.pvt |
| 64 | ${jira} jira |
kishore | 4089a33 | 2017-10-18 17:02:53 -0500 | [diff] [blame] | 65 | ${RESOURCE_PATH} ONAPPORTAL/auxapi/ticketevent |
kishore | 6eebdba | 2017-10-03 11:12:57 -0500 | [diff] [blame] | 66 | ${portal_Template} ${CURDIR}/portal.template |
| 67 | |
CHINTAMANI | 68e9836 | 2018-04-10 18:56:38 -0400 | [diff] [blame] | 68 | ${Result} FALSE |
CHINTAMANI | af44d44 | 2018-04-25 12:38:44 -0400 | [diff] [blame] | 69 | ${td_id} 0 |
| 70 | ${download_link_id} 0 |
kishore | 328996f | 2017-09-08 17:15:42 -0500 | [diff] [blame] | 71 | |
| 72 | *** Test Cases *** |
| 73 | |
| 74 | Portal Health Check |
| 75 | Run Portal Health Check |
kishore | bbca0cf | 2017-10-09 16:59:38 -0500 | [diff] [blame] | 76 | |
| 77 | Login into Portal URL |
| 78 | Portal admin Login To Portal GUI |
| 79 | |
CHINTAMANI | 68e9836 | 2018-04-10 18:56:38 -0400 | [diff] [blame] | 80 | # Portal R1 Release |
| 81 | # [Documentation] ONAP Portal R1 functionality test |
| 82 | # Notification on ONAP Portal |
| 83 | # Portal Application Account Management validation |
kishore | bbca0cf | 2017-10-09 16:59:38 -0500 | [diff] [blame] | 84 | |
| 85 | Portal R1 Release for AAF |
| 86 | [Documentation] ONAP Portal R1 functionality for AAF test |
| 87 | Portal AAF new fields |
| 88 | |
CHINTAMANI | af44d44 | 2018-04-25 12:38:44 -0400 | [diff] [blame] | 89 | Create Microse service onboarding |
| 90 | Portal admin Microservice Onboarding |
kishore | 5ea942b | 2017-10-14 22:19:45 -0500 | [diff] [blame] | 91 | |
CHINTAMANI | af44d44 | 2018-04-25 12:38:44 -0400 | [diff] [blame] | 92 | ##Delete Microse service |
| 93 | ##Portal admin Microservice Delete |
kishore | 5ea942b | 2017-10-14 22:19:45 -0500 | [diff] [blame] | 94 | |
CHINTAMANI | af44d44 | 2018-04-25 12:38:44 -0400 | [diff] [blame] | 95 | Create Widget for all users |
| 96 | Portal Admin Create Widget for All users |
kishore | 5ea942b | 2017-10-14 22:19:45 -0500 | [diff] [blame] | 97 | |
CHINTAMANI | af44d44 | 2018-04-25 12:38:44 -0400 | [diff] [blame] | 98 | Delete Widget for all users |
| 99 | Portal Admin Delete Widget for All users |
CHINTAMANI | 68e9836 | 2018-04-10 18:56:38 -0400 | [diff] [blame] | 100 | |
CHINTAMANI | af44d44 | 2018-04-25 12:38:44 -0400 | [diff] [blame] | 101 | Create Widget for Application Roles |
| 102 | Portal Admin Create Widget for Application Roles |
kishore | bbca0cf | 2017-10-09 16:59:38 -0500 | [diff] [blame] | 103 | |
CHINTAMANI | 68e9836 | 2018-04-10 18:56:38 -0400 | [diff] [blame] | 104 | #Delete Widget for Application Roles |
CHINTAMANI | af44d44 | 2018-04-25 12:38:44 -0400 | [diff] [blame] | 105 | #Portal Admin Delete Widget for Application Roles |
CHINTAMANI | 68e9836 | 2018-04-10 18:56:38 -0400 | [diff] [blame] | 106 | |
CHINTAMANI | af44d44 | 2018-04-25 12:38:44 -0400 | [diff] [blame] | 107 | #EP Admin widget download |
| 108 | #Admin widget download |
kishore | bbca0cf | 2017-10-09 16:59:38 -0500 | [diff] [blame] | 109 | |
CHINTAMANI | af44d44 | 2018-04-25 12:38:44 -0400 | [diff] [blame] | 110 | #EP Admin widget layout reset |
| 111 | #Reset widget layout option |
| 112 | |
| 113 | Validate Functional Top Menu Get Access |
| 114 | Functional Top Menu Get Access |
CHINTAMANI | 68e9836 | 2018-04-10 18:56:38 -0400 | [diff] [blame] | 115 | |
CHINTAMANI | af44d44 | 2018-04-25 12:38:44 -0400 | [diff] [blame] | 116 | Validate Functional Top Menu Contact Us |
| 117 | Functional Top Menu Contact Us |
kishore | bbca0cf | 2017-10-09 16:59:38 -0500 | [diff] [blame] | 118 | |
CHINTAMANI | af44d44 | 2018-04-25 12:38:44 -0400 | [diff] [blame] | 119 | Edit Functional Menu |
| 120 | Portal admin Edit Functional menu |
kishore | bbca0cf | 2017-10-09 16:59:38 -0500 | [diff] [blame] | 121 | |
CHINTAMANI | af44d44 | 2018-04-25 12:38:44 -0400 | [diff] [blame] | 122 | Broadbond Notification functionality |
| 123 | ${AdminBroadCastMsg}= Portal Admin Broadcast Notifications |
| 124 | set global variable ${AdminBroadCastMsg} |
kishore | bbca0cf | 2017-10-09 16:59:38 -0500 | [diff] [blame] | 125 | |
CHINTAMANI | af44d44 | 2018-04-25 12:38:44 -0400 | [diff] [blame] | 126 | Category Notification functionality |
| 127 | ${AdminCategoryMsg}= Portal Admin Category Notifications |
| 128 | set global variable ${AdminCategoryMsg} |
CHINTAMANI | 68e9836 | 2018-04-10 18:56:38 -0400 | [diff] [blame] | 129 | |
CHINTAMANI | af44d44 | 2018-04-25 12:38:44 -0400 | [diff] [blame] | 130 | Create a Test user for Application Admin -Test |
| 131 | Portal admin Add Application admin User New user -Test |
kishore | 5ea942b | 2017-10-14 22:19:45 -0500 | [diff] [blame] | 132 | |
CHINTAMANI | af44d44 | 2018-04-25 12:38:44 -0400 | [diff] [blame] | 133 | Create a Test User for Apllication Admin |
| 134 | Portal admin Add Application admin User New user |
kishore | 5ea942b | 2017-10-14 22:19:45 -0500 | [diff] [blame] | 135 | |
CHINTAMANI | af44d44 | 2018-04-25 12:38:44 -0400 | [diff] [blame] | 136 | Add Application Admin for Existing User Test user |
| 137 | Portal admin Add Application Admin Exiting User -APPDEMO |
kishore | 5ea942b | 2017-10-14 22:19:45 -0500 | [diff] [blame] | 138 | |
CHINTAMANI | af44d44 | 2018-04-25 12:38:44 -0400 | [diff] [blame] | 139 | Create a Test user for Standared User |
| 140 | Portal admin Add Standard User New user |
kishore | 5ea942b | 2017-10-14 22:19:45 -0500 | [diff] [blame] | 141 | |
CHINTAMANI | af44d44 | 2018-04-25 12:38:44 -0400 | [diff] [blame] | 142 | Add Application Admin for Exisitng User |
| 143 | Portal admin Add Application Admin Exiting User |
kishore | 5ea942b | 2017-10-14 22:19:45 -0500 | [diff] [blame] | 144 | |
CHINTAMANI | af44d44 | 2018-04-25 12:38:44 -0400 | [diff] [blame] | 145 | Delete Application Admin for Exisitng User |
| 146 | Portal admin Delete Application Admin Existing User |
kishore | 5ea942b | 2017-10-14 22:19:45 -0500 | [diff] [blame] | 147 | |
CHINTAMANI | af44d44 | 2018-04-25 12:38:44 -0400 | [diff] [blame] | 148 | #Add Standard User Role for Existing user |
| 149 | #Portal admin Add Standard User Existing user |
kishore | 5ea942b | 2017-10-14 22:19:45 -0500 | [diff] [blame] | 150 | |
CHINTAMANI | af44d44 | 2018-04-25 12:38:44 -0400 | [diff] [blame] | 151 | #Edit Standard User Role for Existing user |
| 152 | #Portal admin Edit Standard User Existing user |
kishore | 5ea942b | 2017-10-14 22:19:45 -0500 | [diff] [blame] | 153 | |
CHINTAMANI | 68e9836 | 2018-04-10 18:56:38 -0400 | [diff] [blame] | 154 | #Delete Standard User Role for Existing user |
CHINTAMANI | af44d44 | 2018-04-25 12:38:44 -0400 | [diff] [blame] | 155 | #Portal admin Delete Standard User Existing user |
kishore | 5ea942b | 2017-10-14 22:19:45 -0500 | [diff] [blame] | 156 | |
CHINTAMANI | af44d44 | 2018-04-25 12:38:44 -0400 | [diff] [blame] | 157 | #Add Account new account from App Account Management |
| 158 | #Portal admin Add New Account |
| 159 | |
| 160 | #Delete Account new account from App Account Management |
| 161 | #Portal admin Delete Account |
| 162 | |
| 163 | Logout from Portal GUI as Portal Admin |
| 164 | Portal admin Logout from Portal GUI |
| 165 | |
| 166 | ## Application Admin user Test cases |
CHINTAMANI | 68e9836 | 2018-04-10 18:56:38 -0400 | [diff] [blame] | 167 | |
CHINTAMANI | af44d44 | 2018-04-25 12:38:44 -0400 | [diff] [blame] | 168 | Login To Portal GUI as APP Admin |
| 169 | Application admin Login To Portal GUI |
CHINTAMANI | 68e9836 | 2018-04-10 18:56:38 -0400 | [diff] [blame] | 170 | |
kishore | 92d70d6 | 2017-10-11 14:51:31 -0500 | [diff] [blame] | 171 | ##Navigate Functional Link as APP Admin |
CHINTAMANI | af44d44 | 2018-04-25 12:38:44 -0400 | [diff] [blame] | 172 | ##Application Admin Navigation Functional Menu |
kishore | bbca0cf | 2017-10-09 16:59:38 -0500 | [diff] [blame] | 173 | |
CHINTAMANI | af44d44 | 2018-04-25 12:38:44 -0400 | [diff] [blame] | 174 | #Add Standard User Role for Existing user as APP Admin |
| 175 | #Application admin Add Standard User Existing user |
kishore | bbca0cf | 2017-10-09 16:59:38 -0500 | [diff] [blame] | 176 | |
CHINTAMANI | af44d44 | 2018-04-25 12:38:44 -0400 | [diff] [blame] | 177 | #Edit Standard User Role for Existing user as APP Admin |
| 178 | #Application admin Edit Standard User Existing user |
kishore | bbca0cf | 2017-10-09 16:59:38 -0500 | [diff] [blame] | 179 | |
CHINTAMANI | af44d44 | 2018-04-25 12:38:44 -0400 | [diff] [blame] | 180 | #Delete Standard User Role for Existing user as APP Admin |
| 181 | #Application admin Delete Standard User Existing user |
kishore | 5ea942b | 2017-10-14 22:19:45 -0500 | [diff] [blame] | 182 | |
CHINTAMANI | af44d44 | 2018-04-25 12:38:44 -0400 | [diff] [blame] | 183 | #Navigate Application Link as APP Admin |
| 184 | #Application Admin Navigation Application Link Tab |
kishore | bbca0cf | 2017-10-09 16:59:38 -0500 | [diff] [blame] | 185 | |
CHINTAMANI | af44d44 | 2018-04-25 12:38:44 -0400 | [diff] [blame] | 186 | Logout from Portal GUI as APP Admin |
| 187 | Application admin Logout from Portal GUI |
kishore | bbca0cf | 2017-10-09 16:59:38 -0500 | [diff] [blame] | 188 | |
CHINTAMANI | af44d44 | 2018-04-25 12:38:44 -0400 | [diff] [blame] | 189 | ##Standard User Test cases |
kishore | bbca0cf | 2017-10-09 16:59:38 -0500 | [diff] [blame] | 190 | |
CHINTAMANI | af44d44 | 2018-04-25 12:38:44 -0400 | [diff] [blame] | 191 | Login To Portal GUI as Standared User |
| 192 | Standared user Login To Portal GUI |
kishore | bbca0cf | 2017-10-09 16:59:38 -0500 | [diff] [blame] | 193 | |
| 194 | #Navigate Application Link as Standared User |
CHINTAMANI | af44d44 | 2018-04-25 12:38:44 -0400 | [diff] [blame] | 195 | #Standared user Navigation Application Link Tab |
kishore | bbca0cf | 2017-10-09 16:59:38 -0500 | [diff] [blame] | 196 | |
CHINTAMANI | af44d44 | 2018-04-25 12:38:44 -0400 | [diff] [blame] | 197 | #Navigate Functional Link as Standared User |
| 198 | #Standared user Navigation Functional Menu |
kishore | bbca0cf | 2017-10-09 16:59:38 -0500 | [diff] [blame] | 199 | |
CHINTAMANI | af44d44 | 2018-04-25 12:38:44 -0400 | [diff] [blame] | 200 | #Broadcast Notifications Standared user |
| 201 | #Standared user Broadcast Notifications ${AdminBroadCastMsg} |
kishore | bbca0cf | 2017-10-09 16:59:38 -0500 | [diff] [blame] | 202 | |
CHINTAMANI | af44d44 | 2018-04-25 12:38:44 -0400 | [diff] [blame] | 203 | #Category Notifications Standared user |
| 204 | #Standared user Category Notifications ${AdminCategoryMsg} |
kishore | bbca0cf | 2017-10-09 16:59:38 -0500 | [diff] [blame] | 205 | |
CHINTAMANI | af44d44 | 2018-04-25 12:38:44 -0400 | [diff] [blame] | 206 | Logout from Portal GUI as Standared User |
| 207 | Standared User Logout from Portal GUI |
kishore | bbca0cf | 2017-10-09 16:59:38 -0500 | [diff] [blame] | 208 | |
kishore | 328996f | 2017-09-08 17:15:42 -0500 | [diff] [blame] | 209 | Teardown |
kishore | bbca0cf | 2017-10-09 16:59:38 -0500 | [diff] [blame] | 210 | [Documentation] Close All Open browsers |
| 211 | Close All Browsers |
kishore | 328996f | 2017-09-08 17:15:42 -0500 | [diff] [blame] | 212 | |
kishore | 328996f | 2017-09-08 17:15:42 -0500 | [diff] [blame] | 213 | *** Keywords *** |
kishore | 6eebdba | 2017-10-03 11:12:57 -0500 | [diff] [blame] | 214 | |
| 215 | Setup Browser |
| 216 | [Documentation] Sets up browser based upon the value of ${GLOBAL_SELENIUM_BROWSER} |
| 217 | # Run Keyword If '${GLOBAL_SELENIUM_BROWSER}' == 'firefox' Setup Browser Firefox |
| 218 | Run Keyword If '${GLOBAL_SELENIUM_BROWSER}' == 'chrome' Setup Browser Chrome |
| 219 | Log Running with ${GLOBAL_SELENIUM_BROWSER} |
| 220 | |
| 221 | |
| 222 | Setup Browser Chrome |
| 223 | ${os}= Get Normalized Os |
| 224 | Log Normalized OS=${os} |
| 225 | ${chrome options}= Evaluate sys.modules['selenium.webdriver'].ChromeOptions() sys |
| 226 | Call Method ${chrome options} add_argument no-sandbox |
| 227 | ${dc} Evaluate sys.modules['selenium.webdriver'].DesiredCapabilities.CHROME sys, selenium.webdriver |
| 228 | Set To Dictionary ${dc} elementScrollBehavior 1 |
| 229 | Create Webdriver Chrome chrome_options=${chrome_options} desired_capabilities=${dc} |
| 230 | Set Global Variable ${GLOBAL_SELENIUM_BROWSER_CAPABILITIES} ${dc} |
| 231 | |
| 232 | Handle Proxy Warning |
| 233 | [Documentation] Handle Intermediate Warnings from Proxies |
| 234 | ${status} ${data}= Run Keyword And Ignore Error Variable Should Exist \${GLOBAL_PROXY_WARNING_TITLE} |
| 235 | Return From Keyword if '${status}' != 'PASS' |
| 236 | ${status} ${data}= Run Keyword And Ignore Error Variable Should Exist \${GLOBAL_PROXY_WARNING_CONTINUE_XPATH} |
| 237 | Return From Keyword if '${status}' != 'PASS' |
| 238 | Return From Keyword if "${GLOBAL_PROXY_WARNING_TITLE}" == '' |
| 239 | Return From Keyword if "${GLOBAL_PROXY_WARNING_CONTINUE_XPATH}" == '' |
| 240 | ${test} ${value}= Run keyword and ignore error Title Should Be ${GLOBAL_PROXY_WARNING_TITLE} |
| 241 | Run keyword If '${test}' == 'PASS' Click Element xpath=${GLOBAL_PROXY_WARNING_CONTINUE_XPATH} |
| 242 | |
| 243 | |
kishore | 6eebdba | 2017-10-03 11:12:57 -0500 | [diff] [blame] | 244 | Run Portal Health Check |
| 245 | [Documentation] Runs Portal Health check |
| 246 | ${resp}= Run Portal Get Request ${PORTAL_HEALTH_CHECK_PATH} |
| 247 | Should Be Equal As Strings ${resp.status_code} 200 |
| 248 | Should Be Equal As Strings ${resp.json()['statusCode']} 200 |
CHINTAMANI | af44d44 | 2018-04-25 12:38:44 -0400 | [diff] [blame] | 249 | |
kishore | 6eebdba | 2017-10-03 11:12:57 -0500 | [diff] [blame] | 250 | Run Portal Get Request |
| 251 | [Documentation] Runs Portal Get request |
| 252 | [Arguments] ${data_path} |
| 253 | ${session}= Create Session portal ${PORTAL_URL} |
| 254 | ${uuid}= Generate UUID |
| 255 | ${headers}= Create Dictionary Accept=application/json Content-Type=application/json X-TransactionId=${GLOBAL_APPLICATION_ID}-${uuid} X-FromAppId=${GLOBAL_APPLICATION_ID} |
| 256 | ${resp}= Get Request portal ${data_path} headers=${headers} |
| 257 | Log Received response from portal ${resp.text} |
| 258 | [Return] ${resp} |
| 259 | |
| 260 | |
| 261 | Portal admin Login To Portal GUI |
| 262 | [Documentation] Logs into Portal GUI |
| 263 | ## Setup Browser Now being managed by test case |
kishore | bbca0cf | 2017-10-09 16:59:38 -0500 | [diff] [blame] | 264 | # Setup Browser |
kishore | 6eebdba | 2017-10-03 11:12:57 -0500 | [diff] [blame] | 265 | Start Virtual Display 1920 1080 |
| 266 | Open Browser ${PORTAL_LOGIN_URL} chrome |
kishore | bbca0cf | 2017-10-09 16:59:38 -0500 | [diff] [blame] | 267 | # Go To ${PORTAL_LOGIN_URL} |
kishore | 6eebdba | 2017-10-03 11:12:57 -0500 | [diff] [blame] | 268 | Maximize Browser Window |
| 269 | Set Selenium Speed ${GLOBAL_SELENIUM_DELAY} |
| 270 | Set Browser Implicit Wait ${GLOBAL_SELENIUM_BROWSER_IMPLICIT_WAIT} |
| 271 | Log Logging in to ${PORTAL_URL}${PORTAL_ENV} |
| 272 | # Handle Proxy Warning |
| 273 | Title Should Be Login |
| 274 | Input Text xpath=//input[@ng-model='loginId'] ${GLOBAL_PORTAL_ADMIN_USER} |
| 275 | Input Password xpath=//input[@ng-model='password'] ${GLOBAL_PORTAL_ADMIN_PWD} |
| 276 | Click Link xpath=//a[@id='loginBtn'] |
| 277 | Wait Until Page Contains Element xpath=//img[@alt='Onap Logo'] ${GLOBAL_SELENIUM_BROWSER_WAIT_TIMEOUT} |
CHINTAMANI | af44d44 | 2018-04-25 12:38:44 -0400 | [diff] [blame] | 278 | #Execute Javascript document.getElementById('w-ecomp-footer').style.display = 'none' |
| 279 | Log Logged in to ${PORTAL_URL}${PORTAL_ENV} |
kishore | 6eebdba | 2017-10-03 11:12:57 -0500 | [diff] [blame] | 280 | |
| 281 | Portal admin Go To Portal HOME |
| 282 | [Documentation] Naviage to Portal Home |
| 283 | Go To ${PORTAL_HOME_URL} |
| 284 | Wait Until Page Contains Element xpath=//div[@class='applicationWindow'] ${GLOBAL_SELENIUM_BROWSER_WAIT_TIMEOUT} |
| 285 | |
| 286 | Portal admin User Notifications |
| 287 | [Documentation] Naviage to User notification tab |
| 288 | Click Link xpath=//a[@id='parent-item-User-Notifications'] |
| 289 | Wait Until Element Is Visible xpath=//h1[@class='heading-page'] ${GLOBAL_SELENIUM_BROWSER_WAIT_TIMEOUT} |
| 290 | Click Button xpath=//button[@id='button-openAddNewApp'] |
| 291 | Click Button xpath=(//button[@id='undefined'])[1] |
CHINTAMANI | af44d44 | 2018-04-25 12:38:44 -0400 | [diff] [blame] | 292 | #Click Button xpath=//input[@id='datepicker-start'] |
kishore | 6eebdba | 2017-10-03 11:12:57 -0500 | [diff] [blame] | 293 | |
| 294 | Portal admin Add Application Admin Exiting User |
| 295 | [Documentation] Naviage to Admins tab |
| 296 | Wait Until Element Is Visible xpath=//a[@title='Admins'] ${GLOBAL_SELENIUM_BROWSER_WAIT_TIMEOUT} |
| 297 | Click Link xpath=//a[@title='Admins'] |
| 298 | Wait Until Element Is Visible xpath=//h1[contains(.,'Admins')] ${GLOBAL_SELENIUM_BROWSER_WAIT_TIMEOUT} |
| 299 | Page Should Contain Admins |
| 300 | Click Button xpath=//button[@ng-click='toggleSidebar()'] |
| 301 | Click Button xpath=//button[@ng-click='admins.openAddNewAdminModal()'] |
kishore | bbca0cf | 2017-10-09 16:59:38 -0500 | [diff] [blame] | 302 | Input Text xpath=//input[@id='input-user-search'] ${Existing_User} |
kishore | 6eebdba | 2017-10-03 11:12:57 -0500 | [diff] [blame] | 303 | Click Button xpath=//button[@id='button-search-users'] |
| 304 | Click Element xpath=//span[@id='result-uuid-0'] |
| 305 | Click Button xpath=//button[@id='search-users-button-next'] |
| 306 | Click Button xpath=//input[@value='Select application'] |
kishore | 5ea942b | 2017-10-14 22:19:45 -0500 | [diff] [blame] | 307 | Scroll Element Into View xpath=(//input[@value='Select application']/following::*[contains(text(),'xDemo App' )])[1] |
kishore | 92d70d6 | 2017-10-11 14:51:31 -0500 | [diff] [blame] | 308 | Click Element xpath=(//li[contains(.,'xDemo App' )])[2] |
CHINTAMANI | 68e9836 | 2018-04-10 18:56:38 -0400 | [diff] [blame] | 309 | # Scroll Element Into View xpath=(//input[@value='Select application']/following::*[contains(text(),'Default' )])[1] |
| 310 | # Click Element xpath=(//li[contains(.,'Default' )])[2] |
kishore | 92d70d6 | 2017-10-11 14:51:31 -0500 | [diff] [blame] | 311 | #Select From List xpath=(//input[@value='Select application']/following::*[contains(text(),'xDemo App')])[1] xDemo App |
kishore | 6eebdba | 2017-10-03 11:12:57 -0500 | [diff] [blame] | 312 | Click Button xpath=//button[@id='div-updateAdminAppsRoles'] |
| 313 | Click Element xpath=//button[@id='admin-div-ok-button'] |
| 314 | Click Element xpath=//button[@id='div-confirm-ok-button'] |
| 315 | Get Selenium Implicit Wait |
| 316 | Click Link xpath=//a[@aria-label='Admins'] |
| 317 | Click Element xpath=//input[@id='dropdown1'] |
CHINTAMANI | 68e9836 | 2018-04-10 18:56:38 -0400 | [diff] [blame] | 318 | # Click Element xpath=//li[contains(.,'Default' )] |
kishore | 92d70d6 | 2017-10-11 14:51:31 -0500 | [diff] [blame] | 319 | Click Element xpath=//li[contains(.,'xDemo App' )] |
kishore | 6eebdba | 2017-10-03 11:12:57 -0500 | [diff] [blame] | 320 | Input Text xpath=//input[@id='input-table-search'] ${Existing_User} |
kishore | 5ea942b | 2017-10-14 22:19:45 -0500 | [diff] [blame] | 321 | Table Column Should Contain xpath=//*[@table-data='admins.adminsTableData'] 1 ${Existing_User} |
| 322 | #Element Text Should Be xpath=(//span[contains(.,'portal')])[1] ${Existing_User} |
kishore | 92d70d6 | 2017-10-11 14:51:31 -0500 | [diff] [blame] | 323 | #Element Text Should Be xpath=(//span[contains(.,'demo')])[1] ${Existing_User} |
kishore | 6eebdba | 2017-10-03 11:12:57 -0500 | [diff] [blame] | 324 | |
| 325 | |
| 326 | Portal admin Delete Application Admin Existing User |
| 327 | [Documentation] Naviage to Admins tab |
CHINTAMANI | 68e9836 | 2018-04-10 18:56:38 -0400 | [diff] [blame] | 328 | Wait Until Element Is Visible xpath=//a[@title='Admins'] ${GLOBAL_SELENIUM_BROWSER_WAIT_TIMEOUT} |
| 329 | Click Link xpath=//a[@title='Admins'] |
| 330 | Wait Until Element Is Visible xpath=//h1[contains(.,'Admins')] ${GLOBAL_SELENIUM_BROWSER_WAIT_TIMEOUT} |
| 331 | Page Should Contain Admins |
| 332 | Click Button xpath=//button[@ng-click='toggleSidebar()'] |
| 333 | Input Text xpath=//input[@id='input-table-search'] ${Existing_User} |
kishore | 6eebdba | 2017-10-03 11:12:57 -0500 | [diff] [blame] | 334 | Click Element xpath=(//span[contains(.,'portal')] )[1] |
kishore | 92d70d6 | 2017-10-11 14:51:31 -0500 | [diff] [blame] | 335 | #Click Element xpath=(//span[contains(.,'demo')] )[1] |
| 336 | Click Element xpath=//*[@id='select-app-xDemo-App']/following::i[@id='i-delete-application'] |
CHINTAMANI | 68e9836 | 2018-04-10 18:56:38 -0400 | [diff] [blame] | 337 | # Click Element xpath=//*[@id='select-app-Default']/following::i[@id='i-delete-application'] |
kishore | 6eebdba | 2017-10-03 11:12:57 -0500 | [diff] [blame] | 338 | Click Element xpath=//button[@id='div-confirm-ok-button'] |
| 339 | Click Button xpath=//button[@id='div-updateAdminAppsRoles'] |
| 340 | Click Element xpath=//button[@id='admin-div-ok-button'] |
| 341 | #Is Element Visible xpath=(//span[contains(.,'Portal')] )[2] |
| 342 | #Is Element Visible xpath=(//*[contains(.,'Portal')] )[2] |
| 343 | Element Should Not Contain xpath=//*[@table-data='admins.adminsTableData'] portal |
kishore | 92d70d6 | 2017-10-11 14:51:31 -0500 | [diff] [blame] | 344 | #Element Should Not Contain xpath=//*[@table-data='admins.adminsTableData'] demo |
kishore | 5ea942b | 2017-10-14 22:19:45 -0500 | [diff] [blame] | 345 | Click Image xpath=//img[@alt='Onap Logo'] |
| 346 | Set Selenium Implicit Wait 3000 |
kishore | 6eebdba | 2017-10-03 11:12:57 -0500 | [diff] [blame] | 347 | |
| 348 | |
| 349 | Portal admin Add Application admin User New user |
| 350 | [Documentation] Naviage to Users tab |
| 351 | Click Link xpath=//a[@title='Users'] |
| 352 | Page Should Contain Users |
| 353 | Click Button xpath=//button[@ng-click='toggleSidebar()'] |
kishore | 5ea942b | 2017-10-14 22:19:45 -0500 | [diff] [blame] | 354 | Click Button xpath=//button[@id='users-button-add'] |
kishore | 6eebdba | 2017-10-03 11:12:57 -0500 | [diff] [blame] | 355 | Click Button xpath=//button[@id='Create-New-User-button'] |
| 356 | Input Text xpath=//input[@ng-model='searchUsers.newUser.firstName'] ${App_First_Name} |
| 357 | Input Text xpath=//input[@ng-model='searchUsers.newUser.lastName'] ${App_Last_Name} |
| 358 | Input Text xpath=//input[@ng-model='searchUsers.newUser.emailAddress'] ${App_Email_Address} |
| 359 | Input Text xpath=//input[@ng-model='searchUsers.newUser.loginId'] ${App_LoginID} |
| 360 | Input Text xpath=//input[@ng-model='searchUsers.newUser.loginPwd'] ${App_Loginpwd} |
| 361 | Input Text xpath=//input[@ng-model='searchUsers.newUser.loginPwdCheck'] ${App_LoginPwdCheck} |
| 362 | Click Button xpath=//button[@ng-click='searchUsers.addNewUserFun()'] |
CHINTAMANI | 68e9836 | 2018-04-10 18:56:38 -0400 | [diff] [blame] | 363 | |
| 364 | ${Result}= Get Matching XPath Count xpath=//*[contains(text(),'User with same loginId already exists')] |
| 365 | |
| 366 | #log ${Result} |
| 367 | #${type_result}= Evaluate type(${Result}) |
| 368 | #log ${type_result} |
| 369 | |
| 370 | Run Keyword if '${Result}'== 0 AdminUser does not exist already |
| 371 | ... ELSE Goto Home Image |
| 372 | Set Selenium Implicit Wait 3000 |
| 373 | |
| 374 | Goto Home Image |
| 375 | Click Image xpath=//img[@alt='Onap Logo'] |
| 376 | |
| 377 | AdminUser does not exist already |
kishore | 6eebdba | 2017-10-03 11:12:57 -0500 | [diff] [blame] | 378 | Click Button xpath=//button[@id='next-button'] |
kishore | 92d70d6 | 2017-10-11 14:51:31 -0500 | [diff] [blame] | 379 | #Scroll Element Into View xpath=//div[@id='div-app-name-dropdown-xDemo-App'] |
| 380 | Click Element xpath=//*[@id='div-app-name-dropdown-xDemo-App'] |
| 381 | Click Element xpath=//*[@id='div-app-name-xDemo-App']/following::input[@id='Standard-User-checkbox'] |
kishore | 6eebdba | 2017-10-03 11:12:57 -0500 | [diff] [blame] | 382 | Set Selenium Implicit Wait 3000 |
| 383 | Click Button xpath=//button[@id='new-user-save-button'] |
| 384 | Set Selenium Implicit Wait 3000 |
| 385 | Go To ${PORTAL_HOME_PAGE} |
| 386 | Click Link xpath=//a[@title='Users'] |
| 387 | Click Element xpath=//input[@id='dropdown1'] |
kishore | 92d70d6 | 2017-10-11 14:51:31 -0500 | [diff] [blame] | 388 | Click Element xpath=//li[contains(.,'xDemo App')] |
kishore | bbca0cf | 2017-10-09 16:59:38 -0500 | [diff] [blame] | 389 | Table Column Should Contain xpath=//*[@table-data='users.accountUsers'] 1 ${App_First_Name} |
| 390 | #Input Text xpath=//input[@id='input-table-search'] ${App_First_Name} |
kishore | 5ea942b | 2017-10-14 22:19:45 -0500 | [diff] [blame] | 391 | #Element Text Should Be xpath=(//span[contains(.,'demoapp')] )[1] ${App_First_Name} |
| 392 | Click Image xpath=//img[@alt='Onap Logo'] |
| 393 | Set Selenium Implicit Wait 3000 |
kishore | 6eebdba | 2017-10-03 11:12:57 -0500 | [diff] [blame] | 394 | |
| 395 | |
| 396 | Portal admin Add Standard User New user |
| 397 | [Documentation] Naviage to Users tab |
| 398 | Click Link xpath=//a[@title='Users'] |
| 399 | Page Should Contain Users |
| 400 | Click Button xpath=//button[@ng-click='toggleSidebar()'] |
kishore | 5ea942b | 2017-10-14 22:19:45 -0500 | [diff] [blame] | 401 | Click Button xpath=//button[@id='users-button-add'] |
kishore | 6eebdba | 2017-10-03 11:12:57 -0500 | [diff] [blame] | 402 | Click Button xpath=//button[@id='Create-New-User-button'] |
| 403 | Input Text xpath=//input[@ng-model='searchUsers.newUser.firstName'] ${Sta_First_Name} |
| 404 | Input Text xpath=//input[@ng-model='searchUsers.newUser.lastName'] ${Sta_Last_Name} |
| 405 | Input Text xpath=//input[@ng-model='searchUsers.newUser.emailAddress'] ${Sta_Email_Address} |
| 406 | Input Text xpath=//input[@ng-model='searchUsers.newUser.loginId'] ${Sta_LoginID} |
| 407 | Input Text xpath=//input[@ng-model='searchUsers.newUser.loginPwd'] ${Sta_Loginpwd} |
| 408 | Input Text xpath=//input[@ng-model='searchUsers.newUser.loginPwdCheck'] ${Sta_LoginPwdCheck} |
| 409 | Click Button xpath=//button[@ng-click='searchUsers.addNewUserFun()'] |
CHINTAMANI | 68e9836 | 2018-04-10 18:56:38 -0400 | [diff] [blame] | 410 | |
| 411 | ${Result}= Get Matching XPath Count xpath=//*[contains(text(),'User with same loginId already exists')] |
| 412 | |
| 413 | #log ${Result} |
| 414 | #${type_result}= Evaluate type(${Result}) |
| 415 | #log ${type_result} |
| 416 | |
| 417 | Run Keyword if '${Result}'== 0 StaUser does not exist already |
| 418 | ... ELSE Goto Home Image |
| 419 | Set Selenium Implicit Wait 3000 |
| 420 | |
| 421 | StaUser does not exist already |
kishore | 6eebdba | 2017-10-03 11:12:57 -0500 | [diff] [blame] | 422 | Click Button xpath=//button[@id='next-button'] |
kishore | 92d70d6 | 2017-10-11 14:51:31 -0500 | [diff] [blame] | 423 | #Scroll Element Into View xpath=//div[@id='div-app-name-dropdown-xDemo-App'] |
| 424 | Click Element xpath=//*[@id='div-app-name-dropdown-xDemo-App'] |
| 425 | Click Element xpath=//*[@id='div-app-name-xDemo-App']/following::input[@id='Standard-User-checkbox'] |
kishore | 6eebdba | 2017-10-03 11:12:57 -0500 | [diff] [blame] | 426 | Set Selenium Implicit Wait 3000 |
| 427 | Click Button xpath=//button[@id='new-user-save-button'] |
| 428 | Set Selenium Implicit Wait 3000 |
| 429 | Go To ${PORTAL_HOME_PAGE} |
| 430 | Click Link xpath=//a[@title='Users'] |
| 431 | Click Element xpath=//input[@id='dropdown1'] |
kishore | 92d70d6 | 2017-10-11 14:51:31 -0500 | [diff] [blame] | 432 | Click Element xpath=//li[contains(.,'xDemo App')] |
kishore | bbca0cf | 2017-10-09 16:59:38 -0500 | [diff] [blame] | 433 | Table Column Should Contain xpath=//*[@table-data='users.accountUsers'] 1 ${Sta_First_Name} |
| 434 | #Input Text xpath=//input[@id='input-table-search'] ${Sta_First_Name} |
kishore | 5ea942b | 2017-10-14 22:19:45 -0500 | [diff] [blame] | 435 | #Element Text Should Be xpath=(//span[contains(.,'appdemo')] )[1] ${Sta_First_Name} |
| 436 | Click Image xpath=//img[@alt='Onap Logo'] |
| 437 | Set Selenium Implicit Wait 3000 |
kishore | 6eebdba | 2017-10-03 11:12:57 -0500 | [diff] [blame] | 438 | |
| 439 | |
| 440 | |
| 441 | Portal admin Add Application admin User New user -Test |
| 442 | [Documentation] Naviage to Users tab |
| 443 | Click Link xpath=//a[@title='Users'] |
| 444 | Page Should Contain Users |
| 445 | Click Button xpath=//button[@ng-click='toggleSidebar()'] |
kishore | 5ea942b | 2017-10-14 22:19:45 -0500 | [diff] [blame] | 446 | Click Button xpath=//button[@id='users-button-add'] |
kishore | 6eebdba | 2017-10-03 11:12:57 -0500 | [diff] [blame] | 447 | Click Button xpath=//button[@id='Create-New-User-button'] |
| 448 | Input Text xpath=//input[@ng-model='searchUsers.newUser.firstName'] ${Test_First_Name} |
| 449 | Input Text xpath=//input[@ng-model='searchUsers.newUser.lastName'] ${Test_Last_Name} |
| 450 | Input Text xpath=//input[@ng-model='searchUsers.newUser.emailAddress'] ${Test_Email_Address} |
| 451 | Input Text xpath=//input[@ng-model='searchUsers.newUser.loginId'] ${Test_LoginID} |
| 452 | Input Text xpath=//input[@ng-model='searchUsers.newUser.loginPwd'] ${Test_Loginpwd} |
| 453 | Input Text xpath=//input[@ng-model='searchUsers.newUser.loginPwdCheck'] ${Test_LoginPwdCheck} |
| 454 | Click Button xpath=//button[@ng-click='searchUsers.addNewUserFun()'] |
kishore | 5ea942b | 2017-10-14 22:19:45 -0500 | [diff] [blame] | 455 | Click Button xpath=//button[@id='search-users-button-cancel'] |
| 456 | Click Image xpath=//img[@alt='Onap Logo'] |
| 457 | Set Selenium Implicit Wait 3000 |
| 458 | |
| 459 | |
| 460 | #Click Button xpath=//button[@id='next-button'] |
kishore | 92d70d6 | 2017-10-11 14:51:31 -0500 | [diff] [blame] | 461 | #Scroll Element Into View xpath=//div[@id='div-app-name-dropdown-xDemo-App'] |
kishore | 5ea942b | 2017-10-14 22:19:45 -0500 | [diff] [blame] | 462 | #Click Element xpath=//*[@id='div-app-name-dropdown-xDemo-App'] |
| 463 | #Click Element xpath=//*[@id='div-app-name-xDemo-App']/following::input[@id='Standard-User-checkbox'] |
| 464 | #Set Selenium Implicit Wait 3000 |
| 465 | #Click Button xpath=//button[@id='new-user-save-button'] |
| 466 | #Set Selenium Implicit Wait 3000 |
| 467 | #Go To ${PORTAL_HOME_PAGE} |
| 468 | #Click Link xpath=//a[@title='Users'] |
| 469 | #Click Element xpath=//input[@id='dropdown1'] |
| 470 | #Click Element xpath=//li[contains(.,'xDemo App')] |
| 471 | #Table Column Should Contain xpath=//*[@table-data='users.accountUsers'] 1 ${Test_First_Name} |
kishore | bbca0cf | 2017-10-09 16:59:38 -0500 | [diff] [blame] | 472 | #Input Text xpath=//input[@id='input-table-search'] ${Test_First_Name} |
| 473 | #Element Text Should Be xpath=(//span[contains(.,'appdemo')] )[1] ${Test_First_Name} |
kishore | 6eebdba | 2017-10-03 11:12:57 -0500 | [diff] [blame] | 474 | |
kishore | 6eebdba | 2017-10-03 11:12:57 -0500 | [diff] [blame] | 475 | Portal admin Add Application Admin Exiting User -APPDEMO |
| 476 | [Documentation] Naviage to Admins tab |
| 477 | Wait Until Element Is Visible xpath=//a[@title='Admins'] ${GLOBAL_SELENIUM_BROWSER_WAIT_TIMEOUT} |
| 478 | Click Link xpath=//a[@title='Admins'] |
| 479 | Wait Until Element Is Visible xpath=//h1[contains(.,'Admins')] ${GLOBAL_SELENIUM_BROWSER_WAIT_TIMEOUT} |
| 480 | Page Should Contain Admins |
| 481 | Click Button xpath=//button[@ng-click='toggleSidebar()'] |
| 482 | Click Button xpath=//button[@ng-click='admins.openAddNewAdminModal()'] |
| 483 | Input Text xpath=//input[@id='input-user-search'] ${App_First_Name} |
| 484 | Click Button xpath=//button[@id='button-search-users'] |
| 485 | Click Element xpath=//span[@id='result-uuid-0'] |
| 486 | Click Button xpath=//button[@id='search-users-button-next'] |
| 487 | Click Button xpath=//input[@value='Select application'] |
kishore | 92d70d6 | 2017-10-11 14:51:31 -0500 | [diff] [blame] | 488 | Scroll Element Into View xpath=(//input[@value='Select application']/following::*[contains(text(),'xDemo App' )])[1] |
kishore | 92d70d6 | 2017-10-11 14:51:31 -0500 | [diff] [blame] | 489 | Click Element xpath=(//li[contains(.,'xDemo App' )])[2] |
| 490 | #Select From List xpath=(//input[@value='Select application']/following::*[contains(text(),'xDemo App')])[1] xDemo App |
kishore | 6eebdba | 2017-10-03 11:12:57 -0500 | [diff] [blame] | 491 | Click Button xpath=//button[@id='div-updateAdminAppsRoles'] |
| 492 | Click Element xpath=//button[@id='admin-div-ok-button'] |
| 493 | Click Element xpath=//button[@id='div-confirm-ok-button'] |
| 494 | Get Selenium Implicit Wait |
| 495 | Click Link xpath=//a[@aria-label='Admins'] |
| 496 | Click Element xpath=//input[@id='dropdown1'] |
kishore | 5ea942b | 2017-10-14 22:19:45 -0500 | [diff] [blame] | 497 | Click Element xpath=//li[contains(.,'xDemo App' )] |
kishore | 6eebdba | 2017-10-03 11:12:57 -0500 | [diff] [blame] | 498 | Input Text xpath=//input[@id='input-table-search'] ${App_First_Name} |
kishore | 5ea942b | 2017-10-14 22:19:45 -0500 | [diff] [blame] | 499 | #Element Text Should Be xpath=(//span[contains(.,'appdemo')])[1] ${App_First_Name} |
| 500 | Table Column Should Contain xpath=//*[@table-data='admins.adminsTableData'] 1 ${App_First_Name} |
| 501 | Click Image xpath=//img[@alt='Onap Logo'] |
| 502 | Set Selenium Implicit Wait 3000 |
CHINTAMANI | 68e9836 | 2018-04-10 18:56:38 -0400 | [diff] [blame] | 503 | |
kishore | 6eebdba | 2017-10-03 11:12:57 -0500 | [diff] [blame] | 504 | Portal admin Add Standard User Existing user |
| 505 | [Documentation] Naviage to Users tab |
| 506 | Click Link xpath=//a[@title='Users'] |
| 507 | Page Should Contain Users |
| 508 | Click Button xpath=//button[@ng-click='toggleSidebar()'] |
| 509 | Click Button xpath=//button[@ng-click='users.openAddNewUserModal()'] |
| 510 | Input Text xpath=//input[@id='input-user-search'] ${Existing_User} |
| 511 | Click Button xpath=//button[@id='button-search-users'] |
| 512 | Click Element xpath=//span[@id='result-uuid-0'] |
| 513 | Click Button xpath=//button[@id='next-button'] |
CHINTAMANI | 68e9836 | 2018-04-10 18:56:38 -0400 | [diff] [blame] | 514 | # Click Element xpath=//*[@id='div-app-name-dropdown-Default'] |
| 515 | # Click Element xpath=//*[@id='div-app-name-Default']/following::input[@id='Standard-User-checkbox'] |
| 516 | Click Element xpath=//div[@id='div-app-name-dropdown-xDemo-App'] |
| 517 | Click Element xpath=//div[@id='div-app-name-xDemo-App']/following::input[@id='Standard-User-checkbox'] |
kishore | 6eebdba | 2017-10-03 11:12:57 -0500 | [diff] [blame] | 518 | Set Selenium Implicit Wait 3000 |
| 519 | Click Button xpath=//button[@id='new-user-save-button'] |
| 520 | Set Selenium Implicit Wait 3000 |
| 521 | #Set Browser Implicit Wait ${GLOBAL_SELENIUM_BROWSER_IMPLICIT_WAIT} |
kishore | 92d70d6 | 2017-10-11 14:51:31 -0500 | [diff] [blame] | 522 | #Select From List xpath=//input[@value='Select application'] xDemo App |
kishore | 6eebdba | 2017-10-03 11:12:57 -0500 | [diff] [blame] | 523 | #Click Link xpath=//a[@title='Users'] |
| 524 | #Page Should Contain Users |
| 525 | #Focus xpath=//input[@name='dropdown1'] |
kishore | 6eebdba | 2017-10-03 11:12:57 -0500 | [diff] [blame] | 526 | Go To ${PORTAL_HOME_PAGE} |
| 527 | Click Link xpath=//a[@title='Users'] |
| 528 | Click Element xpath=//input[@id='dropdown1'] |
CHINTAMANI | 68e9836 | 2018-04-10 18:56:38 -0400 | [diff] [blame] | 529 | # Click Element xpath=//li[contains(.,'Default')] |
| 530 | Click Element xpath=//li[contains(.,'XDemo App')] |
kishore | 6eebdba | 2017-10-03 11:12:57 -0500 | [diff] [blame] | 531 | Input Text xpath=//input[@id='input-table-search'] ${Existing_User} |
CHINTAMANI | 68e9836 | 2018-04-10 18:56:38 -0400 | [diff] [blame] | 532 | Element Text Should Be xpath=(.//*[@id='rowheader_t1_0'])[2] Standard User |
| 533 | Set Selenium Implicit Wait 3000 |
| 534 | |
CHINTAMANI | af44d44 | 2018-04-25 12:38:44 -0400 | [diff] [blame] | 535 | Portal admin Edit Standard User Existing user |
kishore | 6eebdba | 2017-10-03 11:12:57 -0500 | [diff] [blame] | 536 | [Documentation] Naviage to Users tab |
CHINTAMANI | af44d44 | 2018-04-25 12:38:44 -0400 | [diff] [blame] | 537 | Click Link xpath=//a[@title='Users'] |
| 538 | Click Element xpath=//input[@id='dropdown1'] |
| 539 | # Click Element xpath=//li[contains(.,'Default')] |
| 540 | # Set Selenium Implicit Wait 3000 |
| 541 | Click Element xpath=//li[contains(.,'xDemo App')] |
| 542 | # Set Selenium Implicit Wait 3000 |
| 543 | Input Text xpath=//input[@id='input-table-search'] ${Existing_User} |
| 544 | Element Text Should Be xpath=(.//*[@id='rowheader_t1_0'])[2] Standard User |
kishore | 6eebdba | 2017-10-03 11:12:57 -0500 | [diff] [blame] | 545 | Click Element xpath=(.//*[@id='rowheader_t1_0'])[2] |
CHINTAMANI | af44d44 | 2018-04-25 12:38:44 -0400 | [diff] [blame] | 546 | # Click Element xpath=//*[@id='div-app-name-dropdown-Default'] |
| 547 | # Click Element xpath=//*[@id='div-app-name-Default']/following::input[@id='Standard-User-checkbox'] |
| 548 | # Click Element xpath=//*[@id='div-app-name-Default']/following::input[@id='Portal-Notification-Admin-checkbox'] |
| 549 | Click Element xpath=//*[@id='app-select-Standard User1'] |
| 550 | Click Element xpath=//*[@id='app-select-Standard User1']/following::input[@id='Standard-User-checkbox'] |
| 551 | Set Selenium Implicit Wait 3000 |
| 552 | Click Button xpath=//button[@id='new-user-save-button'] |
| 553 | Set Selenium Implicit Wait 3000 |
| 554 | |
| 555 | Page Should Contain Users |
| 556 | Click Button xpath=//button[@ng-click='toggleSidebar()'] |
| 557 | Click Button xpath=//button[@ng-click='users.openAddNewUserModal()'] |
| 558 | Input Text xpath=//input[@id='input-user-search'] ${Existing_User} |
| 559 | Click Button xpath=//button[@id='button-search-users'] |
| 560 | Click Element xpath=//span[@id='result-uuid-0'] |
| 561 | Click Button xpath=//button[@id='next-button'] |
| 562 | Click Element xpath=//div[@id='app-select-Select roles1'] |
| 563 | Click Element xpath=//div[@id='app-select-Select roles1']/following::input[@id='System-Administrator-checkbox'] |
| 564 | Set Selenium Implicit Wait 3000 |
| 565 | # Click Element xpath=//*[@id='app-select-Standard User1'] |
| 566 | # Click Element xpath=//*[@id='app-select-Standard User1']/following::input[@id='System-Administrator-checkbox'] |
| 567 | # Click Element xpath=//*[@id='div-app-name-dropdown-SDC'] |
| 568 | # Click Element xpath=//*[@id='div-app-name-SDC']/following::input[@id='Standard-User-checkbox'] |
| 569 | # Click Element xpath=//*[@id='div-app-name-SDC']/following::input[@id='Portal-Notification-Admin-checkbox'] |
kishore | 6eebdba | 2017-10-03 11:12:57 -0500 | [diff] [blame] | 570 | Set Selenium Implicit Wait 3000 |
| 571 | Click Button xpath=//button[@id='new-user-save-button'] |
| 572 | Set Selenium Implicit Wait 3000 |
| 573 | Page Should Contain Users |
| 574 | #Click Button xpath=//input[@id='dropdown1'] |
kishore | 92d70d6 | 2017-10-11 14:51:31 -0500 | [diff] [blame] | 575 | #Click Element xpath=//li[contains(.,'xDemo App')] |
kishore | 6eebdba | 2017-10-03 11:12:57 -0500 | [diff] [blame] | 576 | Input Text xpath=//input[@id='input-table-search'] ${Existing_User} |
CHINTAMANI | af44d44 | 2018-04-25 12:38:44 -0400 | [diff] [blame] | 577 | # Element Text Should Be xpath=(.//*[@id='rowheader_t1_0'])[2] Portal Notification Admin |
kishore | 6eebdba | 2017-10-03 11:12:57 -0500 | [diff] [blame] | 578 | Element Text Should Be xpath=(.//*[@id='rowheader_t1_0'])[2] System Administrator |
CHINTAMANI | 68e9836 | 2018-04-10 18:56:38 -0400 | [diff] [blame] | 579 | Set Selenium Implicit Wait 3000 |
kishore | 6eebdba | 2017-10-03 11:12:57 -0500 | [diff] [blame] | 580 | |
| 581 | Portal admin Delete Standard User Existing user |
| 582 | [Documentation] Naviage to Users tab |
| 583 | Click Element xpath=(.//*[@id='rowheader_t1_0'])[2] |
CHINTAMANI | 68e9836 | 2018-04-10 18:56:38 -0400 | [diff] [blame] | 584 | # Scroll Element Into View xpath=//*[@id='div-app-name-Default']/following::*[@id='app-item-delete'][1] |
| 585 | # Click Element xpath=//*[@id='div-app-name-Default']/following::*[@id='app-item-delete'][1] |
kishore | 92d70d6 | 2017-10-11 14:51:31 -0500 | [diff] [blame] | 586 | Scroll Element Into View xpath=//*[@id='div-app-name-xDemo-App']/following::*[@id='app-item-delete'][1] |
| 587 | Click Element xpath=//*[@id='div-app-name-xDemo-App']/following::*[@id='app-item-delete'][1] |
CHINTAMANI | 68e9836 | 2018-04-10 18:56:38 -0400 | [diff] [blame] | 588 | # Scroll Element Into View xpath=//*[@id='div-app-name-SDC']/following::*[@id='app-item-delete'][1] |
| 589 | # Click Element xpath=//*[@id='div-app-name-SDC']/following::*[@id='app-item-delete'][1] |
kishore | 6eebdba | 2017-10-03 11:12:57 -0500 | [diff] [blame] | 590 | Click Element xpath=//button[@id='div-confirm-ok-button'] |
| 591 | Click Button xpath=//button[@id='new-user-save-button'] |
| 592 | #Input Text xpath=//input[@id='input-table-search'] ${Existing_User} |
CHINTAMANI | 68e9836 | 2018-04-10 18:56:38 -0400 | [diff] [blame] | 593 | #Is Element Visible xpath=(//*[contains(.,'Portal')] )[2] |
| 594 | Element Should Not Contain xpath=//*[@table-data='users.accountUsers'] Portal |
| 595 | #Element Should Not Contain xpath=//*[@table-data='users.accountUsers'] demo |
| 596 | Set Selenium Implicit Wait 3000 |
kishore | 6eebdba | 2017-10-03 11:12:57 -0500 | [diff] [blame] | 597 | |
| 598 | Functional Top Menu Get Access |
| 599 | [Documentation] Naviage to Support tab |
CHINTAMANI | af44d44 | 2018-04-25 12:38:44 -0400 | [diff] [blame] | 600 | Go To ${PORTAL_HOME_URL} |
kishore | 6eebdba | 2017-10-03 11:12:57 -0500 | [diff] [blame] | 601 | Click Link xpath=//a[contains(.,'Support')] |
| 602 | Mouse Over xpath=//*[contains(text(),'Get Access')] |
| 603 | Click Link xpath=//a[contains(.,'Get Access')] |
| 604 | Element Text Should Be xpath=//h1[contains(.,'Get Access')] Get Access |
CHINTAMANI | 68e9836 | 2018-04-10 18:56:38 -0400 | [diff] [blame] | 605 | Set Selenium Implicit Wait 3000 |
kishore | 6eebdba | 2017-10-03 11:12:57 -0500 | [diff] [blame] | 606 | |
| 607 | Functional Top Menu Contact Us |
| 608 | [Documentation] Naviage to Support tab |
| 609 | Click Link xpath=//a[contains(.,'Support')] |
| 610 | Mouse Over xpath=//*[contains(text(),'Contact Us')] |
| 611 | Click Link xpath=//a[contains(.,'Contact Us')] |
| 612 | Element Text Should Be xpath=//h1[contains(.,'Contact Us')] Contact Us |
| 613 | Click Image xpath=//img[@alt='Onap Logo'] |
CHINTAMANI | 68e9836 | 2018-04-10 18:56:38 -0400 | [diff] [blame] | 614 | Set Selenium Implicit Wait 3000 |
kishore | 6eebdba | 2017-10-03 11:12:57 -0500 | [diff] [blame] | 615 | |
| 616 | Portal admin Edit Functional menu |
| 617 | [Documentation] Naviage to Edit Functional menu tab |
| 618 | Click Link xpath=//a[@title='Edit Functional Menu'] |
| 619 | Click Link xpath=.//*[@id='Manage']/div/a |
| 620 | Click Link xpath=.//*[@id='Design']/div/a |
| 621 | Click Link xpath=.//*[@id='Product_Design']/div/a |
| 622 | Open Context Menu xpath=//*[@id='Product_Design']/div/span |
| 623 | Click Link xpath=//a[@href='#add'] |
| 624 | Input Text xpath=//input[@id='input-title'] ONAP Test |
| 625 | #Input Text xpath=//input[@id='input-url'] http://google.com |
| 626 | Click Element xpath=//input[@id='select-app'] |
kishore | 92d70d6 | 2017-10-11 14:51:31 -0500 | [diff] [blame] | 627 | Scroll Element Into View xpath=//li[contains(.,'xDemo App')] |
| 628 | Click Element xpath=//li[contains(.,'xDemo App')] |
kishore | 6eebdba | 2017-10-03 11:12:57 -0500 | [diff] [blame] | 629 | Input Text xpath=//input[@id='input-url'] http://google.com |
| 630 | Click Button xpath=//button[@id='button-save-continue'] |
| 631 | #Click Button xpath=//div[@title='Select Roles'] |
| 632 | Click Element xpath=//*[@id='app-select-Select Roles'] |
| 633 | Click Element xpath=//input[@id='Standard-User-checkbox'] |
| 634 | Click Element xpath=//button[@id='button-save-add'] |
| 635 | Click Image xpath=//img[@alt='Onap Logo'] |
| 636 | Set Selenium Implicit Wait 3000 |
| 637 | Click Link xpath=//a[contains(.,'Manage')] |
| 638 | Mouse Over xpath=//*[contains(text(),'Design')] |
| 639 | Set Selenium Implicit Wait 3000 |
| 640 | Element Text Should Be xpath=//a[contains(.,'ONAP Test')] ONAP Test |
| 641 | Set Selenium Implicit Wait 3000 |
kishore | bbca0cf | 2017-10-09 16:59:38 -0500 | [diff] [blame] | 642 | Click Image xpath=//img[@alt='Onap Logo'] |
kishore | 6eebdba | 2017-10-03 11:12:57 -0500 | [diff] [blame] | 643 | Click Link xpath=//a[@title='Edit Functional Menu'] |
| 644 | Click Link xpath=.//*[@id='Manage']/div/a |
| 645 | Click Link xpath=.//*[@id='Design']/div/a |
| 646 | Click Link xpath=.//*[@id='Product_Design']/div/a |
| 647 | Open Context Menu xpath=//*[@id='ONAP_Test'] |
| 648 | Click Link xpath=//a[@href='#delete'] |
| 649 | Set Selenium Implicit Wait 3000 |
| 650 | Click Element xpath=//button[@id='div-confirm-ok-button'] |
| 651 | Click Image xpath=//img[@alt='Onap Logo'] |
| 652 | Set Selenium Implicit Wait 3000 |
| 653 | Click Link xpath=//a[contains(.,'Manage')] |
| 654 | Mouse Over xpath=//*[contains(text(),'Design')] |
| 655 | Set Selenium Implicit Wait 3000 |
| 656 | Element Should Not Contain xpath=(.//*[contains(.,'Design')]/following::ul[1])[1] ONAP Test |
CHINTAMANI | 68e9836 | 2018-04-10 18:56:38 -0400 | [diff] [blame] | 657 | Set Selenium Implicit Wait 3000 |
CHINTAMANI | af44d44 | 2018-04-25 12:38:44 -0400 | [diff] [blame] | 658 | Click Image xpath=//img[@alt='Onap Logo'] |
| 659 | Set Selenium Implicit Wait 3000 |
kishore | 6eebdba | 2017-10-03 11:12:57 -0500 | [diff] [blame] | 660 | |
| 661 | Portal admin Microservice Onboarding |
| 662 | [Documentation] Naviage to Edit Functional menu tab |
| 663 | Click Link xpath=//a[@title='Microservice Onboarding'] |
| 664 | Click Button xpath=//button[@id='microservice-onboarding-button-add'] |
| 665 | Input Text xpath=//input[@name='name'] Test Microservice |
| 666 | Input Text xpath=//*[@name='desc'] Test |
| 667 | Click Element xpath=//input[@id='microservice-details-input-app'] |
kishore | 92d70d6 | 2017-10-11 14:51:31 -0500 | [diff] [blame] | 668 | Scroll Element Into View xpath=//li[contains(.,'xDemo App')] |
| 669 | Click Element xpath=//li[contains(.,'xDemo App')] |
kishore | 6eebdba | 2017-10-03 11:12:57 -0500 | [diff] [blame] | 670 | Click Element xpath=//*[@name='desc'] |
| 671 | Input Text xpath=//input[@name='url'] ${PORTAL_MICRO_ENDPOINT} |
| 672 | Click Element xpath=//input[@id='microservice-details-input-security-type'] |
| 673 | Scroll Element Into View xpath=//li[contains(.,'Basic Authentication')] |
| 674 | Click Element xpath=//li[contains(.,'Basic Authentication')] |
| 675 | Input Text xpath=//input[@name='username'] ${GLOBAL_PORTAL_ADMIN_USER} |
| 676 | Input Text xpath=//input[@name='password'] ${GLOBAL_PORTAL_ADMIN_PWD} |
| 677 | Click Button xpath=//button[@id='microservice-details-save-button'] |
| 678 | Table Column Should Contain xpath=//*[@table-data='serviceList'] 1 Test Microservice |
| 679 | #Element Text Should Be xpath=//*[@table-data='serviceList'] Test Microservice |
CHINTAMANI | 68e9836 | 2018-04-10 18:56:38 -0400 | [diff] [blame] | 680 | Set Selenium Implicit Wait 3000 |
| 681 | |
| 682 | Portal admin Microservice Delete |
| 683 | [Documentation] Naviage to Edit Functional menu tab |
| 684 | Click Link xpath=//a[@title='Microservice Onboarding'] |
| 685 | Click Button xpath=//button[@id='microservice-onboarding-button-add'] |
| 686 | Input Text xpath=//input[@name='name'] TestMS |
| 687 | Input Text xpath=//*[@name='desc'] TestMS |
| 688 | Click Element xpath=//input[@id='microservice-details-input-app'] |
| 689 | Scroll Element Into View xpath=//li[contains(.,'xDemo App')] |
| 690 | Click Element xpath=//li[contains(.,'xDemo App')] |
| 691 | Click Element xpath=//*[@name='desc'] |
| 692 | Input Text xpath=//input[@name='url'] ${PORTAL_MICRO_ENDPOINT} |
| 693 | Click Element xpath=//input[@id='microservice-details-input-security-type'] |
| 694 | Scroll Element Into View xpath=//li[contains(.,'Basic Authentication')] |
| 695 | Click Element xpath=//li[contains(.,'Basic Authentication')] |
| 696 | Input Text xpath=//input[@name='username'] ${GLOBAL_PORTAL_ADMIN_USER} |
| 697 | Input Text xpath=//input[@name='password'] ${GLOBAL_PORTAL_ADMIN_PWD} |
| 698 | Click Button xpath=//button[@id='microservice-details-save-button'] |
CHINTAMANI | af44d44 | 2018-04-25 12:38:44 -0400 | [diff] [blame] | 699 | Execute Javascript window.scrollTo(0,document.body.scrollHeight); |
CHINTAMANI | 68e9836 | 2018-04-10 18:56:38 -0400 | [diff] [blame] | 700 | Click Element xpath=(.//*[contains(text(),'TestMS')]/following::*[@ng-click='microserviceOnboarding.deleteService(rowData)'])[1] |
| 701 | Click Button xpath=//button[@id="div-confirm-ok-button"] |
| 702 | Set Selenium Implicit Wait 3000 |
| 703 | |
kishore | 6eebdba | 2017-10-03 11:12:57 -0500 | [diff] [blame] | 704 | Portal Admin Create Widget for All users |
CHINTAMANI | 68e9836 | 2018-04-10 18:56:38 -0400 | [diff] [blame] | 705 | [Documentation] Navigate to Create Widget menu tab |
kishore | 5f57af1 | 2017-11-27 13:57:35 -0600 | [diff] [blame] | 706 | ${WidgetAttachment}= Catenate ${PORTAL_ASSETS_DIRECTORY}//news_widget.zip |
CHINTAMANI | af44d44 | 2018-04-25 12:38:44 -0400 | [diff] [blame] | 707 | Wait until page contains Element xpath=//a[@title='Widget Onboarding'] ${GLOBAL_SELENIUM_BROWSER_WAIT_TIMEOUT} |
kishore | 6eebdba | 2017-10-03 11:12:57 -0500 | [diff] [blame] | 708 | Click Link xpath=//a[@title='Widget Onboarding'] |
| 709 | Click Button xpath=//button[@ng-click='toggleSidebar()'] |
| 710 | Click Button xpath=//button[@id='widget-onboarding-button-add'] |
kishore | 92d70d6 | 2017-10-11 14:51:31 -0500 | [diff] [blame] | 711 | Input Text xpath=//*[@name='name'] ONAP-xDemo |
| 712 | Input Text xpath=//*[@name='desc'] ONAP xDemo |
kishore | 6eebdba | 2017-10-03 11:12:57 -0500 | [diff] [blame] | 713 | Click Element xpath=//*[@id='widgets-details-input-endpoint-url'] |
CHINTAMANI | af44d44 | 2018-04-25 12:38:44 -0400 | [diff] [blame] | 714 | Scroll Element Into View xpath=//li[contains(.,'News Microservice')] |
| 715 | Click Element xpath=//li[contains(.,'News Microservice')] |
kishore | 6eebdba | 2017-10-03 11:12:57 -0500 | [diff] [blame] | 716 | Click Element xpath=//*[contains(text(),'Allow all user access')]/preceding::input[@ng-model='widgetOnboardingDetails.widget.allUser'][1] |
| 717 | Choose File xpath=//input[@id='widget-onboarding-details-upload-file'] ${WidgetAttachment} |
| 718 | Click Button xpath=//button[@id='widgets-details-save-button'] |
CHINTAMANI | af44d44 | 2018-04-25 12:38:44 -0400 | [diff] [blame] | 719 | Wait Until Page Contains ONAP-xDemo ${GLOBAL_SELENIUM_BROWSER_WAIT_TIMEOUT} |
kishore | 92d70d6 | 2017-10-11 14:51:31 -0500 | [diff] [blame] | 720 | Page Should Contain ONAP-xDemo |
CHINTAMANI | af44d44 | 2018-04-25 12:38:44 -0400 | [diff] [blame] | 721 | Set Selenium Implicit Wait 3000 |
kishore | 6eebdba | 2017-10-03 11:12:57 -0500 | [diff] [blame] | 722 | GO TO ${PORTAL_HOME_PAGE} |
| 723 | |
| 724 | |
| 725 | Portal Admin Delete Widget for All users |
| 726 | [Documentation] Naviage to delete Widget menu tab |
kishore | 92d70d6 | 2017-10-11 14:51:31 -0500 | [diff] [blame] | 727 | #Wait Until Page Contains ONAP-xDemo ${GLOBAL_SELENIUM_BROWSER_WAIT_TIMEOUT} |
| 728 | #Page Should Contain ONAP-xDemo |
kishore | 6eebdba | 2017-10-03 11:12:57 -0500 | [diff] [blame] | 729 | #Click Image xpath=//img[@alt='Onap Logo'] |
| 730 | Click Link xpath=//a[@title='Widget Onboarding'] |
| 731 | Click Element xpath=//input[@id='dropdown1'] |
kishore | 92d70d6 | 2017-10-11 14:51:31 -0500 | [diff] [blame] | 732 | Click Element xpath=//li[contains(.,'xDemo App')] |
| 733 | #Wait Until Page Contains xpath=(.//*[contains(text(),'ONAP-xDemo')]/followi |
| 734 | #Wait Until Page Contains xpath=(.//*[contains(text(),'ONAP-xDemo')]/following::*[@ng-click='widgetOnboarding.deleteWidget(rowData)'])[1] ${GLOBAL_SELENIUM_BROWSER_WAIT_TIMEOUT} |
kishore | bbca0cf | 2017-10-09 16:59:38 -0500 | [diff] [blame] | 735 | Click Button xpath=//button[@ng-click='toggleSidebar()'] |
kishore | 92d70d6 | 2017-10-11 14:51:31 -0500 | [diff] [blame] | 736 | Click Element xpath=(.//*[contains(text(),'ONAP-xDemo')]/following::*[@ng-click='widgetOnboarding.deleteWidget(rowData)'])[1] |
kishore | 6eebdba | 2017-10-03 11:12:57 -0500 | [diff] [blame] | 737 | Click Element xpath=//button[@id='div-confirm-ok-button'] |
| 738 | Set Selenium Implicit Wait 3000 |
kishore | 92d70d6 | 2017-10-11 14:51:31 -0500 | [diff] [blame] | 739 | Element Should Not Contain xpath=//*[@table-data='portalAdmin.portalAdminsTableData'] ONAP-xDemo |
kishore | 6eebdba | 2017-10-03 11:12:57 -0500 | [diff] [blame] | 740 | #Is Element Visible xpath=//*[@table-data='portalAdmin.portalAdminsTableData'] |
kishore | 92d70d6 | 2017-10-11 14:51:31 -0500 | [diff] [blame] | 741 | #Table Column Should Contain .//*[@table-data='portalAdmin.portalAdminsTableData'] 0 ONAP-xDemo |
kishore | 6eebdba | 2017-10-03 11:12:57 -0500 | [diff] [blame] | 742 | #Set Selenium Implicit Wait 3000 |
| 743 | |
kishore | 6eebdba | 2017-10-03 11:12:57 -0500 | [diff] [blame] | 744 | Portal Admin Create Widget for Application Roles |
| 745 | [Documentation] Naviage to Create Widget menu tab |
kishore | 5f57af1 | 2017-11-27 13:57:35 -0600 | [diff] [blame] | 746 | ${WidgetAttachment}= Catenate ${PORTAL_ASSETS_DIRECTORY}//news_widget.zip |
kishore | 6eebdba | 2017-10-03 11:12:57 -0500 | [diff] [blame] | 747 | Click Link xpath=//a[@title='Widget Onboarding'] |
| 748 | Click Button xpath=//button[@ng-click='toggleSidebar()'] |
| 749 | Click Button xpath=//button[@id='widget-onboarding-button-add'] |
kishore | 92d70d6 | 2017-10-11 14:51:31 -0500 | [diff] [blame] | 750 | Input Text xpath=//*[@name='name'] ONAP-xDemo |
| 751 | Input Text xpath=//*[@name='desc'] ONAP xDemo |
kishore | 6eebdba | 2017-10-03 11:12:57 -0500 | [diff] [blame] | 752 | Click Element xpath=//*[@id='widgets-details-input-endpoint-url'] |
CHINTAMANI | af44d44 | 2018-04-25 12:38:44 -0400 | [diff] [blame] | 753 | Scroll Element Into View xpath=//li[contains(.,'News Microservice')] |
| 754 | Click Element xpath=//li[contains(.,'News Microservice')] |
kishore | 6eebdba | 2017-10-03 11:12:57 -0500 | [diff] [blame] | 755 | Click element xpath=//*[@id="app-select-Select Applications"] |
kishore | 92d70d6 | 2017-10-11 14:51:31 -0500 | [diff] [blame] | 756 | click element xpath=//*[@id="xDemo-App-checkbox"] |
kishore | 6eebdba | 2017-10-03 11:12:57 -0500 | [diff] [blame] | 757 | Click element xpath=//*[@name='desc'] |
CHINTAMANI | af44d44 | 2018-04-25 12:38:44 -0400 | [diff] [blame] | 758 | click element xpath=//*[@id="app-select-Select Roles0"] |
kishore | 6eebdba | 2017-10-03 11:12:57 -0500 | [diff] [blame] | 759 | click element xpath=//*[@id="Standard-User-checkbox"] |
| 760 | Click element xpath=//*[@name='desc'] |
| 761 | Scroll Element Into View xpath=//input[@id='widget-onboarding-details-upload-file'] |
| 762 | Choose File xpath=//input[@id='widget-onboarding-details-upload-file'] ${WidgetAttachment} |
| 763 | Click Button xpath=//button[@id='widgets-details-save-button'] |
| 764 | Click Image xpath=//img[@alt='Onap Logo'] |
| 765 | Set Selenium Implicit Wait 3000 |
kishore | 92d70d6 | 2017-10-11 14:51:31 -0500 | [diff] [blame] | 766 | #Wait Until Page Contains ONAP-xDemo ${GLOBAL_SELENIUM_BROWSER_WAIT_TIMEOUT} |
kishore | 6eebdba | 2017-10-03 11:12:57 -0500 | [diff] [blame] | 767 | Click Link xpath=//a[@title='Widget Onboarding'] |
| 768 | Click Element xpath=//input[@id='dropdown1'] |
kishore | 92d70d6 | 2017-10-11 14:51:31 -0500 | [diff] [blame] | 769 | Click Element xpath=//li[contains(.,'xDemo App')] |
| 770 | Page Should Contain ONAP-xDemo |
kishore | 6eebdba | 2017-10-03 11:12:57 -0500 | [diff] [blame] | 771 | Set Selenium Implicit Wait 3000 |
| 772 | GO TO ${PORTAL_HOME_PAGE} |
CHINTAMANI | 68e9836 | 2018-04-10 18:56:38 -0400 | [diff] [blame] | 773 | |
kishore | 92d70d6 | 2017-10-11 14:51:31 -0500 | [diff] [blame] | 774 | Portal Admin Delete Widget for Application Roles |
| 775 | #Wait Until Page Contains ONAP-xDemo ${GLOBAL_SELENIUM_BROWSER_WAIT_TIMEOUT} |
| 776 | #Page Should Contain ONAP-xDemo |
kishore | 6eebdba | 2017-10-03 11:12:57 -0500 | [diff] [blame] | 777 | #Click Image xpath=//img[@alt='Onap Logo'] |
| 778 | Click Link xpath=//a[@title='Widget Onboarding'] |
| 779 | Click Element xpath=//input[@id='dropdown1'] |
kishore | 92d70d6 | 2017-10-11 14:51:31 -0500 | [diff] [blame] | 780 | Click Element xpath=//li[contains(.,'xDemo App')] |
| 781 | #Wait Until Page Contains xpath=(.//*[contains(text(),'ONAP-xDemo')]/followi |
| 782 | #Wait Until Page Contains xpath=(.//*[contains(text(),'ONAP-xDemo')]/following::*[@ng-click='widgetOnboarding.deleteWidget(rowData)'])[1] ${GLOBAL_SELENIUM_BROWSER_WAIT_TIMEOUT} |
kishore | bbca0cf | 2017-10-09 16:59:38 -0500 | [diff] [blame] | 783 | Click Button xpath=//button[@ng-click='toggleSidebar()'] |
kishore | 92d70d6 | 2017-10-11 14:51:31 -0500 | [diff] [blame] | 784 | Scroll Element Into View xpath=//*[contains(text(),'ONAP-xDemo')]/following::td[3]/div |
| 785 | Click Element xpath=//*[contains(text(),'ONAP-xDemo')]/following::td[3]/div |
kishore | 6eebdba | 2017-10-03 11:12:57 -0500 | [diff] [blame] | 786 | Click Element xpath=//button[@id='div-confirm-ok-button'] |
| 787 | Set Selenium Implicit Wait 3000 |
kishore | 92d70d6 | 2017-10-11 14:51:31 -0500 | [diff] [blame] | 788 | Element Should Not Contain xpath=//*[@table-data='portalAdmin.portalAdminsTableData'] ONAP-xDemo |
kishore | 6eebdba | 2017-10-03 11:12:57 -0500 | [diff] [blame] | 789 | #Is Element Visible xpath=//*[@table-data='portalAdmin.portalAdminsTableData'] |
kishore | 92d70d6 | 2017-10-11 14:51:31 -0500 | [diff] [blame] | 790 | #Table Column Should Contain .//*[@table-data='portalAdmin.portalAdminsTableData'] 0 ONAP-xDemo |
CHINTAMANI | 68e9836 | 2018-04-10 18:56:38 -0400 | [diff] [blame] | 791 | Set Selenium Implicit Wait 3000 |
kishore | 6eebdba | 2017-10-03 11:12:57 -0500 | [diff] [blame] | 792 | |
| 793 | |
| 794 | |
| 795 | Portal Admin Edit Widget |
| 796 | [Documentation] Naviage to Home tab |
| 797 | #Mouse Over xpath=(//h3[contains(text(),'News')]/following::span[1])[1] |
| 798 | Click Element xpath=(//h3[contains(text(),'News')]/following::span[1])[1] |
| 799 | Set Browser Implicit Wait 8000 |
| 800 | #Wait Until Element Is Visible xpath=(//h3[contains(text(),'News')]/following::span[1]/following::a[contains(text(),'Edit')])[1] 60 |
| 801 | Mouse Over xpath=(//h3[contains(text(),'News')]/following::span[1]/following::a[contains(text(),'Edit')])[1] |
| 802 | Click Link xpath=(//h3[contains(text(),'News')]/following::span[1]/following::a[contains(text(),'Edit')])[1] |
| 803 | Input Text xpath=//input[@name='title'] ONAP_VID |
| 804 | Input Text xpath=//input[@name='url'] http://about.att.com/news/international.html |
| 805 | Input Text xpath=//input[@id='widget-input-add-order'] 5 |
| 806 | Click Link xpath=//a[contains(.,'Add New')] |
| 807 | Click Element xpath=//div[@id='close-button'] |
| 808 | Element Should Contain xpath=//*[@table-data='ignoredTableData'] ONAP_VID |
| 809 | Click Element xpath=.//div[contains(text(),'ONAP_VID')]/following::*[contains(text(),'5')][1]/following::div[@ng-click='remove($index);'][1] |
| 810 | Click Element xpath=//div[@id='confirmation-button-next'] |
| 811 | Element Should Not Contain xpath=//*[@table-data='ignoredTableData'] ONAP_VID |
| 812 | Click Link xpath=//a[@id='close-button'] |
CHINTAMANI | 68e9836 | 2018-04-10 18:56:38 -0400 | [diff] [blame] | 813 | Set Selenium Implicit Wait 3000 |
kishore | 6eebdba | 2017-10-03 11:12:57 -0500 | [diff] [blame] | 814 | |
| 815 | Portal Admin Broadcast Notifications |
| 816 | [Documentation] Portal Test Admin Broadcast Notifications |
CHINTAMANI | 68e9836 | 2018-04-10 18:56:38 -0400 | [diff] [blame] | 817 | ${CurrentDay}= Get Current Date increment=24:00:00 result_format=%m/%d/%Y |
| 818 | ${NextDay}= Get Current Date increment=48:00:00 result_format=%m/%d/%Y |
| 819 | ${CurrentDate}= Get Current Date increment=24:00:00 result_format=%m%d%y%H%M |
kishore | 6eebdba | 2017-10-03 11:12:57 -0500 | [diff] [blame] | 820 | ${AdminBroadCastMsg}= catenate ONAP VID Broadcast Automation${CurrentDate} |
CHINTAMANI | af44d44 | 2018-04-25 12:38:44 -0400 | [diff] [blame] | 821 | Go To ${PORTAL_HOME_URL} |
| 822 | Click Image xpath=//img[@alt='Onap Logo'] |
kishore | 6eebdba | 2017-10-03 11:12:57 -0500 | [diff] [blame] | 823 | Set Selenium Implicit Wait 3000 |
| 824 | Click Link xpath=//*[@id="parent-item-User-Notifications"] |
| 825 | Wait until Element is visible xpath=//*[@id="button-openAddNewApp"] timeout=10 |
| 826 | Click button xpath=//*[@id="button-openAddNewApp"] |
| 827 | Input Text xpath=//input[@id='datepicker-start'] ${CurrentDay} |
| 828 | Input Text xpath=//input[@id='datepicker-end'] ${NextDay} |
| 829 | Input Text xpath=//*[@id="add-notification-input-title"] ONAP VID Broadcast Automation |
| 830 | Input Text xpath=//*[@id="user-notif-input-message"] ${AdminBroadCastMsg} |
| 831 | click element xpath=//*[@id="button-notification-save"] |
| 832 | Wait until Element is visible xpath=//*[@id="button-openAddNewApp"] timeout=10 |
| 833 | click element xpath=//*[@id="megamenu-notification-button"] |
| 834 | click element xpath=//*[@id="notification-history-link"] |
CHINTAMANI | af44d44 | 2018-04-25 12:38:44 -0400 | [diff] [blame] | 835 | # Notification bug, Uncomment the code when PORTAL-232 is fixed |
| 836 | # Wait until Element is visible xpath=//*[@id="notification-history-table"] timeout=10 |
| 837 | # Table Column Should Contain xpath=//*[@id="notification-history-table"] 2 ${AdminBroadCastMsg} |
CHINTAMANI | 68e9836 | 2018-04-10 18:56:38 -0400 | [diff] [blame] | 838 | Set Selenium Implicit Wait 3000 |
kishore | 6eebdba | 2017-10-03 11:12:57 -0500 | [diff] [blame] | 839 | log ${AdminBroadCastMsg} |
| 840 | [Return] ${AdminBroadCastMsg} |
| 841 | |
| 842 | Portal Admin Category Notifications |
| 843 | [Documentation] Portal Admin Broadcast Notifications |
CHINTAMANI | 68e9836 | 2018-04-10 18:56:38 -0400 | [diff] [blame] | 844 | ${CurrentDay}= Get Current Date increment=24:00:00 result_format=%m/%d/%Y |
| 845 | ${NextDay}= Get Current Date increment=48:00:00 result_format=%m/%d/%Y |
| 846 | # ${CurrentDay}= Get Current Date result_format=%m/%d/%Y |
| 847 | ${CurrentDate}= Get Current Date increment=24:00:00 result_format=%m%d%y%H%M |
kishore | 6eebdba | 2017-10-03 11:12:57 -0500 | [diff] [blame] | 848 | ${AdminCategoryMsg}= catenate ONAP VID Category Automation${CurrentDate} |
| 849 | Click Link xpath=//a[@id='parent-item-Home'] |
| 850 | Click Link xpath=//*[@id="parent-item-User-Notifications"] |
| 851 | Wait until Element is visible xpath=//*[@id="button-openAddNewApp"] timeout=10 |
| 852 | Click button xpath=//*[@id="button-openAddNewApp"] |
| 853 | #Select Radio Button NO radio-button-no |
| 854 | Click Element //*[contains(text(),'Broadcast to All Categories')]/following::*[contains(text(),'No')][1] |
| 855 | #Select Radio Button //label[@class='radio'] radio-button-approles |
| 856 | Click Element xpath=//*[contains(text(),'Categories')]/following::*[contains(text(),'Application Roles')][1] |
kishore | 92d70d6 | 2017-10-11 14:51:31 -0500 | [diff] [blame] | 857 | Click Element xpath=//*[contains(text(),'xDemo App')]/preceding::input[@ng-model='member.isSelected'][1] |
kishore | 6eebdba | 2017-10-03 11:12:57 -0500 | [diff] [blame] | 858 | Input Text xpath=//input[@id='datepicker-start'] ${CurrentDay} |
| 859 | Input Text xpath=//input[@id='datepicker-end'] ${NextDay} |
| 860 | Input Text xpath=//*[@id="add-notification-input-title"] ONAP VID Category Automation |
| 861 | Input Text xpath=//*[@id='user-notif-input-message'] ${AdminCategoryMsg} |
| 862 | click element xpath=//*[@id="button-notification-save"] |
| 863 | Wait until Element is visible xpath=//*[@id="button-openAddNewApp"] timeout=10 |
| 864 | click element xpath=//*[@id="megamenu-notification-button"] |
| 865 | click element xpath=//*[@id="notification-history-link"] |
CHINTAMANI | af44d44 | 2018-04-25 12:38:44 -0400 | [diff] [blame] | 866 | # Notification bug, Uncomment the code when PORTAL-232 is fixed |
| 867 | # Wait until Element is visible xpath=//*[@id="notification-history-table"] timeout=10 |
| 868 | # Table Column Should Contain xpath=//*[@id="notification-history-table"] 2 ${AdminCategoryMsg} |
CHINTAMANI | 68e9836 | 2018-04-10 18:56:38 -0400 | [diff] [blame] | 869 | Set Selenium Implicit Wait 3000 |
kishore | 6eebdba | 2017-10-03 11:12:57 -0500 | [diff] [blame] | 870 | log ${AdminCategoryMsg} |
CHINTAMANI | 68e9836 | 2018-04-10 18:56:38 -0400 | [diff] [blame] | 871 | [Return] ${AdminCategoryMsg} |
kishore | 6eebdba | 2017-10-03 11:12:57 -0500 | [diff] [blame] | 872 | |
kishore | bbca0cf | 2017-10-09 16:59:38 -0500 | [diff] [blame] | 873 | Portal admin Logout from Portal GUI |
kishore | 6eebdba | 2017-10-03 11:12:57 -0500 | [diff] [blame] | 874 | [Documentation] Logout from Portal GUI |
| 875 | Click Element xpath=//div[@id='header-user-icon'] |
| 876 | Click Button xpath=//button[contains(.,'Log out')] |
| 877 | Title Should Be Login |
| 878 | |
kishore | 6eebdba | 2017-10-03 11:12:57 -0500 | [diff] [blame] | 879 | Application admin Login To Portal GUI |
| 880 | [Documentation] Logs into Portal GUI |
| 881 | # Setup Browser Now being managed by test case |
| 882 | ##Setup Browser |
kishore | 72d3adf | 2017-10-19 11:05:22 -0500 | [diff] [blame] | 883 | # Go To ${PORTAL_LOGIN_URL} |
| 884 | # Maximize Browser Window |
| 885 | # Set Selenium Speed ${GLOBAL_SELENIUM_DELAY} |
| 886 | # Set Browser Implicit Wait ${GLOBAL_SELENIUM_BROWSER_IMPLICIT_WAIT} |
| 887 | # Log Logging in to ${PORTAL_URL}${PORTAL_ENV} |
kishore | 6eebdba | 2017-10-03 11:12:57 -0500 | [diff] [blame] | 888 | # Handle Proxy Warning |
| 889 | Title Should Be Login |
| 890 | Input Text xpath=//input[@ng-model='loginId'] ${App_LoginID} |
| 891 | Input Password xpath=//input[@ng-model='password'] ${App_Loginpwd} |
| 892 | Click Link xpath=//a[@id='loginBtn'] |
| 893 | Wait Until Page Contains Element xpath=//img[@alt='Onap Logo'] ${GLOBAL_SELENIUM_BROWSER_WAIT_TIMEOUT} |
| 894 | Log Logged in to ${PORTAL_URL}${PORTAL_ENV} |
| 895 | |
| 896 | Application Admin Navigation Application Link Tab |
| 897 | [Documentation] Logs into Portal GUI as application admin |
| 898 | Click Link xpath=//a[@id='parent-item-Home'] |
kishore | 92d70d6 | 2017-10-11 14:51:31 -0500 | [diff] [blame] | 899 | Click Element xpath=.//h3[contains(text(),'xDemo App')]/following::div[1] |
| 900 | Page Should Contain ONAP Portal |
kishore | 5ea942b | 2017-10-14 22:19:45 -0500 | [diff] [blame] | 901 | Scroll Element Into View xpath=//i[@class='ion-close-round'] |
| 902 | Click Element xpath=//i[@class='ion-close-round'] |
| 903 | Set Selenium Implicit Wait 3000 |
| 904 | #Click Element xpath=(.//span[@id='tab-Home'])[1] |
kishore | 6eebdba | 2017-10-03 11:12:57 -0500 | [diff] [blame] | 905 | |
| 906 | |
| 907 | Application Admin Navigation Functional Menu |
| 908 | [Documentation] Logs into Portal GUI as application admin |
| 909 | Click Link xpath=//a[contains(.,'Manage')] |
| 910 | Mouse Over xpath=//*[contains(text(),'Technology Insertion')] |
| 911 | Click Link xpath= //*[contains(text(),'Infrastructure VNF Provisioning')] |
kishore | 92d70d6 | 2017-10-11 14:51:31 -0500 | [diff] [blame] | 912 | Page Should Contain ONAP Portal |
kishore | 6eebdba | 2017-10-03 11:12:57 -0500 | [diff] [blame] | 913 | Click Element xpath=//i[@class='ion-close-round'] |
| 914 | Click Element xpath=(.//span[@id='tab-Home'])[1] |
| 915 | |
| 916 | |
CHINTAMANI | af44d44 | 2018-04-25 12:38:44 -0400 | [diff] [blame] | 917 | Application admin Add Standard User Existing user |
kishore | 6eebdba | 2017-10-03 11:12:57 -0500 | [diff] [blame] | 918 | [Documentation] Naviage to Users tab |
| 919 | Click Link xpath=//a[@title='Users'] |
| 920 | Page Should Contain Users |
| 921 | Click Button xpath=//button[@ng-click='toggleSidebar()'] |
| 922 | Click Button xpath=//button[@ng-click='users.openAddNewUserModal()'] |
| 923 | Input Text xpath=//input[@id='input-user-search'] ${Existing_User} |
| 924 | Click Button xpath=//button[@id='button-search-users'] |
| 925 | Click Element xpath=//span[@id='result-uuid-0'] |
| 926 | Click Button xpath=//button[@id='next-button'] |
kishore | 92d70d6 | 2017-10-11 14:51:31 -0500 | [diff] [blame] | 927 | Click Element xpath=//*[@id='div-app-name-dropdown-xDemo-App'] |
| 928 | Click Element xpath=//*[@id='div-app-name-xDemo-App']/following::input[@id='Standard-User-checkbox'] |
CHINTAMANI | af44d44 | 2018-04-25 12:38:44 -0400 | [diff] [blame] | 929 | # Click Element xpath=//*[@id='div-app-name-dropdown-Default'] |
| 930 | # Click Element xpath=//*[@id='div-app-name-Default']/following::input[@id='Standard-User-checkbox'] |
| 931 | # Set Selenium Implicit Wait 3000 |
kishore | 6eebdba | 2017-10-03 11:12:57 -0500 | [diff] [blame] | 932 | Click Button xpath=//button[@id='new-user-save-button'] |
| 933 | Set Selenium Implicit Wait 3000 |
| 934 | #Set Browser Implicit Wait ${GLOBAL_SELENIUM_BROWSER_IMPLICIT_WAIT} |
kishore | 92d70d6 | 2017-10-11 14:51:31 -0500 | [diff] [blame] | 935 | #Select From List xpath=//input[@value='Select application'] xDemo App |
kishore | 6eebdba | 2017-10-03 11:12:57 -0500 | [diff] [blame] | 936 | #Click Link xpath=//a[@title='Users'] |
| 937 | #Page Should Contain Users |
| 938 | Go To ${PORTAL_HOME_PAGE} |
| 939 | Set Selenium Implicit Wait 3000 |
| 940 | Click Link xpath=//a[@title='Users'] |
| 941 | Click Element xpath=//input[@id='dropdown1'] |
CHINTAMANI | af44d44 | 2018-04-25 12:38:44 -0400 | [diff] [blame] | 942 | #Click Element xpath=//li[contains(.,'Default')] |
kishore | 92d70d6 | 2017-10-11 14:51:31 -0500 | [diff] [blame] | 943 | Click Element xpath=//li[contains(.,'xDemo App')] |
kishore | 6eebdba | 2017-10-03 11:12:57 -0500 | [diff] [blame] | 944 | Input Text xpath=//input[@id='input-table-search'] ${Existing_User} |
CHINTAMANI | af44d44 | 2018-04-25 12:38:44 -0400 | [diff] [blame] | 945 | # Element Text Should Be xpath=(.//*[@id='rowheader_t1_0'])[2] Account Administrator |
kishore | 6eebdba | 2017-10-03 11:12:57 -0500 | [diff] [blame] | 946 | Element Text Should Be xpath=(.//*[@id='rowheader_t1_0'])[2] Standard User |
| 947 | |
CHINTAMANI | af44d44 | 2018-04-25 12:38:44 -0400 | [diff] [blame] | 948 | Application admin Edit Standard User Existing user |
kishore | 6eebdba | 2017-10-03 11:12:57 -0500 | [diff] [blame] | 949 | [Documentation] Naviage to Users tab |
| 950 | Click Element xpath=(.//*[@id='rowheader_t1_0'])[2] |
CHINTAMANI | af44d44 | 2018-04-25 12:38:44 -0400 | [diff] [blame] | 951 | # Click Element xpath=//*[@id='div-app-name-dropdown-Default'] |
| 952 | # Click Element xpath=//*[@id='div-app-name-Default']/following::input[@id='Standard-User-checkbox'] |
| 953 | # Click Element xpath=//*[@id='div-app-name-Default']/following::input[@id='Portal-Notification-Admin-checkbox'] |
kishore | 92d70d6 | 2017-10-11 14:51:31 -0500 | [diff] [blame] | 954 | Click Element xpath=//*[@id='div-app-name-dropdown-xDemo-App'] |
| 955 | Click Element xpath=//*[@id='div-app-name-xDemo-App']/following::input[@id='Standard-User-checkbox'] |
CHINTAMANI | af44d44 | 2018-04-25 12:38:44 -0400 | [diff] [blame] | 956 | Click Element xpath=//*[@id='div-app-name-xDemo-App']/following::input[@id='System-Administrator-checkbox'] |
kishore | 6eebdba | 2017-10-03 11:12:57 -0500 | [diff] [blame] | 957 | Set Selenium Implicit Wait 3000 |
| 958 | Click Button xpath=//button[@id='new-user-save-button'] |
| 959 | Set Selenium Implicit Wait 3000 |
| 960 | Page Should Contain Users |
| 961 | #Click Button xpath=//input[@id='dropdown1'] |
kishore | 92d70d6 | 2017-10-11 14:51:31 -0500 | [diff] [blame] | 962 | #Click Element xpath=//li[contains(.,'xDemo App')] |
kishore | 6eebdba | 2017-10-03 11:12:57 -0500 | [diff] [blame] | 963 | Input Text xpath=//input[@id='input-table-search'] ${Existing_User} |
CHINTAMANI | af44d44 | 2018-04-25 12:38:44 -0400 | [diff] [blame] | 964 | # Element Text Should Be xpath=(.//*[@id='rowheader_t1_0'])[2] Account Administrator |
kishore | 6eebdba | 2017-10-03 11:12:57 -0500 | [diff] [blame] | 965 | Element Text Should Be xpath=(.//*[@id='rowheader_t1_0'])[2] System Administrator |
| 966 | |
kishore | 6eebdba | 2017-10-03 11:12:57 -0500 | [diff] [blame] | 967 | Application admin Delete Standard User Existing user |
| 968 | [Documentation] Naviage to Users tab |
| 969 | Click Element xpath=(.//*[@id='rowheader_t1_0'])[2] |
CHINTAMANI | 68e9836 | 2018-04-10 18:56:38 -0400 | [diff] [blame] | 970 | # Scroll Element Into View xpath=//*[@id='div-app-name-Default']/following::*[@id='app-item-delete'][1] |
| 971 | # Click Element xpath=//*[@id='div-app-name-Default']/following::*[@id='app-item-delete'][1] |
kishore | 92d70d6 | 2017-10-11 14:51:31 -0500 | [diff] [blame] | 972 | Scroll Element Into View xpath=//*[@id='div-app-name-xDemo-App']/following::*[@id='app-item-delete'][1] |
| 973 | Click Element xpath=//*[@id='div-app-name-xDemo-App']/following::*[@id='app-item-delete'][1] |
kishore | 6eebdba | 2017-10-03 11:12:57 -0500 | [diff] [blame] | 974 | Click Element xpath=//button[@id='div-confirm-ok-button'] |
| 975 | Click Button xpath=//button[@id='new-user-save-button'] |
CHINTAMANI | 68e9836 | 2018-04-10 18:56:38 -0400 | [diff] [blame] | 976 | # Input Text xpath=//input[@id='input-table-search'] ${Existing_User} |
| 977 | # Is Element Visible xpath=(//*[contains(.,'Portal')] )[2] |
kishore | 6eebdba | 2017-10-03 11:12:57 -0500 | [diff] [blame] | 978 | Element Should Not Contain xpath=//*[@table-data='users.accountUsers'] Portal |
kishore | 72d3adf | 2017-10-19 11:05:22 -0500 | [diff] [blame] | 979 | #Click Image xpath=//img[@alt='Onap Logo'] |
CHINTAMANI | 68e9836 | 2018-04-10 18:56:38 -0400 | [diff] [blame] | 980 | Set Selenium Implicit Wait 3000 |
kishore | 6eebdba | 2017-10-03 11:12:57 -0500 | [diff] [blame] | 981 | |
kishore | 6eebdba | 2017-10-03 11:12:57 -0500 | [diff] [blame] | 982 | Application admin Logout from Portal GUI |
| 983 | [Documentation] Logout from Portal GUI |
| 984 | Click Element xpath=//div[@id='header-user-icon'] |
kishore | 72d3adf | 2017-10-19 11:05:22 -0500 | [diff] [blame] | 985 | #Set Selenium Implicit Wait 3000 |
kishore | 82eb79a | 2017-10-31 08:04:25 -0500 | [diff] [blame] | 986 | Click Button xpath=//button[contains(text(),'Log out')] |
kishore | 72d3adf | 2017-10-19 11:05:22 -0500 | [diff] [blame] | 987 | #Set Selenium Implicit Wait 3000 |
kishore | 4089a33 | 2017-10-18 17:02:53 -0500 | [diff] [blame] | 988 | Title Should Be Login |
kishore | 6eebdba | 2017-10-03 11:12:57 -0500 | [diff] [blame] | 989 | |
| 990 | Standared user Login To Portal GUI |
| 991 | [Documentation] Logs into Portal GUI |
| 992 | # Setup Browser Now being managed by test case |
| 993 | ##Setup Browser |
kishore | 72d3adf | 2017-10-19 11:05:22 -0500 | [diff] [blame] | 994 | # Go To ${PORTAL_LOGIN_URL} |
| 995 | # Maximize Browser Window |
| 996 | # Set Selenium Speed ${GLOBAL_SELENIUM_DELAY} |
| 997 | # Set Browser Implicit Wait ${GLOBAL_SELENIUM_BROWSER_IMPLICIT_WAIT} |
| 998 | # Log Logging in to ${PORTAL_URL}${PORTAL_ENV} |
kishore | 6eebdba | 2017-10-03 11:12:57 -0500 | [diff] [blame] | 999 | # Handle Proxy Warning |
| 1000 | Title Should Be Login |
| 1001 | Input Text xpath=//input[@ng-model='loginId'] ${Sta_LoginID} |
| 1002 | Input Password xpath=//input[@ng-model='password'] ${Sta_Loginpwd} |
| 1003 | Click Link xpath=//a[@id='loginBtn'] |
| 1004 | Wait Until Page Contains Element xpath=//img[@alt='Onap Logo'] ${GLOBAL_SELENIUM_BROWSER_WAIT_TIMEOUT} |
| 1005 | Log Logged in to ${PORTAL_URL}${PORTAL_ENV} |
| 1006 | |
kishore | 6eebdba | 2017-10-03 11:12:57 -0500 | [diff] [blame] | 1007 | Standared user Navigation Application Link Tab |
| 1008 | [Documentation] Logs into Portal GUI as application admin |
| 1009 | #Portal admin Go To Portal HOME |
kishore | 92d70d6 | 2017-10-11 14:51:31 -0500 | [diff] [blame] | 1010 | Click Element xpath=.//h3[contains(text(),'xDemo App')]/following::div[1] |
| 1011 | Page Should Contain ONAP Portal |
kishore | 6eebdba | 2017-10-03 11:12:57 -0500 | [diff] [blame] | 1012 | Click Element xpath=(.//span[@id='tab-Home'])[1] |
CHINTAMANI | 68e9836 | 2018-04-10 18:56:38 -0400 | [diff] [blame] | 1013 | Set Selenium Implicit Wait 3000 |
kishore | 6eebdba | 2017-10-03 11:12:57 -0500 | [diff] [blame] | 1014 | |
| 1015 | Standared user Navigation Functional Menu |
| 1016 | [Documentation] Logs into Portal GUI as application admin |
| 1017 | Click Link xpath=//a[contains(.,'Manage')] |
CHINTAMANI | 68e9836 | 2018-04-10 18:56:38 -0400 | [diff] [blame] | 1018 | Mouse Over xpath=//*[contains(text(),'Technology Insertion')] |
| 1019 | Click Link xpath= //*[contains(text(),'Infrastructure VNF Provisioning')] |
| 1020 | Page Should Contain Welcome to VID |
| 1021 | Click Element xpath=(.//span[@id='tab-Home'])[1] |
| 1022 | Set Selenium Implicit Wait 3000 |
kishore | 6eebdba | 2017-10-03 11:12:57 -0500 | [diff] [blame] | 1023 | |
| 1024 | |
| 1025 | Standared user Broadcast Notifications |
| 1026 | [Documentation] Logs into Portal GUI as application admin |
| 1027 | [Arguments] ${AdminBroadCastMsg} |
| 1028 | Click element xpath=//*[@id='megamenu-notification-button'] |
| 1029 | Click element xpath=//*[@id='notification-history-link'] |
| 1030 | Wait until Element is visible xpath=//*[@id='app-title'] timeout=10 |
| 1031 | Table Column Should Contain xpath=//*[@id='notification-history-table'] 2 ${AdminBroadCastMsg} |
| 1032 | log ${AdminBroadCastMsg} |
| 1033 | |
| 1034 | |
| 1035 | Standared user Category Notifications |
| 1036 | [Documentation] Logs into Portal GUI as application admin |
| 1037 | [Arguments] ${AdminCategoryMsg} |
| 1038 | #click element xpath=//*[@id='megamenu-notification-button'] |
| 1039 | #click element xpath=//*[@id="notification-history-link"] |
| 1040 | Wait until Element is visible xpath=//*[@id='app-title'] timeout=10 |
| 1041 | Table Column Should Contain xpath=//*[@id='notification-history-table'] 2 ${AdminCategoryMsg} |
| 1042 | log ${AdminCategoryMsg} |
| 1043 | |
kishore | 6eebdba | 2017-10-03 11:12:57 -0500 | [diff] [blame] | 1044 | Standared user Logout from Portal GUI |
| 1045 | [Documentation] Logout from Portal GUI |
| 1046 | Click Element xpath=//div[@id='header-user-icon'] |
| 1047 | Click Button xpath=//button[contains(.,'Log out')] |
| 1048 | #Confirm Action |
| 1049 | Title Should Be Login |
| 1050 | |
CHINTAMANI | af44d44 | 2018-04-25 12:38:44 -0400 | [diff] [blame] | 1051 | Portal admin Add New Account |
| 1052 | Click Link //*[@id="parent-item-App-Account-Management"] |
| 1053 | Click Button xpath=//button[@ng-click='toggleSidebar()'] |
| 1054 | Set Selenium Implicit Wait 3000 |
| 1055 | Click Button //*[@id="account-onboarding-button-add"] |
| 1056 | Set Selenium Implicit Wait 3000 |
| 1057 | Input Text //*[@id="account-details-input-name"] ${AppAccountName} |
| 1058 | Input Text //*[@id="account-details-input-username"] ${AppUserName} |
| 1059 | Input Text //*[@id="account-details-input-password"] ${AppPassword} |
| 1060 | Input Text //*[@id="account-details-input-repassword"] ${AppPassword} |
| 1061 | # Click Button xpath=//*[@ng-click='accountAddDetails.saveChanges()'] |
| 1062 | # #Click Button xpath=//button[@ng-click='admins.openAddNewAdminModal()'] |
| 1063 | #account-details-next-button |
| 1064 | Click Button xpath=//button[@ng-click='accountAddDetails.saveChanges()'] |
| 1065 | |
| 1066 | Portal admin Delete Account |
| 1067 | Click Link //*[@id="parent-item-App-Account-Management"] |
| 1068 | Click Button xpath=//button[@ng-click='toggleSidebar()'] |
| 1069 | Set Selenium Implicit Wait 3000 |
| 1070 | Click Button //*[@id="account-onboarding-button-add"] |
| 1071 | Set Selenium Implicit Wait 3000 |
| 1072 | |
| 1073 | Tear Down |
kishore | 6eebdba | 2017-10-03 11:12:57 -0500 | [diff] [blame] | 1074 | [Documentation] Close all browsers |
| 1075 | Close All Browsers |
| 1076 | |
kishore | 6eebdba | 2017-10-03 11:12:57 -0500 | [diff] [blame] | 1077 | Enhanced Notification on ONAP Portal |
| 1078 | [Documentation] Runs portal Post request |
| 1079 | [Arguments] ${data_path} ${data} |
CHINTAMANI | af44d44 | 2018-04-25 12:38:44 -0400 | [diff] [blame] | 1080 | # Log Creating session ${GLOBAL_PORTAL_SERVER_URL} |
kishore | 6eebdba | 2017-10-03 11:12:57 -0500 | [diff] [blame] | 1081 | ${session}= Create Session portal ${PORTAL_URL} |
| 1082 | ${headers}= Create Dictionary Accept=application/json Content-Type=application/json Authorization=Basic amlyYTpfcGFzcw== username=jira password=_pass |
| 1083 | ${resp}= Post Request portal ${data_path} data=${data} headers=${headers} |
CHINTAMANI | af44d44 | 2018-04-25 12:38:44 -0400 | [diff] [blame] | 1084 | # Log Received response from portal ${resp.text} |
kishore | 6eebdba | 2017-10-03 11:12:57 -0500 | [diff] [blame] | 1085 | [Return] ${resp} |
CHINTAMANI | af44d44 | 2018-04-25 12:38:44 -0400 | [diff] [blame] | 1086 | |
kishore | 6eebdba | 2017-10-03 11:12:57 -0500 | [diff] [blame] | 1087 | Notification on ONAP Portal |
| 1088 | [Documentation] Create Config portal |
| 1089 | ${configportal}= Create Dictionary jira_id=${jira} |
| 1090 | ${output} = Fill JSON Template File ${portal_Template} ${configportal} |
| 1091 | ${post_resp} = Enhanced Notification on ONAP Portal ${RESOURCE_PATH} ${output} |
| 1092 | Should Be Equal As Strings ${post_resp.status_code} 200 |
kishore | 6eebdba | 2017-10-03 11:12:57 -0500 | [diff] [blame] | 1093 | |
| 1094 | Portal Application Account Management |
| 1095 | [Documentation] Naviage to Application Account Management tab |
| 1096 | Click Link xpath=//a[@title='App Account Management'] |
| 1097 | Click Button xpath=//button[@id='account-onboarding-button-add'] |
| 1098 | Input Text xpath=//input[@name='name'] JIRA |
| 1099 | Input Text xpath=//input[@name='username'] jira |
| 1100 | Input Text xpath=//input[@name='password'] _pass |
| 1101 | Input Text xpath=//input[@name='repassword'] _pass |
| 1102 | Click Element xpath=//div[@ng-click='accountAddDetails.saveChanges()'] |
| 1103 | Element Text Should Be xpath=//*[@table-data='serviceList'] JIRA |
| 1104 | |
CHINTAMANI | af44d44 | 2018-04-25 12:38:44 -0400 | [diff] [blame] | 1105 | Portal Application Account Management validation |
kishore | 6eebdba | 2017-10-03 11:12:57 -0500 | [diff] [blame] | 1106 | [Documentation] Naviage to user notification tab |
| 1107 | Click Link xpath=//a[@id='parent-item-User-Notifications'] |
| 1108 | click element xpath=//*[@id="megamenu-notification-button"] |
| 1109 | Click element xpath=//*[@id="notification-history-link"] |
| 1110 | Wait until Element is visible xpath=//*[@id="notification-history-table"] timeout=10 |
| 1111 | Table Column Should Contain xpath=//*[@id="notification-history-table"] 1 JIRA |
| 1112 | |
| 1113 | |
CHINTAMANI | af44d44 | 2018-04-25 12:38:44 -0400 | [diff] [blame] | 1114 | Portal AAF new fields |
kishore | 6eebdba | 2017-10-03 11:12:57 -0500 | [diff] [blame] | 1115 | [Documentation] Naviage to user Application details tab |
| 1116 | Click Link xpath=//a[@title='Application Onboarding'] |
kishore | 92d70d6 | 2017-10-11 14:51:31 -0500 | [diff] [blame] | 1117 | Click Element xpath=//td[contains(.,'xDemo App')] |
kishore | 6eebdba | 2017-10-03 11:12:57 -0500 | [diff] [blame] | 1118 | Page Should Contain Name Space |
| 1119 | Page Should Contain Centralized |
| 1120 | Click Element xpath=//button[@id='button-notification-cancel'] |
| 1121 | |
CHINTAMANI | af44d44 | 2018-04-25 12:38:44 -0400 | [diff] [blame] | 1122 | Admin widget download |
| 1123 | Go To ${PORTAL_HOME_URL} |
| 1124 | Wait until page contains Element xpath=//a[@title='Widget Onboarding'] ${GLOBAL_SELENIUM_BROWSER_WAIT_TIMEOUT} |
| 1125 | click Link xpath=//a[@title='Widget Onboarding'] |
| 1126 | Wait until page contains Element xpath=//table[@class='ng-scope'] |
| 1127 | ${td_id}= get element attribute xpath=//*[contains(text(),'Events')]@id |
| 1128 | log ${td_id} |
| 1129 | ${test}= Get Substring ${td_id} -1 |
| 1130 | log ${test} |
| 1131 | ${download_link_id}= Catenate 'widget-onboarding-div-download-widget-${test}' |
| 1132 | click Element xpath=//*[@id=${download_link_id}] |
| 1133 | |
| 1134 | Reset widget layout option |
| 1135 | Go To ${PORTAL_HOME_URL} |
| 1136 | Wait Until Page Contains Element xpath=//div[@id='widget-boarder'] ${GLOBAL_SELENIUM_BROWSER_WAIT_TIMEOUT} |
| 1137 | Execute Javascript document.getElementById('widgets').scrollTo(0,1400) |
| 1138 | Wait Until Page Contains Element xpath=//*[@id='widget-gridster-Events-icon'] ${GLOBAL_SELENIUM_BROWSER_WAIT_TIMEOUT} |
| 1139 | Execute Javascript document.getElementById('widgets').scrollTo(0,1800) |
| 1140 | Drag And Drop By Offset xpath=//*[@id='widget-gridster-Events-icon'] 500 500 |
| 1141 | Execute Javascript document.getElementById('widgets').scrollTo(0,document.getElementById('widgets').scrollHeight); |
| 1142 | Execute Javascript document.getElementById('dashboardDefaultPreference').click() |
| 1143 | Execute Javascript document.getElementById('div-confirm-ok-button').click() |