HW_CI: Param to capture SOL logging
Changes:
- By default capturing SOL logging is disabled.
- Added capture_sol param to enable or disable during test
suite run.
Tested: with -v capture_sol:0
with -v capture_sol:1
option for the test suite test_power_operations.robot
Change-Id: Idee840eea18a150677fa94a19c2cfbbecf653680
Signed-off-by: George Keishing <gkeishin@in.ibm.com>
diff --git a/redfish/systems/test_power_operations.robot b/redfish/systems/test_power_operations.robot
index 928d59c..c415d36 100644
--- a/redfish/systems/test_power_operations.robot
+++ b/redfish/systems/test_power_operations.robot
@@ -14,6 +14,9 @@
${additional_power_check} ${1}
${additional_occ_check} ${1}
+# By default disable SOL logging collection.
+${capture_sol} ${0}
+
*** Test Cases ***
Verify Redfish Host GracefulShutdown
@@ -64,7 +67,7 @@
[Documentation] Do test case setup tasks.
Printn
- Start SOL Console Logging
+ Run Keyword If ${capture_sol} == ${1} Start SOL Console Logging
Redfish.Login
@@ -72,8 +75,7 @@
[Documentation] Collect FFDC and SOL log.
FFDC On Test Case Fail
- ${sol_log}= Stop SOL Console Logging
- Log ${sol_log}
+ Run Keyword If ${capture_sol} == ${1} Stop SOL Capture
Run Keyword If ${REDFISH_SUPPORTED}
... Redfish Set Auto Reboot RetryAttempts
@@ -82,6 +84,13 @@
Redfish.Logout
+Stop SOL Capture
+ [Documentation] Stop SOL log collection.
+
+ ${sol_log}= Stop SOL Console Logging
+ Log ${sol_log}
+
+
Power Check
[Documentation] Verify PowerConsumedWatts property.