blob: 42611d0df716a3772e8dfc0ca8d02606f7f1c1f9 [file] [log] [blame]
George Keishing92abc992016-10-18 13:29:25 -05001*** Settings ***
2Documentation Power cycle loop. This is to test where network service
3... becomes unavailable during AC-Cycle stress test.
4
5Resource ../lib/rest_client.robot
6Resource ../lib/pdu/pdu.robot
7Resource ../lib/utils.robot
8Resource ../lib/openbmc_ffdc.robot
George Keishingca709b02017-02-02 11:38:19 -06009Resource ../lib/state_manager.robot
George Keishingbf1500d2017-10-30 12:47:47 -050010Resource ../lib/boot_utils.robot
George Keishingc26e74d2017-11-17 00:45:20 -060011Resource ../lib/code_update_utils.robot
George Keishing92abc992016-10-18 13:29:25 -050012
George Keishing94659a22017-11-17 00:03:05 -060013Test Teardown Test Teardown Execution
George Keishingc26e74d2017-11-17 00:45:20 -060014Suite Setup Suite Setup Execution
George Keishing92abc992016-10-18 13:29:25 -050015
16*** Variables ***
17${LOOP_COUNT} ${50}
18
19*** Test Cases ***
20
George Keishingca709b02017-02-02 11:38:19 -060021Run Multiple Power Cycle
22 [Documentation] Execute multiple power cycles.
23 [Setup] Validate Parameters
24 [Tags] Run_Multiple_Power_Cycle
George Keishing92abc992016-10-18 13:29:25 -050025
George Keishingca709b02017-02-02 11:38:19 -060026 # By default run test for 50 loops, else user input iteration.
27 # Fails immediately if any of the execution rounds fail and
28 # check if BMC is still pinging and FFDC is collected.
29 Repeat Keyword ${LOOP_COUNT} times Power Cycle System Via PDU
30
31
George Keishingbf1500d2017-10-30 12:47:47 -050032Run Multiple BMC Reset Via REST
33 [Documentation] Execute multiple reboots via REST.
34 [Tags] Run_Multiple_BMC_Reset_Via_REST
35
36 # By default run test for 50 loops, else user input iteration.
37 # Fails immediately if any of the execution rounds fail and
38 # check if BMC is still pinging and FFDC is collected.
39 Repeat Keyword ${LOOP_COUNT} times BMC REST Reset Cycle
40
41
42Run Multiple BMC Reset Via Reboot
43 [Documentation] Execute multiple reboots via "reboot" command.
44 [Tags] Run_Multiple_BMC_Reset_Via_Reboot
George Keishingca709b02017-02-02 11:38:19 -060045
46 # By default run test for 50 loops, else user input iteration.
47 # Fails immediately if any of the execution rounds fail and
48 # check if BMC is still pinging and FFDC is collected.
49 Repeat Keyword ${LOOP_COUNT} times BMC Reboot Cycle
George Keishing92abc992016-10-18 13:29:25 -050050
51
52*** Keywords ***
53
George Keishingca709b02017-02-02 11:38:19 -060054Power Cycle System Via PDU
55 [Documentation] Power cycle system and wait for BMC to reach Ready state.
56 Log "Doing power cycle"
George Keishing92abc992016-10-18 13:29:25 -050057 PDU Power Cycle
George Keishingca709b02017-02-02 11:38:19 -060058 Check If BMC Is Up 5 min 10 sec
George Keishing92abc992016-10-18 13:29:25 -050059
George Keishingca709b02017-02-02 11:38:19 -060060 Wait Until Keyword Succeeds 10 min 10 sec Is BMC Ready
George Keishingb39a6792017-11-10 22:58:52 -060061 Verify BMC RTC And UTC Time Drift
George Keishingc26e74d2017-11-17 00:45:20 -060062 Field Mode Should Be Enabled
George Keishingca709b02017-02-02 11:38:19 -060063
64
George Keishingbf1500d2017-10-30 12:47:47 -050065BMC REST Reset Cycle
66 [Documentation] Reset BMC via REST and wait for ready state.
George Keishingca709b02017-02-02 11:38:19 -060067 Log "Doing Reboot cycle"
George Keishing137882c2017-10-28 09:19:05 -050068 ${bmc_version_before}= Get BMC Version
George Keishingca709b02017-02-02 11:38:19 -060069 Initiate BMC Reboot
70 Wait Until Keyword Succeeds 10 min 10 sec Is BMC Ready
George Keishing137882c2017-10-28 09:19:05 -050071 ${bmc_version_after}= Get BMC Version
72 Should Be Equal ${bmc_version_before} ${bmc_version_after}
George Keishingb39a6792017-11-10 22:58:52 -060073 Verify BMC RTC And UTC Time Drift
George Keishingc26e74d2017-11-17 00:45:20 -060074 Field Mode Should Be Enabled
George Keishing92abc992016-10-18 13:29:25 -050075
76
George Keishingbf1500d2017-10-30 12:47:47 -050077BMC Reboot Cycle
78 [Documentation] Reboot BMC and wait for ready state.
79 Log "Doing Reboot cycle"
80 ${bmc_version_before}= Get BMC Version
81 OBMC Reboot (off) stack_mode=normal
82 ${bmc_version_after}= Get BMC Version
83 Should Be Equal ${bmc_version_before} ${bmc_version_after}
George Keishingb39a6792017-11-10 22:58:52 -060084 Verify BMC RTC And UTC Time Drift
George Keishingc26e74d2017-11-17 00:45:20 -060085 Field Mode Should Be Enabled
George Keishingbf1500d2017-10-30 12:47:47 -050086
87
George Keishing94659a22017-11-17 00:03:05 -060088Test Teardown Execution
89 [Documentation] Do test case tear-down.
George Keishing92abc992016-10-18 13:29:25 -050090 Ping Host ${OPENBMC_HOST}
Gunnar Millseac1af22016-11-14 15:30:09 -060091 FFDC On Test Case Fail
George Keishing92abc992016-10-18 13:29:25 -050092
93
94Validate Parameters
George Keishing94659a22017-11-17 00:03:05 -060095 [Documentation] Validate PDU parameters.
George Keishing92abc992016-10-18 13:29:25 -050096 Should Not Be Empty ${PDU_IP}
97 Should Not Be Empty ${PDU_TYPE}
98 Should Not Be Empty ${PDU_SLOT_NO}
99 Should Not Be Empty ${PDU_USERNAME}
100 Should Not Be Empty ${PDU_PASSWORD}
101
George Keishingc26e74d2017-11-17 00:45:20 -0600102
103Suite Setup Execution
104 [Documentation] Enable field mode.
105 Enable Field Mode And Verify Unmount
106 Field Mode Should Be Enabled