1*b89977a4SRahul Maheshwari*** Settings *** 2*b89977a4SRahul MaheshwariDocumentation This test suite will validate the "OpenBMC" GUI -> 3*b89977a4SRahul Maheshwari... "Server control" main menu -> "Server power 4*b89977a4SRahul Maheshwari... operations" submenu module. 5*b89977a4SRahul Maheshwari 6*b89977a4SRahul MaheshwariResource ../../lib/resource.robot 7*b89977a4SRahul MaheshwariTest Setup Test Setup Execution ${OBMC_PowerOff_state} 8*b89977a4SRahul MaheshwariTest Teardown Test Teardown Execution 9*b89977a4SRahul Maheshwari 10*b89977a4SRahul Maheshwari*** Variables *** 11*b89977a4SRahul Maheshwari${xpath_select_server_control} //*[@id="nav__top-level"]/li[3]/button/span 12*b89977a4SRahul Maheshwari${xpath_select_server_power_operations} //a[@href='#/server-control/power-operations'] 13*b89977a4SRahul Maheshwari${string_server_power_operations} Server power operations 14*b89977a4SRahul Maheshwari${string_current_status} Current status 15*b89977a4SRahul Maheshwari${string_select_power_operation} Select a power operation 16*b89977a4SRahul Maheshwari${string_warm_reboot} Attempts to perform an orderly shutdown before restarting the server 17*b89977a4SRahul Maheshwari${string_cold_reboot} Shuts down the server immediately, then restarts it 18*b89977a4SRahul Maheshwari${string_orderly_shutdown} Attempts to stop all software on the server before removing power 19*b89977a4SRahul Maheshwari${string_immediate_shutdown} Removes power from the server without waiting for software to stop 20*b89977a4SRahul Maheshwari${string_power_on} Attempts to power on the server 21*b89977a4SRahul Maheshwari 22*b89977a4SRahul Maheshwari*** Test Case *** 23*b89977a4SRahul Maheshwari# OpenBMC @ Power Off state test cases. 24*b89977a4SRahul Maheshwari 25*b89977a4SRahul MaheshwariVerify Title Text Should Be Server Power Operations At Power Off 26*b89977a4SRahul Maheshwari [Documentation] Verify display of title text "Server Power Operations". 27*b89977a4SRahul Maheshwari [Tags] Verify_Title_Text_Should_Be_Server_Power_Operations_At_Power_Off 28*b89977a4SRahul Maheshwari ... OBMC_PowerOff_state 29*b89977a4SRahul Maheshwari 30*b89977a4SRahul Maheshwari Select Server Power Operations Sub Menu 31*b89977a4SRahul Maheshwari Verify Display Content ${string_server_power_operations} 32*b89977a4SRahul Maheshwari 33*b89977a4SRahul MaheshwariVerify Sub Title Text Should Be Current Status At Power Off 34*b89977a4SRahul Maheshwari [Documentation] Verify display of title text "Current Status". 35*b89977a4SRahul Maheshwari [Tags] Verify_Sub_Title_Text_Should_Be_Current_Status_At_Power_Off 36*b89977a4SRahul Maheshwari ... OBMC_PowerOff_state 37*b89977a4SRahul Maheshwari 38*b89977a4SRahul Maheshwari Select Server Power Operations Sub Menu 39*b89977a4SRahul Maheshwari Verify Display Content ${string_current_status} 40*b89977a4SRahul Maheshwari 41*b89977a4SRahul MaheshwariVerify Sub Title Text Should Be Select Power Operation At Power Off 42*b89977a4SRahul Maheshwari [Documentation] Verify display of title text "Select a power operation". 43*b89977a4SRahul Maheshwari [Tags] Verify_Sub_Title_Text_Should_Be_Select_Power_Operation_At_Power_Off 44*b89977a4SRahul Maheshwari ... OBMC_PowerOff_state 45*b89977a4SRahul Maheshwari 46*b89977a4SRahul Maheshwari Select Server Power Operations Sub Menu 47*b89977a4SRahul Maheshwari Verify Display Content ${string_Select_power_operation} 48*b89977a4SRahul Maheshwari 49*b89977a4SRahul MaheshwariVerify Power On Button Should Present At Power Off 50*b89977a4SRahul Maheshwari [Documentation] Verify presence of "Warm reboot" button. 51*b89977a4SRahul Maheshwari [Tags] Verify_Power_On_Button_Should_Present_At_Power_Off 52*b89977a4SRahul Maheshwari ... OBMC_PowerOff_State 53*b89977a4SRahul Maheshwari 54*b89977a4SRahul Maheshwari Select Server Power Operations Sub Menu 55*b89977a4SRahul Maheshwari Verify Presence of Power Button And Text Info 56*b89977a4SRahul Maheshwari ... ${xpath_select_button_power_on} ${string_power_on} 57*b89977a4SRahul Maheshwari 58*b89977a4SRahul MaheshwariVerify Power On At Power Off 59*b89977a4SRahul Maheshwari [Documentation] Verify presence of "Warm reboot" button. 60*b89977a4SRahul Maheshwari [Tags] Verify_Power_On_At_Power_Off 61*b89977a4SRahul Maheshwari ... OBMC_PowerOff_State 62*b89977a4SRahul Maheshwari 63*b89977a4SRahul Maheshwari Power On OpenBMC 64*b89977a4SRahul Maheshwari 65*b89977a4SRahul Maheshwari 66*b89977a4SRahul Maheshwari# OpenBMC @ Power Running state test cases. 67*b89977a4SRahul Maheshwari 68*b89977a4SRahul MaheshwariVerify Warm Reboot Button Should Present At Power Running 69*b89977a4SRahul Maheshwari [Documentation] Verify presence of "Warm reboot" button. 70*b89977a4SRahul Maheshwari [Tags] Verify_Warm_Reboot_Button_Should_Present_At_Power_Running 71*b89977a4SRahul Maheshwari ... OBMC_PowerRunning_State 72*b89977a4SRahul Maheshwari [Setup] Test Setup Execution ${OBMC_PowerRunning_state} 73*b89977a4SRahul Maheshwari 74*b89977a4SRahul Maheshwari Select Server Power Operations Sub Menu 75*b89977a4SRahul Maheshwari Verify Presence of Power Button And Text Info 76*b89977a4SRahul Maheshwari ... ${xpath_select_button_warm_reboot} ${string_warm_reboot} 77*b89977a4SRahul Maheshwari 78*b89977a4SRahul MaheshwariVerify Cold Reboot Button Should Present At Power Running 79*b89977a4SRahul Maheshwari [Documentation] Verify presence of "cold reboot" button. 80*b89977a4SRahul Maheshwari [Tags] Verify_Cold_Reboot_Button_Should_Present_At_Power_Running 81*b89977a4SRahul Maheshwari ... OBMC_PowerRunning_State 82*b89977a4SRahul Maheshwari [Setup] Test Setup Execution ${OBMC_PowerRunning_state} 83*b89977a4SRahul Maheshwari 84*b89977a4SRahul Maheshwari Select Server Power Operations Sub Menu 85*b89977a4SRahul Maheshwari Verify Presence of Power Button And Text Info 86*b89977a4SRahul Maheshwari ... ${xpath_select_button_cold_reboot} ${string_cold_reboot} 87*b89977a4SRahul Maheshwari 88*b89977a4SRahul MaheshwariVerify Orderly Shutdown Button Should Present At Power Running 89*b89977a4SRahul Maheshwari [Documentation] Verify presence of "Orderly shutdow " button. 90*b89977a4SRahul Maheshwari [Tags] Verify_Orderly_Shutdown_Button_Should_Present_At_Power_Running 91*b89977a4SRahul Maheshwari ... OBMC_PowerRunning_State 92*b89977a4SRahul Maheshwari [Setup] Test Setup Execution ${OBMC_PowerRunning_state} 93*b89977a4SRahul Maheshwari 94*b89977a4SRahul Maheshwari Select Server Power Operations Sub Menu 95*b89977a4SRahul Maheshwari Verify Presence of Power Button And Text Info 96*b89977a4SRahul Maheshwari ... ${xpath_select_button_orderly_shutdown} ${string_orderly_shutdown} 97*b89977a4SRahul Maheshwari 98*b89977a4SRahul MaheshwariVerify Immediate Shutdown Button Should Present At Power Running 99*b89977a4SRahul Maheshwari [Documentation] Verify presence of "Immediate shutdown" button. 100*b89977a4SRahul Maheshwari [Tags] Verify_Immediate_Shutdown_Button_Should_Present_At_Power_Running 101*b89977a4SRahul Maheshwari ... OBMC_PowerRunning_State 102*b89977a4SRahul Maheshwari [Setup] Test Setup Execution ${OBMC_PowerRunning_state} 103*b89977a4SRahul Maheshwari 104*b89977a4SRahul Maheshwari Select Server Power Operations Sub Menu 105*b89977a4SRahul Maheshwari Verify Presence of Power Button And Text Info 106*b89977a4SRahul Maheshwari ... ${xpath_select_button_immediate_shutdown} ${string_immediate_shutdown} 107*b89977a4SRahul Maheshwari 108*b89977a4SRahul MaheshwariVerify Warm Reboot Should Not Happen By Clicking No Button 109*b89977a4SRahul Maheshwari [Documentation] Verify functionality of warm reboot "No" button clicking. 110*b89977a4SRahul Maheshwari [Tags] Verify_Warm_Reboot_Should_Not_Happen_By_Clicking_No_Button 111*b89977a4SRahul Maheshwari [Setup] Test Setup Execution ${OBMC_PowerRunning_state} 112*b89977a4SRahul Maheshwari 113*b89977a4SRahul Maheshwari Select Server Power Operations Sub Menu 114*b89977a4SRahul Maheshwari Click Element ${xpath_select_button_warm_reboot} 115*b89977a4SRahul Maheshwari Verify Warning Message Display Text ${xpath_warm_reboot_warning_message} 116*b89977a4SRahul Maheshwari ... ${text_warm_reboot_warning_message} 117*b89977a4SRahul Maheshwari Verify No Button Functionality 118*b89977a4SRahul Maheshwari ... ${xpath_select_button_warm_reboot_no} 119*b89977a4SRahul Maheshwari 120*b89977a4SRahul MaheshwariVerify Cold Reboot Should Not Happen By Clicking No Button 121*b89977a4SRahul Maheshwari [Documentation] Verify functionality of cold reboot "No" button clicking. 122*b89977a4SRahul Maheshwari [Tags] Verify_Cold_Reboot_Should_Not_Happen_By_Clicking_No_Button 123*b89977a4SRahul Maheshwari [Setup] Test Setup Execution ${OBMC_PowerRunning_state} 124*b89977a4SRahul Maheshwari 125*b89977a4SRahul Maheshwari Select Server Power Operations Sub Menu 126*b89977a4SRahul Maheshwari Click Element ${xpath_select_button_cold_reboot} 127*b89977a4SRahul Maheshwari Verify Warning Message Display Text ${xpath_cold_reboot_warning_message} 128*b89977a4SRahul Maheshwari ... ${text_cold_reboot_warning_message} 129*b89977a4SRahul Maheshwari Verify No Button Functionality 130*b89977a4SRahul Maheshwari ... ${xpath_select_button_cold_reboot_no} 131*b89977a4SRahul Maheshwari 132*b89977a4SRahul MaheshwariVerify Orderly Shutdown Should Not Happen By Clicking No Button 133*b89977a4SRahul Maheshwari [Documentation] Verify functionality of orderly shutdown "No" button clicking. 134*b89977a4SRahul Maheshwari [Tags] Verify_Orderly_Shutdown_Should_Not_Happen_By_Clicking_No_Button 135*b89977a4SRahul Maheshwari [Setup] Test Setup Execution ${OBMC_PowerRunning_state} 136*b89977a4SRahul Maheshwari 137*b89977a4SRahul Maheshwari Select Server Power Operations Sub Menu 138*b89977a4SRahul Maheshwari Click Element ${xpath_select_button_orderly_shutdown} 139*b89977a4SRahul Maheshwari Verify Warning Message Display Text ${xpath_orderly_shutdown_warning_message} 140*b89977a4SRahul Maheshwari ... ${text_orderly_shutdown_warning_message} 141*b89977a4SRahul Maheshwari Verify No Button Functionality 142*b89977a4SRahul Maheshwari ... ${xpath_select_button_orderly_shutdown_button_no} 143*b89977a4SRahul Maheshwari 144*b89977a4SRahul MaheshwariVerify Immediate Shutdown Should Not Happen By Clicking No Button 145*b89977a4SRahul Maheshwari [Documentation] Verify functionality of immediate shutdown "No" button clicking. 146*b89977a4SRahul Maheshwari [Tags] Verify_Immediate_Shutdown_Should_Not_Happen_By_Clicking_No_Button 147*b89977a4SRahul Maheshwari [Setup] Test Setup Execution ${OBMC_PowerRunning_state} 148*b89977a4SRahul Maheshwari 149*b89977a4SRahul Maheshwari Select Server Power Operations Sub Menu 150*b89977a4SRahul Maheshwari Click Element ${xpath_select_button_immediate_shutdown} 151*b89977a4SRahul Maheshwari Verify Warning Message Display Text ${xpath_immediate_shutdown_warning_message} 152*b89977a4SRahul Maheshwari ... ${text_immediate_shutdown_warning_message} 153*b89977a4SRahul Maheshwari Verify No Button Functionality 154*b89977a4SRahul Maheshwari ... ${xpath_select_button_immediate_shutdown_no} 155*b89977a4SRahul Maheshwari 156*b89977a4SRahul MaheshwariVerify Warm Reboot Should Happen By Clicking Yes Button 157*b89977a4SRahul Maheshwari [Documentation] Verify functionality of warm reboot "Yes" button clicking. 158*b89977a4SRahul Maheshwari [Tags] Verify_Warm_Reboot_Should_Happen_By_Clicking_Yes_Button 159*b89977a4SRahul Maheshwari [Setup] Test Setup Execution ${OBMC_PowerRunning_state} 160*b89977a4SRahul Maheshwari 161*b89977a4SRahul Maheshwari Select Server Power Operations Sub Menu 162*b89977a4SRahul Maheshwari Warm Reboot openBMC 163*b89977a4SRahul Maheshwari 164*b89977a4SRahul MaheshwariVerify Cold Reboot Should Happen By Clicking Yes Button 165*b89977a4SRahul Maheshwari [Documentation] Verify functionality of cold reboot "Yes" button clicking. 166*b89977a4SRahul Maheshwari [Tags] Verify_Cold_Reboot_Should_Happen_By_Clicking_Yes_Button 167*b89977a4SRahul Maheshwari [Setup] Test Setup Execution ${OBMC_PowerRunning_state} 168*b89977a4SRahul Maheshwari 169*b89977a4SRahul Maheshwari Select Server Power Operations Sub Menu 170*b89977a4SRahul Maheshwari Cold Reboot openBMC 171*b89977a4SRahul Maheshwari 172*b89977a4SRahul MaheshwariVerify Orderly Shutdown Should Happen By Clicking Yes Button 173*b89977a4SRahul Maheshwari [Documentation] Verify functionality of orderly shutdown "Yes" button clicking. 174*b89977a4SRahul Maheshwari [Tags] Verify_Orderly_Shutdown_Should_Happen_By_Clicking_Yes_Button 175*b89977a4SRahul Maheshwari ... OBMC_PowerRunning_State 176*b89977a4SRahul Maheshwari [Setup] Test Setup Execution ${OBMC_PowerRunning_state} 177*b89977a4SRahul Maheshwari 178*b89977a4SRahul Maheshwari Select Server Power Operations Sub Menu 179*b89977a4SRahul Maheshwari Orderly Shutdown OpenBMC 180*b89977a4SRahul Maheshwari 181*b89977a4SRahul MaheshwariVerify Immediate Shutdown Should Happen By Clicking Yes Button 182*b89977a4SRahul Maheshwari [Documentation] Verify functionality of immediate shutdown "Yes" button clicking. 183*b89977a4SRahul Maheshwari [Tags] Verify_Immediate_Shutdown_Should_Happen_By_Clicking_Yes_Button 184*b89977a4SRahul Maheshwari ... OBMC_PowerRunning_State 185*b89977a4SRahul Maheshwari [Setup] Test Setup Execution ${OBMC_PowerRunning_state} 186*b89977a4SRahul Maheshwari 187*b89977a4SRahul Maheshwari Select Server Power Operations Sub Menu 188*b89977a4SRahul Maheshwari Immediate Shutdown openBMC 189*b89977a4SRahul Maheshwari 190*b89977a4SRahul Maheshwari*** Keywords *** 191*b89977a4SRahul MaheshwariSelect Server Power Operations Sub Menu 192*b89977a4SRahul Maheshwari [Documentation] Selecting of OpenBMC "Server Power Operations" Submenu. 193*b89977a4SRahul Maheshwari 194*b89977a4SRahul Maheshwari Click Button ${xpath_select_server_control} 195*b89977a4SRahul Maheshwari Click Button ${xpath_select_server_power_operations} 196*b89977a4SRahul Maheshwari 197*b89977a4SRahul MaheshwariVerify Presence of Power Button And Text Info 198*b89977a4SRahul Maheshwari [Documentation] Verify the presens fo power button and text message info. 199*b89977a4SRahul Maheshwari [Arguments] ${power_button} ${power_button_text} 200*b89977a4SRahul Maheshwari 201*b89977a4SRahul Maheshwari # power_button Xpath of power button. 202*b89977a4SRahul Maheshwari # power_button_text Text message info. 203*b89977a4SRahul Maheshwari 204*b89977a4SRahul Maheshwari Page Should Contain Button ${power_button} 205*b89977a4SRahul Maheshwari Verify Display Content ${power_button_text} 206*b89977a4SRahul Maheshwari 207*b89977a4SRahul MaheshwariVerify No Button Functionality 208*b89977a4SRahul Maheshwari [Documentation] Verify the functionality of "No" button click. 209*b89977a4SRahul Maheshwari [Arguments] ${xpath_no_button} 210*b89977a4SRahul Maheshwari 211*b89977a4SRahul Maheshwari # xpath_no_button Xpath of "No" button. 212*b89977a4SRahul Maheshwari 213*b89977a4SRahul Maheshwari Click No Button ${xpath_no_button} 214*b89977a4SRahul Maheshwari ${obmc_current_state}= Get Text ${xpath_display_server_power_status} 215*b89977a4SRahul Maheshwari Should Contain ${obmc_current_state} ${obmc_running_state} 216