blob: ce5c0a2b3f30519db86cf1bf416e72c6beae1f4a [file] [log] [blame]
George Keishing3e840a52017-07-21 08:31:44 -05001*** Settings ***
2Documentation BMC error polling test to check errors every 10 seconds.
3
4Resource ../lib/rest_client.robot
5Resource ../lib/openbmc_ffdc.robot
6Resource ../lib/resource.txt
7Resource ../lib/boot_utils.robot
8
Steven Sombar0278b132018-01-09 14:41:32 -06009Suite Setup Suite Setup Execution
George Keishing3e840a52017-07-21 08:31:44 -050010Test Teardown Post Test Case Execution
11
12*** Variables ***
13
14# Default duration and interval of test to run.
15${POLL_DURATION} 48 hours
16${POLL_INTERVAL} 10 second
17
18*** Test Cases ***
19
20Poll BMC For Errors
21 [Documentation] Poll BMC for errors.
22 ... exist.
23 [Tags] Poll_BMC_For_Errors
24
25 Repeat Keyword ${POLL_DURATION}
26 ... Run Keywords Enumerate Sensors And Check For Errors
27 ... AND Sleep ${POLL_INTERVAL}
28
29*** Keywords ***
30
31Enumerate Sensors And Check For Errors
32 [Documentation] Enumerate and check if there is any error reported.
33
34 ${resp}= OpenBMC Get Request /xyz/openbmc_project/sensors/
35 Should Be Equal As Strings ${resp.status_code} ${HTTP_OK}
36
37 Error Logs Should Not Exist
38
39
Steven Sombar0278b132018-01-09 14:41:32 -060040Suite Setup Execution
George Keishing3e840a52017-07-21 08:31:44 -050041 [Documentation] Do test setup initialization.
42
43 Should Not Be Empty
44 ... ${OS_HOST} msg=You must provide hostname or IP of the OS host.
45 Should Not Be Empty
46 ... ${OS_USERNAME} msg=You must provide OS host user name.
47 Should Not Be Empty
48 ... ${OS_PASSWORD} msg=You must provide OS host user password.
49
50 # Boot to OS.
51 REST Power On
52
53 Delete Error Logs
54 Error Logs Should Not Exist
55
56Post Test Case Execution
57 [Documentation] Do the post test teardown.
58 ... 1. Capture FFDC on test failure.
59
60 FFDC On Test Case Fail