Sivas SRR | f424885 | 2018-01-14 10:33:24 -0600 | [diff] [blame] | 1 | #!/usr/bin/python |
| 2 | |
| 3 | r""" |
| 4 | Contains xpaths and related string constants applicable to all openBMC GUI |
| 5 | menus. |
| 6 | """ |
| 7 | |
| 8 | |
| 9 | class resource_variables(): |
| 10 | |
| 11 | xpath_textbox_hostname = "//*[@id='login__form']/input[1]" |
| 12 | xpath_textbox_username = "//*[@id='username']" |
| 13 | xpath_textbox_password = "//*[@id='password']" |
| 14 | xpath_button_login = "//*[@id='login__submit']" |
| 15 | xpath_button_logout = "//*[@id='header']/a" |
| 16 | xpath_display_server_power_status = \ |
| 17 | "//*[@id='header__wrapper']/div/div[3]/a[3]/span" |
| 18 | xpath_select_button_orderly_power_shutdown = \ |
| 19 | "//*[@id='power__soft-shutdown']" |
| 20 | xpath_select_button_orderly_power_shutdown_yes = \ |
| 21 | "//*[@id='power-operations']/div[3]/div[5]/confirm/div/div[2]/" \ |
| 22 | "button[1]" |
| 23 | xpath_select_button_power_on = "//*[@id='power__power-on']" |
| 24 | |
| 25 | xpath_openbmc_url = "http://localhost:8080/#/login" |
| 26 | xpath_openbmc_ip = "//*[@id='login__form']/input[1]" |
| 27 | openbmc_username = "root" |
| 28 | openbmc_password = "0penBmc" |
| 29 | |
| 30 | obmc_off_state = "Off" |
| 31 | obmc_quiesced_state = "Quiesced" |
| 32 | obmc_running_state = "Running" |
| 33 | |
| 34 | # Power operation elements needed for power on. |
| 35 | header_wrapper = "3" |
| 36 | header_wrapper_elt = "3" |
| 37 | |
| 38 | # Power operation elements needed for power operations confirmation. |
| 39 | power_operations = "3" |
| 40 | warm_boot = "3" |
| 41 | cold_boot = "4" |
| 42 | shut_down = "5" |
| 43 | power_off = "6" |
| 44 | confirm_msg = "2" |
| 45 | yes = "1" |
| 46 | no = "2" |
| 47 | |