blob: d5f530326f1b68436ae8d310a93f9ca2d1932c9f [file] [log] [blame]
Prashanth Katti26f91752021-04-08 09:23:17 -05001*** Settings ***
2
3Documentation Test Redfish session and its connection stability.
4
Prashanth Katti26f91752021-04-08 09:23:17 -05005Resource ../../lib/bmc_redfish_utils.robot
6Resource ../../lib/openbmc_ffdc.robot
7
ganesanb7a122f22023-03-31 10:39:16 +00008Suite Setup Disable Redfish Delete Session
9Suite Teardown Run Keywords Enable Redfish Delete Session AND Redfish.Logout
Prashanth Katti26f91752021-04-08 09:23:17 -050010Test Setup Printn
11Test Teardown FFDC On Test Case Fail
12
13
14*** Variables ***
15
16${duration} 6h
17${interval} 30s
18${reboot_interval} 30m
19${REDFISH_DELETE_SESSIONS} ${0}
20
21
22*** Test Cases ***
23
24Create Session And Check Connection Stability
George Keishing89f499d2021-04-19 05:25:40 -050025 [Documentation] Send heartbeat on session continuously and verify connection stability.
Prashanth Katti26f91752021-04-08 09:23:17 -050026 [Tags] Create_Session_And_Check_Connection_Stability
27 [Setup] Redfish.logout
28
29 # Clear old session and start new session.
30 Redfish.Login
31
32 Repeat Keyword ${duration} Send Heartbeat
33
34
35Create Session And Check Connection Stability On Reboot
36 [Documentation] Create Session And Check Connection Stability On Reboot
37 [Tags] Create_Session_And_Check_Connection_Stability_On_Reboot
38 [Setup] Redfish.logout
39
40 # Clear old session and start new session.
41 Redfish.Login
42
43 Repeat Keyword ${duration} Check Connection On Reboot
44
45
46*** Keywords ***
47
48Send Heartbeat
49 [Documentation] Send heartbeat to BMC.
50
51 ${hostname}= Redfish.Get Attribute ${REDFISH_NW_PROTOCOL_URI} HostName
52 Sleep ${interval}
53
54
55Check Connection On Reboot
56 [Documentation] Send heartbeat on BMC reboot.
57
58 # Reboot BMC
59 Redfish OBMC Reboot (Off)
60
61 # Verify session is still active and no issues on connection after reboot.
62 Repeat Keyword ${reboot_interval} Send Heartbeat
63
ganesanb7a122f22023-03-31 10:39:16 +000064Disable Redfish Delete Session
65 [Documentation] Disable delete redfish while performing power operation keyword.
66
67 ${REDFISH_DELETE_SESSIONS}= Set Variable ${0}
68 Set Suite Variable ${REDFISH_DELETE_SESSIONS}
69
70Enable Redfish Delete Session
71 [Documentation] Enable delete redfish while performing power operation keyword.
72
73 ${REDFISH_DELETE_SESSIONS}= Set Variable ${1}
74 Set Suite Variable ${REDFISH_DELETE_SESSIONS}