Verify front and rear LED is off at standby
Changes:
- Move keyword "Verify Identify LED State" from IPMI to utils.
- Add test for checking LED at standby
- Add tags for HW_CI and CT_basic_run
Resolves openbmc/openbmc-test-automation#1314
Change-Id: I56df13ce3ff3b08f988946e04d331cfd98b41cfd
Signed-off-by: George Keishing <gkeishin@in.ibm.com>
diff --git a/lib/utils.robot b/lib/utils.robot
index b861b3c..91729e2 100755
--- a/lib/utils.robot
+++ b/lib/utils.robot
@@ -1593,3 +1593,23 @@
Run Keyword If '${DEBUG_TARBALL_PATH}' == '${EMPTY}' Return From Keyword
BMC Execute Command rm -rf /tmp/tarball
Install Debug Tarball On BMC ${DEBUG_TARBALL_PATH}
+
+
+Verify Identify LED State
+ [Documentation] Verify the identify LED state
+ ... matches caller's expectations.
+ [Arguments] ${expected_state}
+
+ # Description of argument(s):
+ # expected_state The LED state expected by the caller ("Blink" or "Off").
+
+ ${resp}= Read Attribute ${LED_PHYSICAL_URI}/front_id State
+ Should Be Equal ${resp}
+ ... xyz.openbmc_project.Led.Physical.Action.${expected_state}
+ ... msg=Unexpected LED state.
+
+ ${resp}= Read Attribute ${LED_PHYSICAL_URI}/rear_id State
+ Should Be Equal ${resp}
+ ... xyz.openbmc_project.Led.Physical.Action.${expected_state}
+ ... msg=Unexpected LED state.
+
diff --git a/test_lists/CT_basic_run b/test_lists/CT_basic_run
index ddaf325..895f32b 100644
--- a/test_lists/CT_basic_run
+++ b/test_lists/CT_basic_run
@@ -8,6 +8,7 @@
-i BMC_Software_Activation_Association
-i Host_Software_Activation_Association
#Basic poweron test via REST
+-i Verify_Front_And_Rear_LED_At_Standby
-i Power_On_Test
# Check for apps failures
-i Check_For_Application_Failures
diff --git a/test_lists/HW_CI b/test_lists/HW_CI
index de55abf..0334819 100644
--- a/test_lists/HW_CI
+++ b/test_lists/HW_CI
@@ -3,6 +3,7 @@
#REST SSL connection test.
-i Test_SSL_Connection
#Basic poweron test
+-i Verify_Front_And_Rear_LED_At_Standby
-i Power_On_Test
#Check for apps failures.
-i Check_For_Application_Failures
diff --git a/tests/ipmi/test_general_ipmi.robot b/tests/ipmi/test_general_ipmi.robot
index bc26247..e76ca01 100644
--- a/tests/ipmi/test_general_ipmi.robot
+++ b/tests/ipmi/test_general_ipmi.robot
@@ -4,8 +4,9 @@
Resource ../../lib/ipmi_client.robot
Resource ../../lib/openbmc_ffdc.robot
Resource ../../lib/boot_utils.robot
-Library ../../lib/ipmi_utils.py
+Resource ../../lib/utils.robot
Resource ../../lib/bmc_network_utils.robot
+Library ../../lib/ipmi_utils.py
Variables ../../data/ipmi_raw_cmd_table.py
Test Teardown FFDC On Test Case Fail
@@ -556,23 +557,6 @@
... msg=Command failed: get_mc_id.
-Verify Identify LED State
- [Documentation] Verify the identify LED state
- ... matches caller's expectations.
- [Arguments] ${expected_state}
-
- # Description of argument(s):
- # expected_state The LED state expected by the caller ("Blink" or "Off").
-
- ${resp}= Read Attribute ${LED_PHYSICAL_URI}/front_id State
- Should Be Equal ${resp} xyz.openbmc_project.Led.Physical.Action.${expected_state}
- ... msg=Unexpected LED state.
-
- ${resp}= Read Attribute ${LED_PHYSICAL_URI}/rear_id State
- Should Be Equal ${resp} xyz.openbmc_project.Led.Physical.Action.${expected_state}
- ... msg=Unexpected LED state.
-
-
Set Watchdog Enabled Using REST
[Documentation] Set watchdog Enabled field using REST.
[Arguments] ${value}
diff --git a/tests/test_basic_poweron.robot b/tests/test_basic_poweron.robot
index 0384ba1..64f9d0d 100644
--- a/tests/test_basic_poweron.robot
+++ b/tests/test_basic_poweron.robot
@@ -6,6 +6,7 @@
Resource ../lib/state_manager.robot
Resource ../lib/open_power_utils.robot
Resource ../lib/ipmi_client.robot
+Resource ../lib/boot_utils.robot
Test Setup Test Setup Execution
Test Teardown Test Teardown Execution
@@ -23,6 +24,13 @@
*** Test Cases ***
+Verify Front And Rear LED At Standby
+ [Documentation] Front and Rear LED should be off at standby.
+ [Tags] Verify_Front_And_Rear_LED_At_Standby
+
+ REST Power Off stack_mode=skip quiet=1
+ Verify Identify LED State Off
+
Power On Test
[Documentation] Power off and on.
[Tags] Power_On_Test