George Keishing | a47c5d3 | 2017-01-09 09:03:17 -0600 | [diff] [blame] | 1 | *** Settings *** |
| 2 | Documentation Set metadata for test suite. |
| 3 | |
| 4 | Library SSHLibrary |
| 5 | Resource ../lib/connection_client.robot |
| 6 | Resource ../lib/rest_client.robot |
George Keishing | 847a7bf | 2017-02-09 11:39:47 -0600 | [diff] [blame] | 7 | Resource ../lib/utils.robot |
Sweta Potthuri | cd96634 | 2017-09-06 03:41:32 -0500 | [diff] [blame] | 8 | Resource ../lib/code_update_utils.robot |
George Keishing | a47c5d3 | 2017-01-09 09:03:17 -0600 | [diff] [blame] | 9 | |
| 10 | Suite Setup System Driver Data |
| 11 | |
| 12 | *** Variables *** |
| 13 | |
| 14 | ${DRIVER_CMD} cat /etc/os-release | grep ^VERSION_ID= |
| 15 | |
| 16 | *** Keyword *** |
| 17 | |
| 18 | System Driver Data |
George Keishing | fb76203 | 2017-11-14 11:18:21 -0600 | [diff] [blame] | 19 | [Documentation] System driver information and enable defaults settings. |
Vijay | 1a52c99 | 2017-09-19 08:37:26 -0500 | [diff] [blame] | 20 | Run Keyword And Ignore Error Clear System Entry From Knownhosts |
Charles Paul Hofer | dcf0c96 | 2018-04-24 10:29:55 -0500 | [diff] [blame] | 21 | Wait Until Keyword Succeeds 2 min 30 sec Open Connection And Log In |
George Keishing | 847a7bf | 2017-02-09 11:39:47 -0600 | [diff] [blame] | 22 | Run Keyword And Ignore Error Log BMC Driver Details |
| 23 | Run Keyword And Ignore Error Log PNOR Driver Details |
| 24 | Run Keyword And Ignore Error Log BMC Model |
George Keishing | 7a52022 | 2017-02-27 09:44:30 -0600 | [diff] [blame] | 25 | Run Keyword And Ignore Error Enable Core Dump On BMC |
George Keishing | dd91749 | 2020-06-16 03:29:38 -0500 | [diff] [blame^] | 26 | |
| 27 | Run Keyword If ${REDFISH_SUPPORTED} |
| 28 | ... Redfish Default |
| 29 | ... ELSE |
| 30 | ... REST Default |
| 31 | |
| 32 | REST Default |
| 33 | [Documentation] Set REST defaults. |
| 34 | |
George Keishing | ef74a8c | 2017-10-20 10:23:52 -0500 | [diff] [blame] | 35 | Run Keyword And Ignore Error Set Boot Defaults |
Charles Paul Hofer | c002d83 | 2018-05-30 13:08:07 -0500 | [diff] [blame] | 36 | Run Keyword And Ignore Error Set BMC Power Policy ${ALWAYS_POWER_OFF} |
George Keishing | 3e28ea3 | 2017-12-19 03:13:52 -0600 | [diff] [blame] | 37 | Run Keyword If ${FIELD_MODE} == ${True} |
| 38 | ... Enable Field Mode And Verify Unmount |
George Keishing | 201d826 | 2017-12-19 09:12:25 -0600 | [diff] [blame] | 39 | Run Keyword And Ignore Error Clear BMC Gard Record |
George Keishing | ef74a8c | 2017-10-20 10:23:52 -0500 | [diff] [blame] | 40 | |
George Keishing | dd91749 | 2020-06-16 03:29:38 -0500 | [diff] [blame^] | 41 | |
| 42 | Redfish Default |
| 43 | [Documentation] Set REST defaults. |
| 44 | |
| 45 | Redfish.Login |
| 46 | Run Keyword And Ignore Error Redfish Set Power Restore Policy AlwaysOff |
| 47 | Redfish.Logout |
| 48 | |
| 49 | |
George Keishing | ef74a8c | 2017-10-20 10:23:52 -0500 | [diff] [blame] | 50 | Set Boot Defaults |
Joy Onyerikwu | f4a807b | 2018-06-20 08:43:54 -0500 | [diff] [blame] | 51 | [Documentation] Set boot defaults. |
George Keishing | ef74a8c | 2017-10-20 10:23:52 -0500 | [diff] [blame] | 52 | Set Control Boot Mode ${CONTROL_HOST_URI}/boot ${BOOT_MODE_REGULAR} |
| 53 | Set Control Boot Mode |
| 54 | ... ${CONTROL_HOST_URI}/boot/one_time ${BOOT_MODE_REGULAR} |
George Keishing | a47c5d3 | 2017-01-09 09:03:17 -0600 | [diff] [blame] | 55 | |
George Keishing | 847a7bf | 2017-02-09 11:39:47 -0600 | [diff] [blame] | 56 | Log BMC Driver Details |
George Keishing | a47c5d3 | 2017-01-09 09:03:17 -0600 | [diff] [blame] | 57 | [Documentation] Get BMC driver details and log. |
| 58 | |
George Keishing | a47c5d3 | 2017-01-09 09:03:17 -0600 | [diff] [blame] | 59 | ${output} ${stderr}= Execute Command ${DRIVER_CMD} |
| 60 | ... return_stderr=True |
| 61 | Should Be Empty ${stderr} |
| 62 | Log ${output} |
| 63 | [Return] ${output} |
| 64 | |
George Keishing | 847a7bf | 2017-02-09 11:39:47 -0600 | [diff] [blame] | 65 | Log PNOR Driver Details |
George Keishing | a47c5d3 | 2017-01-09 09:03:17 -0600 | [diff] [blame] | 66 | [Documentation] Get PNOR driver details and log. |
George Keishing | 90ab177 | 2017-02-24 05:40:55 -0600 | [diff] [blame] | 67 | # Until the new REST interface is available using pflash to |
| 68 | # capture the PNOR details. |
Sweta Potthuri | cd96634 | 2017-09-06 03:41:32 -0500 | [diff] [blame] | 69 | ${software}= Get Host Software Objects Details |
| 70 | Log ${software} |
George Keishing | 847a7bf | 2017-02-09 11:39:47 -0600 | [diff] [blame] | 71 | |
| 72 | Log BMC Model |
| 73 | [Documentation] Fetch BMC Model name from system and log. |
| 74 | ${bmc_model}= Get BMC System Model |
| 75 | Log BMC Model=${bmc_model} |