root | 442f0ef | 2016-08-04 20:23:05 +0000 | [diff] [blame] | 1 | *** Settings *** |
| 2 | Documentation Contains all of the keywords that do various power ons. |
| 3 | |
| 4 | Resource ../resource.txt |
| 5 | Resource ../utils.robot |
| 6 | Resource ../connection_client.robot |
| 7 | |
| 8 | *** Keywords *** |
| 9 | BMC Power On |
| 10 | [Documentation] Powers on the system, checks that the OS is functional, and |
| 11 | ... makes sure that all states are powered on. |
| 12 | |
| 13 | &{bmc_connection_args}= Create Dictionary alias=bmc_connection |
| 14 | |
| 15 | Open Connection and Log In &{bmc_connection_args} |
| 16 | Initiate Power On |
George Keishing | 8a84f95 | 2016-08-25 04:54:53 -0500 | [diff] [blame] | 17 | Run Keyword If '${OS_HOST}' != '${EMPTY}' Wait For OS |
root | 442f0ef | 2016-08-04 20:23:05 +0000 | [diff] [blame] | 18 | Switch Connection bmc_connection |
| 19 | Check Power On States |
| 20 | Close Connection |
| 21 | |
| 22 | Check Power On States |
| 23 | [Documentation] Checks that the BMC state, power state, and boot progress |
| 24 | ... are correctly powered on. |
| 25 | |
George Keishing | 8a84f95 | 2016-08-25 04:54:53 -0500 | [diff] [blame] | 26 | Wait Until Keyword Succeeds ${OS_WAIT_TIMEOUT} 10sec Is Host Booted |
root | 442f0ef | 2016-08-04 20:23:05 +0000 | [diff] [blame] | 27 | |
| 28 | ${boot_progress}= Get Boot Progress |
| 29 | Should Be Equal ${boot_progress} FW Progress, Starting OS |
| 30 | Log to Console Boot Progress: ${boot_progress} |
| 31 | |
| 32 | ${power_state}= Get Power State |
| 33 | Should Be Equal ${power_state} ${1} |
| 34 | Log to Console Power State: ${power_state} |
George Keishing | 8a84f95 | 2016-08-25 04:54:53 -0500 | [diff] [blame] | 35 | |
| 36 | Is Host Booted |
| 37 | ${bmc_state}= Get BMC State |
| 38 | Should Contain ${bmc_state} HOST_BOOTED |
| 39 | Log to Console BMC State: ${bmc_state} |
| 40 | |