Sivas SRR | 008dcc6 | 2018-02-27 06:34:56 -0600 | [diff] [blame] | 1 | *** Settings *** |
| 2 | |
| 3 | Documentation Test Open BMC GUI server health under GUI Header. |
| 4 | |
| 5 | Resource ../../lib/resource.robot |
| 6 | Resource ../../../../lib/boot_utils.robot |
Sivas SRR | be02691 | 2018-03-14 11:33:02 -0500 | [diff] [blame^] | 7 | Resource ../../../../lib/utils.robot |
| 8 | Resource ../../../../lib/openbmc_ffdc.robot |
| 9 | Resource ../../../../lib/state_manager.robot |
| 10 | Resource ../../../../lib/openbmc_ffdc_methods.robot |
| 11 | Resource ../../../../lib/dump_utils.robot |
Sivas SRR | 008dcc6 | 2018-02-27 06:34:56 -0600 | [diff] [blame] | 12 | |
| 13 | Suite Setup Launch Browser And Login OpenBMC GUI |
| 14 | Suite Teardown Logout And Close Browser |
Sivas SRR | be02691 | 2018-03-14 11:33:02 -0500 | [diff] [blame^] | 15 | Test Setup Test Setup Execution |
| 16 | Test Teardown Test Teardown Execution |
| 17 | |
Sivas SRR | 008dcc6 | 2018-02-27 06:34:56 -0600 | [diff] [blame] | 18 | |
| 19 | *** Test Cases *** |
| 20 | |
| 21 | Verify Event Log Text Appears By Clicking Server Health |
| 22 | [Documentation] Check that "Event Log" text appears by clicking server |
| 23 | ... health in GUI header. |
| 24 | [Tags] Verify_Event_Log_Text_Appears_By_Clicking_Server_Health |
| 25 | |
| 26 | Wait Until Page Contains Element event-log |
| 27 | Page should contain Event log |
| 28 | |
| 29 | |
| 30 | Verify Filters By Severity Elements Appears |
Sivas SRR | 179208e | 2018-03-01 04:08:23 -0600 | [diff] [blame] | 31 | [Documentation] Check that the "event log" filters appears by clicking |
| 32 | ... server health in GUI header. |
Sivas SRR | 008dcc6 | 2018-02-27 06:34:56 -0600 | [diff] [blame] | 33 | [Tags] Verify_Filters_By_Severity_Elements_Appears |
| 34 | |
| 35 | # Types of event severity: All, High, Medium, Low. |
| 36 | Page Should Contain Element ${xpath_event_severity_all} limit=1 |
| 37 | Page Should Contain Element ${xpath_event_severity_high} limit=1 |
| 38 | Page Should Contain Element ${xpath_event_severity_medium} limit=1 |
| 39 | Page Should Contain Element ${xpath_event_severity_low} limit=1 |
| 40 | |
| 41 | |
| 42 | Verify Drop Down Button User Timezone Appears |
Sivas SRR | 179208e | 2018-03-01 04:08:23 -0600 | [diff] [blame] | 43 | [Documentation] Check that the "drop down" button of user timezone appears |
| 44 | ... by clicking server health in GUI header. |
Sivas SRR | 008dcc6 | 2018-02-27 06:34:56 -0600 | [diff] [blame] | 45 | [Tags] Verify_Drop_Down_Button_User_Timezone_Appears |
| 46 | |
| 47 | Page Should Contain Button ${xpath_drop_down_timezone_edt} |
| 48 | # Ensure that page is not in refreshing state. |
| 49 | # It helps to click the drop down element. |
| 50 | Wait Until Page Does Not Contain Element ${xpath_refresh_circle} |
| 51 | Click Element class:dropdown__button |
| 52 | Page Should Contain Button ${xpath_drop_down_timezone_utc} |
| 53 | |
Sivas SRR | 179208e | 2018-03-01 04:08:23 -0600 | [diff] [blame] | 54 | |
| 55 | Verify Content Search Element Appears |
| 56 | [Documentation] Check that the "event search element is available with |
| 57 | ... filter" button appears. |
| 58 | [Tags] Verify_Content_Search_Element_Appears |
| 59 | |
| 60 | Page Should Contain Element content__search-input limit=1 |
| 61 | # Ensure that page is not in refreshing state. |
| 62 | Wait Until Page Does Not Contain Element ${xpath_refresh_circle} |
| 63 | Page Should Contain Button content__search-submit |
| 64 | |
| 65 | |
| 66 | Verify Filter By Date Element Appears |
| 67 | [Documentation] Check that the "filter by date" elements are available and |
| 68 | ... visible. |
| 69 | [Tags] Verify_Filter_By_Date_Element_Appears |
| 70 | |
| 71 | Wait Until Element Is Visible event-filter-start-date |
| 72 | Page Should Contain Element event-filter-start-date limit=1 |
| 73 | Page Should Contain Element event-filter-end-date limit=1 |
| 74 | |
| 75 | |
| 76 | Verify Filter By Event Status Element Appears |
| 77 | [Documentation] Check that the "filter by event status" element appears. |
| 78 | [Tags] Verify_Filter_By_Event_Status_Element_Appears |
| 79 | |
| 80 | # Ensure that page is not in refreshing state. |
| 81 | Wait Until Page Does Not Contain Element ${xpath_refresh_circle} |
| 82 | Wait Until Element is Visible class:dropdown__wrapper |
| 83 | Click Element class:dropdown__wrapper |
| 84 | Page Should Contain Element ${xpath_event_filter_all} limit=1 |
| 85 | Page Should Contain Element ${xpath_event_filter_resolved} limit=1 |
| 86 | Page Should Contain Element ${xpath_event_filter_unresolved} limit=1 |
Sivas SRR | 162bf48 | 2018-03-02 07:01:16 -0600 | [diff] [blame] | 87 | |
| 88 | |
| 89 | Verify Event Action Bar Element Appears |
| 90 | [Documentation] Check that "event action bar" element appears. |
| 91 | [Tags] Verify_Event_Action_Bar_Element_Appears |
| 92 | |
| 93 | # Ensure that page is not in refreshing state. |
| 94 | Wait Until Page Does Not Contain Element ${xpath_refresh_circle} |
| 95 | Page Should Contain Element ${xpath_event_action_bars} limit=1 |
| 96 | Page Should Contain Element class:control__indicator |
| 97 | |
| 98 | |
| 99 | Verify Click Events Check Box |
| 100 | [Documentation] Check that "event check box" element appears and on click |
| 101 | ... should be able to see elements like "Delete" button and "Export" |
| 102 | ... element. |
| 103 | [Tags] Verify_Click_Events_Check_Box |
| 104 | |
| 105 | # Ensure that page is not in refreshing state. |
| 106 | Wait Until Page Does Not Contain Element ${xpath_refresh_circle} |
| 107 | Click Element class:control__indicator |
| 108 | Page Should Contain Button ${xpath_event_action_delete} limit=1 |
| 109 | Page Should Contain Element ${xpath_event_action_export} limit=1 |
| 110 | |
| 111 | |
| 112 | Verify Number of Events Appears |
| 113 | [Documentation] Check that "number of events" element appears and value is |
| 114 | ... visible. |
| 115 | [Tags] Verify_Number_of_Events_Appears |
| 116 | |
| 117 | # Ensure that page is not in refreshing state. |
| 118 | Wait Until Page Does Not Contain Element ${xpath_refresh_circle} |
| 119 | Page Should Contain Element ${xpath_number_of_events} |
| 120 | ${number_of_events}= Get Text ${xpath_number_of_events} |
| 121 | Log To Console \n Number of Events:${number_of_events} |
Sivas SRR | be02691 | 2018-03-14 11:33:02 -0500 | [diff] [blame^] | 122 | |
| 123 | |
| 124 | Select All Error Logs And Mark As Resolved |
| 125 | [Documentation] Select all error logs and mark them as resolved. |
| 126 | [Tags] Select_All_Error_Logs_And_Mark_As_Resolved |
| 127 | |
| 128 | Create Test Error Log |
| 129 | Create Test Error Log |
| 130 | Wait Until Page Does Not Contain Element ${xpath_refresh_circle} |
| 131 | Page Should Contain Element ${xpath_number_of_events} |
| 132 | ${number_of_events}= Get Text ${xpath_number_of_events} |
| 133 | Click Element class:control__indicator |
| 134 | Run Keyword If ${number_of_events} > 0 |
| 135 | ... Click Element ${xpath_mark_as_resolved} |
| 136 | Element Should Be Disabled ${xpath_mark_as_resolved} |
| 137 | |
| 138 | |
| 139 | Select All Error Logs And Click Export |
| 140 | [Documentation] Select all error logs and click export element. |
| 141 | [Tags] Select_All_Error_Logs_And_Click_Export |
| 142 | |
| 143 | Create Test Error Log |
| 144 | Create Test Error Log |
| 145 | Wait Until Page Does Not Contain Element ${xpath_refresh_circle} |
| 146 | Page Should Contain Element ${xpath_number_of_events} |
| 147 | ${number_of_events}= Get Text ${xpath_number_of_events} |
| 148 | Click Element class:control__indicator |
| 149 | Page Should Contain Element ${xpath_events_export} |
| 150 | Run Keyword If ${number_of_events} > 0 |
| 151 | ... Click Element ${xpath_events_export} |
| 152 | |
| 153 | |
| 154 | Select All Error Logs And Delete |
| 155 | [Documentation] Select all error logs and delete them. |
| 156 | [Tags] Select_All_Error_Logs_And_Delete |
| 157 | |
| 158 | Create Test Error Log |
| 159 | Create Test Error Log |
| 160 | Wait Until Page Does Not Contain Element ${xpath_refresh_circle} |
| 161 | Page Should Contain Element ${xpath_number_of_events} |
| 162 | ${number_of_events}= Get Text ${xpath_number_of_events} |
| 163 | Click Element class:control__indicator |
| 164 | Page Should Contain Button ${xpath_event_action_delete} |
| 165 | Run Keyword If ${number_of_events} > 0 |
| 166 | ... Click Element ${xpath_event_action_delete} |
| 167 | ${number_of_events}= Get Text ${xpath_number_of_events} |
| 168 | Should Be Equal ${number_of_events} 0 |
| 169 | |
| 170 | |
| 171 | *** Keywords *** |
| 172 | |
| 173 | Test Setup Execution |
| 174 | [Documentation] Do test case setup tasks. |
| 175 | ${status}= Run Keyword And Return Status Logging Test Binary Exist |
| 176 | Run Keyword If ${status} == ${False} Install Tarball |
| 177 | Delete Error Logs And Verify |
| 178 | Click Element ${xpath_select_server_health} |
| 179 | |
| 180 | |
| 181 | Test Teardown Execution |
| 182 | [Documentation] Do the post test teardown. |
| 183 | |
| 184 | FFDC On Test Case Fail |
| 185 | Delete All Error Logs |
| 186 | Close All Connections |