blob: 428bf11da146c1c20bbf586952b367346f7610fc [file] [log] [blame]
George Keishing8b082fd2017-05-03 13:42:39 -05001*** Settings ***
2Documentation Stress the system using HTX exerciser.
3
4Resource ../syslib/utils_os.robot
George Keishingffbe8ce2017-05-04 12:08:54 -05005
George Keishingae5d9782017-06-12 13:35:59 -05006Suite Setup Run Key Start SOL Console Logging
George Keishingffbe8ce2017-05-04 12:08:54 -05007Test Setup Pre Test Case Execution
8Test Teardown Post Test Case Execution
George Keishing8b082fd2017-05-03 13:42:39 -05009
10*** Variables ****
11
George Keishingffbe8ce2017-05-04 12:08:54 -050012${stack_mode} skip
13
George Keishing8b082fd2017-05-03 13:42:39 -050014*** Test Cases ***
15
16Hard Bootme Test
17 [Documentation] Stress the system using HTX exerciser.
George Keishingffbe8ce2017-05-04 12:08:54 -050018 [Tags] Hard_Bootme_Test
George Keishing8b082fd2017-05-03 13:42:39 -050019
George Keishingffbe8ce2017-05-04 12:08:54 -050020 Rprintn
21 Rpvars HTX_DURATION HTX_INTERVAL
22
23 Repeat Keyword ${HTX_LOOP} times Start HTX Exerciser
24
25
26*** Keywords ***
27
28Start HTX Exerciser
29 [Documentation] Start HTX exerciser.
30 # Test Flow:
31 # - Power on
32 # - Establish SSH connection session
33 # - Create HTX mdt profile
34 # - Run HTX exerciser
35 # - Check HTX status for errors
36 # - Power off
37
38 Boot To OS
39
40 # Post Power off and on, the OS SSH session needs to be established.
George Keishing8b082fd2017-05-03 13:42:39 -050041 Login To OS
42
George Keishing13f44e52017-05-12 15:28:12 -050043 Run Keyword If '${HTX_MDT_PROFILE}' == 'mdt.bu'
44 ... Create Default MDT Profile
George Keishing8b082fd2017-05-03 13:42:39 -050045
George Keishing13f44e52017-05-12 15:28:12 -050046 Run MDT Profile
George Keishing8b082fd2017-05-03 13:42:39 -050047
48 Loop HTX Health Check
49
George Keishingffbe8ce2017-05-04 12:08:54 -050050 Shutdown HTX Exerciser
51
52 Power Off Host
53
George Keishingae5d9782017-06-12 13:35:59 -050054 # Close all SSH and REST active sessions.
55 Close All Connections
56 Flush REST Sessions
57
George Keishingffbe8ce2017-05-04 12:08:54 -050058 Rprint Timen HTX Test ran for: ${HTX_DURATION}
George Keishing8b082fd2017-05-03 13:42:39 -050059
George Keishing13f44e52017-05-12 15:28:12 -050060
George Keishing8b082fd2017-05-03 13:42:39 -050061Loop HTX Health Check
George Keishingffbe8ce2017-05-04 12:08:54 -050062 [Documentation] Run until HTX exerciser fails.
63
George Keishing8b082fd2017-05-03 13:42:39 -050064 Repeat Keyword ${HTX_DURATION}
65 ... Run Keywords Check HTX Run Status
66 ... AND Sleep ${HTX_INTERVAL}
67
68
George Keishingffbe8ce2017-05-04 12:08:54 -050069Post Test Case Execution
70 [Documentation] Do the post test teardown.
71 # 1. Shut down HTX exerciser if test Failed.
72 # 2. Capture FFDC on test failure.
73 # 3. Close all open SSH connections.
74
George Keishing1a23b692017-05-06 12:19:41 -050075 # Keep HTX running if user set HTX_KEEP_RUNNING to 1.
76 Run Keyword If '${TEST_STATUS}' == 'FAIL' and ${HTX_KEEP_RUNNING} == ${0}
George Keishingffbe8ce2017-05-04 12:08:54 -050077 ... Shutdown HTX Exerciser
78
George Keishingae5d9782017-06-12 13:35:59 -050079 ${keyword_buf}= Catenate Stop SOL Console Logging
80 ... \ targ_file_path=${EXECDIR}${/}logs${/}SOL.log
81 Run Key ${keyword_buf}
82
George Keishingffbe8ce2017-05-04 12:08:54 -050083 FFDC On Test Case Fail
84 Close All Connections