Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix: new home page issues #1428

Draft
wants to merge 17 commits into
base: master
Choose a base branch
from
Draft
Show file tree
Hide file tree
Changes from 10 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
16 changes: 14 additions & 2 deletions ods_ci/tests/Resources/Page/ODH/ODHDashboard/ODHDashboard.robot
Original file line number Diff line number Diff line change
Expand Up @@ -52,6 +52,7 @@
${RHODS_GROUPS_CONFIG_CM}= rhods-groups-config
${RHODS_LOGO_XPATH}= //img[@alt="${ODH_DASHBOARD_PROJECT_NAME} Logo"]
@{ISV_TO_REMOVE_SELF_MANAGED}= Create List starburst nvidia rhoam
@{HOME_HEADERS}= Projects Train, serve, monitor, and manage AI/ML models Get oriented with learning resources


*** Keywords ***
Expand All @@ -61,8 +62,7 @@
Open Browser ${dashboard_url} browser=${browser} options=${browser_options}
... alias=${browser_alias}
Login To RHODS Dashboard ${ocp_user_name} ${ocp_user_pw} ${ocp_user_auth_type}
Wait For RHODS Dashboard To Load expected_page=${expected_page}
... wait_for_cards=${wait_for_cards}
Wait For RHOAI Home Page To Load
FedeAlonso marked this conversation as resolved.
Show resolved Hide resolved

Authorize rhods-dashboard service account
Wait Until Page Contains Authorize Access
Expand Down Expand Up @@ -117,6 +117,18 @@
${title}= Get Element Attribute ${page_title_element} textContent
Should Be Equal ${title} ${page_title}

Wait For RHOAI Home Page To Load
[Documentation] Compare the h1 headers of the landing page with the expected ones
[Arguments] ${timeout}=10s
Fixed Show fixed Hide fixed
Wait Until Element is Visible xpath:(//h1)[1]
Fixed Show fixed Hide fixed
${h1_elements} Get WebElements xpath://h1
Fixed Show fixed Hide fixed
${h1_texts} Create List
Fixed Show fixed Hide fixed
Fixed Show fixed Hide fixed
FOR ${element} IN @{h1_elements}
${text} Get Text ${element}
Fixed Show fixed Hide fixed
Append To List ${h1_texts} ${text}
END
List Should Contain Sub List ${h1_texts} ${HOME_HEADERS}

Wait Until RHODS Dashboard ${dashboard_app} Is Visible
# Ideally the timeout would be an arg but Robot does not allow "normal" and "embedded" arguments
# Setting timeout to 30seconds since anything beyond that should be flagged as a UI bug
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -431,12 +431,12 @@ Launch Notebook And Stop It # robocop: disable
Set Library Search Order SeleniumLibrary
Open Browser ${ODH_DASHBOARD_URL} browser=${BROWSER.NAME} options=${BROWSER.OPTIONS}
Login To RHODS Dashboard ${TEST_USER.USERNAME} ${TEST_USER.PASSWORD} ${TEST_USER.AUTH_TYPE}
Wait For RHODS Dashboard To Load
Wait For RHOAI Home Page To Load
Launch Jupyter From RHODS Dashboard Link
Login To Jupyterhub ${TEST_USER.USERNAME} ${TEST_USER.PASSWORD} ${TEST_USER.AUTH_TYPE}
${authorization_required} = Is Service Account Authorization Required
IF ${authorization_required} Authorize Jupyterhub Service Account
Wait Until Page Contains Start a notebook server
Wait Until Page Contains Start a notebook server 30
Fix Spawner Status
Spawn Notebook With Arguments image=minimal-notebook
End Web Test
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@ Verify Content In RHODS Explore Section
# TODO: In ODH there are only 2 Apps, we excpect 7 Apps according to:
# ods_ci/tests/Resources/Files/AppsInfoDictionary_latest.json
${EXP_DATA_DICT}= Load Expected Data Of RHODS Explore Section
Click Link Explore
Navigate To Page Applications Explore
Wait For RHODS Dashboard To Load expected_page=Explore
Check Number Of Displayed Cards Is Correct expected_data=${EXP_DATA_DICT}
Check Cards Details Are Correct expected_data=${EXP_DATA_DICT}
Expand All @@ -75,7 +75,7 @@ Verify RHODS Explore Section Contains Only Expected ISVs
# TODO: In ODH there are only 2 Apps, we excpect 7 Apps according to:
# ods_ci/tests/Resources/Files/AppsInfoDictionary_latest.json
${EXP_DATA_DICT}= Load Expected Data Of RHODS Explore Section
Click Link Explore
Navigate To Page Applications Explore
Wait For RHODS Dashboard To Load expected_page=Explore
Check Number Of Displayed Cards Is Correct expected_data=${EXP_DATA_DICT}
Check Dashboard Diplayes Expected ISVs expected_data=${EXP_DATA_DICT}
Expand Down Expand Up @@ -124,7 +124,7 @@ Verify CSS Style Of Getting Started Descriptions
[Tags] Smoke
... Tier1
... ODS-1165
Click Link Explore
Navigate To Page Applications Explore
Wait For RHODS Dashboard To Load expected_page=Explore
${status}= Open Get Started Sidebar And Return Status card_locator=${JUPYTER_CARD_XP}
Should Be Equal ${status} ${TRUE}
Expand Down
Loading