George Keishing | eefc07a | 2016-07-26 03:25:35 -0500 | [diff] [blame] | 1 | *** Settings *** |
George Keishing | 0a46d02 | 2017-01-30 08:11:43 -0600 | [diff] [blame] | 2 | Documentation Test power on for HW CI. |
George Keishing | eefc07a | 2016-07-26 03:25:35 -0500 | [diff] [blame] | 3 | |
George Keishing | d55a4be | 2016-08-26 03:28:17 -0500 | [diff] [blame] | 4 | Resource ../lib/openbmc_ffdc.robot |
George Keishing | 97e9653 | 2016-10-06 12:44:52 -0500 | [diff] [blame] | 5 | Resource ../lib/utils.robot |
George Keishing | 0a46d02 | 2017-01-30 08:11:43 -0600 | [diff] [blame] | 6 | Resource ../lib/state_manager.robot |
George Keishing | 766c623 | 2018-02-02 11:42:55 -0600 | [diff] [blame] | 7 | Resource ../lib/open_power_utils.robot |
George Keishing | 97e9653 | 2016-10-06 12:44:52 -0500 | [diff] [blame] | 8 | |
George Keishing | fcc6d78 | 2018-01-24 00:44:03 -0600 | [diff] [blame] | 9 | Test Setup Test Setup Execution |
George Keishing | 2f0f4b3 | 2018-01-21 23:25:47 -0600 | [diff] [blame] | 10 | Test Teardown Test Teardown Execution |
George Keishing | 83ada4f | 2016-08-09 03:15:08 -0500 | [diff] [blame] | 11 | |
causten | 147f575 | 2016-08-11 16:24:45 -0500 | [diff] [blame] | 12 | Force Tags chassisboot |
George Keishing | eefc07a | 2016-07-26 03:25:35 -0500 | [diff] [blame] | 13 | |
George Keishing | 0af2441 | 2017-03-10 13:33:23 -0600 | [diff] [blame] | 14 | *** Variables *** |
| 15 | |
| 16 | # User may pass LOOP_COUNT. |
| 17 | # By default 2 cycle for CI/CT. |
| 18 | ${LOOP_COUNT} ${2} |
| 19 | |
George Keishing | 32ed412 | 2017-05-13 03:06:39 -0500 | [diff] [blame] | 20 | # Error strings to check from journald. |
| 21 | ${ERROR_REGEX} SEGV|core-dump |
| 22 | |
Gunnar Mills | 7c8923f | 2016-12-12 21:19:52 -0600 | [diff] [blame] | 23 | *** Test Cases *** |
George Keishing | eefc07a | 2016-07-26 03:25:35 -0500 | [diff] [blame] | 24 | |
George Keishing | 0a46d02 | 2017-01-30 08:11:43 -0600 | [diff] [blame] | 25 | Power On Test |
| 26 | [Documentation] Power off and on. |
| 27 | [Tags] Power_On_Test |
George Keishing | eefc07a | 2016-07-26 03:25:35 -0500 | [diff] [blame] | 28 | |
George Keishing | 0af2441 | 2017-03-10 13:33:23 -0600 | [diff] [blame] | 29 | Repeat Keyword ${LOOP_COUNT} times Host Off And On |
George Keishing | 97e9653 | 2016-10-06 12:44:52 -0500 | [diff] [blame] | 30 | |
George Keishing | 32ed412 | 2017-05-13 03:06:39 -0500 | [diff] [blame] | 31 | Check For Application Failures |
| 32 | [Documentation] Parse the journal log and check for failures. |
| 33 | [Tags] Check_For_Application_Failures |
| 34 | |
| 35 | Open Connection And Log In |
| 36 | |
| 37 | ${journal_log}= Execute Command On BMC |
| 38 | ... journalctl --no-pager | egrep '${ERROR_REGEX}' |
| 39 | |
| 40 | Should Be Empty ${journal_log} |
| 41 | |
George Keishing | 97e9653 | 2016-10-06 12:44:52 -0500 | [diff] [blame] | 42 | *** Keywords *** |
George Keishing | 0a46d02 | 2017-01-30 08:11:43 -0600 | [diff] [blame] | 43 | |
George Keishing | fcc6d78 | 2018-01-24 00:44:03 -0600 | [diff] [blame] | 44 | Test Setup Execution |
| 45 | [Documentation] Do test case setup tasks. |
| 46 | Start SOL Console Logging |
| 47 | Set Auto Reboot ${0} |
| 48 | |
George Keishing | 2f0f4b3 | 2018-01-21 23:25:47 -0600 | [diff] [blame] | 49 | Test Teardown Execution |
George Keishing | 0a46d02 | 2017-01-30 08:11:43 -0600 | [diff] [blame] | 50 | [Documentation] Collect FFDC and SOL log. |
Gunnar Mills | eac1af2 | 2016-11-14 15:30:09 -0600 | [diff] [blame] | 51 | FFDC On Test Case Fail |
George Keishing | 97e9653 | 2016-10-06 12:44:52 -0500 | [diff] [blame] | 52 | ${sol_log}= Stop SOL Console Logging |
| 53 | Log ${sol_log} |
George Keishing | 2f0f4b3 | 2018-01-21 23:25:47 -0600 | [diff] [blame] | 54 | Set Auto Reboot ${1} |
George Keishing | 0af2441 | 2017-03-10 13:33:23 -0600 | [diff] [blame] | 55 | |
| 56 | Host Off And On |
| 57 | [Documentation] Verify power off and on. |
| 58 | |
| 59 | Initiate Host PowerOff |
George Keishing | 0af2441 | 2017-03-10 13:33:23 -0600 | [diff] [blame] | 60 | |
| 61 | Initiate Host Boot |
George Keishing | 766c623 | 2018-02-02 11:42:55 -0600 | [diff] [blame] | 62 | Verify OCC State |
George Keishing | 383d29b | 2017-03-25 11:10:52 -0500 | [diff] [blame] | 63 | |
George Keishing | 5f2f7f5 | 2017-06-30 09:17:53 -0500 | [diff] [blame] | 64 | # TODO: Host shutdown race condition. |
| 65 | # Wait 30 seconds before Powering Off. |
| 66 | Sleep 30s |