diff --git a/ods_ci/tests/Resources/Page/ODH/ODHDashboard/ODHDashboard.robot b/ods_ci/tests/Resources/Page/ODH/ODHDashboard/ODHDashboard.robot index 2e04f5dfe..95144a381 100644 --- a/ods_ci/tests/Resources/Page/ODH/ODHDashboard/ODHDashboard.robot +++ b/ods_ci/tests/Resources/Page/ODH/ODHDashboard/ODHDashboard.robot @@ -642,7 +642,8 @@ Open Edit Menu For Custom Image Expand Custom Image Details [Documentation] Expands a custom image's row in the dashboard UI [Arguments] ${image_name} - ${is_expanded}= Run Keyword And Return Status Page Should Contain Element xpath://td[.="${image_name}"]/../td[1]/button[@aria-expanded="true"] + ${is_expanded}= Run Keyword And Return Status + ... Page Should Contain Element xpath://td[.="${image_name}"]/../td[1]/button[@aria-expanded="true"] IF ${is_expanded}==False Click Button xpath://td[.="${image_name}"]/../td[1]//button END @@ -650,7 +651,8 @@ Expand Custom Image Details Collapse Custom Image Details [Documentation] Collapses a custom image's row in the dashboard UI [Arguments] ${image_name} - ${is_expanded}= Run Keyword And Return Status Page Should Contain Element xpath://td[.="${image_name}"]/../td[1]/button[@aria-expanded="true"] + ${is_expanded}= Run Keyword And Return Status + ... Page Should Contain Element xpath://td[.="${image_name}"]/../td[1]/button[@aria-expanded="true"] IF ${is_expanded}==True Click Button xpath://td[.="${image_name}"]/../td[1]//button END diff --git a/ods_ci/tests/Resources/Page/ODH/ODHDashboard/ODHDataScienceProject/Projects.resource b/ods_ci/tests/Resources/Page/ODH/ODHDashboard/ODHDataScienceProject/Projects.resource index 7371463f8..f4d114f36 100644 --- a/ods_ci/tests/Resources/Page/ODH/ODHDashboard/ODHDataScienceProject/Projects.resource +++ b/ods_ci/tests/Resources/Page/ODH/ODHDashboard/ODHDataScienceProject/Projects.resource @@ -57,7 +57,7 @@ Delete Data Science Project ODHDashboard.Click Action From Actions Menu item_title=${project_title} item_type=project action=Delete Handle Deletion Confirmation Modal item_title=${project_title} item_type=project ... press_cancel=${press_cancel} - ... additional_msg=It will destroy all workbenches, storages, data connections and other resources in ${project_title} + ... additional_msg=It will destroy all workbenches, storages, data connections and other resources in ${project_title} # robocop: disable Wait Until Data Science Project Is Deleted project_title=${project_title} Wait Until Data Science Project Is Deleted @@ -107,7 +107,8 @@ Project's Owner Should Be [Documentation] Checks if the owner of a DS project is displayed and corresponds to the expected one [Arguments] ${project_title} ${expected_username} Run Keyword And Continue On Failure - ... Page Should Contain Element xpath=//a[text()="${project_title}"]/ancestor::td[@data-label='Name']//small[text()="${expected_username}"] + ... Page Should Contain Element + ... xpath=//a[text()="${project_title}"]/ancestor::td[@data-label='Name']//small[text()="${expected_username}"] Create Data Science Project [Documentation] Creates a DS Project with the given ${title}, ${description} and ${resource_name}. @@ -188,7 +189,7 @@ Delete Data Science Project From CLI END END - +#robocop: disable: line-too-long Workbench Status Should Be From Projects Home Page [Documentation] Checks the workbench status is the expected one, from the DS Project home page [Arguments] ${workbench_title} ${status} ${project_title} @@ -223,6 +224,7 @@ Start Workbench From Projects Home Page Wait Until Workbench Is Started From Projects Home Page workbench_title=${workbench_title} ... project_title=${project_title} +#robocop: disable: line-too-long Stop Workbench From Projects Home Page [Documentation] Triggers the workbench "stop" process from DS Projects home page. ... It needs ${workbench_title} and ${project_title} at least. If ${namespace} and/or @@ -313,7 +315,6 @@ Launch Data Science Project Main Page ... browser_alias=${browser_alias} Open Data Science Projects Home Page - Remove Current Page Projects From All Projects [Documentation] Remove list of currently displayed Data Science projects from list of all projects [Arguments] ${all_projects} ${curr_page_projects} @@ -403,7 +404,8 @@ Create Data Science Project If Not Exists [Documentation] If the given ${project_title} DS Project does not exist, it creates one. ... Useful as test setup. [Arguments] ${project_title} ${username} ${description}=${EMPTY} - ${rc} ${resource_name}= Run And Return Rc And Output oc get projects -o json | jq '.items[] | select((.metadata.annotations."openshift.io/display-name" != null) and (.metadata.labels."opendatahub.io/dashboard"=="true") and (.metadata.annotations."openshift.io/display-name"=="${project_title}")) | .metadata.name' | tr -d '"' # robocop: disable + ${rc} ${resource_name}= Run And Return Rc And Output + ... oc get projects -o json | jq '.items[] | select((.metadata.annotations."openshift.io/display-name" != null) and (.metadata.labels."opendatahub.io/dashboard"=="true") and (.metadata.annotations."openshift.io/display-name"=="${project_title}")) | .metadata.name' | tr -d '"' # robocop: disable IF "${resource_name}" == "${EMPTY}" Log msg=There is no DS Projects with Diplay Name equal to ${project_title}. Creating it now. Launch Data Science Project Main Page username=${username} @@ -418,4 +420,4 @@ Clean Project From Workbench Resources ... ${pvc_title}=${workbench_title} Delete Workbench From CLI workbench_title=${workbench_title} ... project_title=${project_title} - Delete PVC In Project From CLI pvc_title=${pvc_title} project_title=${project_title} + Delete PVC In Project From CLI pvc_title=${pvc_title} project_title=${project_title} # robocop: disable diff --git a/ods_ci/tests/Resources/Page/ODH/ODHDashboard/ODHDataScienceProject/Storages.resource b/ods_ci/tests/Resources/Page/ODH/ODHDashboard/ODHDataScienceProject/Storages.resource index 2f1cd7633..a91d77d6c 100644 --- a/ods_ci/tests/Resources/Page/ODH/ODHDashboard/ODHDataScienceProject/Storages.resource +++ b/ods_ci/tests/Resources/Page/ODH/ODHDashboard/ODHDataScienceProject/Storages.resource @@ -18,6 +18,7 @@ ${STORAGE_SUBMIT_BTN_XP}= xpath=//footer//button[@data-testid="modal-s *** Keywords *** +#robocop: disable: line-too-long Storage Should Be Listed [Documentation] Checks storage is listed in DS Project details page [Arguments] ${name} ${description} ${type} ${connected_workbench} @@ -51,7 +52,7 @@ Storage Size Should Be ... oc get pvc -n ${namespace} -o jsonpath='{.items[?(@.metadata.annotations.openshift\\.io/display-name=="${name}")].status.phase}' # robocop: disable Should Be Equal As Integers ${rc} 0 An error occurred during the check of PVC ${name} .status.phase value! ${storage_size_xp}= Set Variable - ... ${STORAGE_SECTION_XP}//tr[td//*/div[text()="${name}"]]/following-sibling::*//td[contains(@data-label,"Size")]//div[strong[text()="Size"]] + ... ${STORAGE_SECTION_XP}//tr[td//*/div[text()="${name}"]]/following-sibling::*//td[contains(@data-label,"Size")]//div[strong[text()="Size"]] # robocop: disable IF "${pvc_status_phase}" == "Pending" # PVC hasn't been bound yet - only simple text with max storage should be shown Wait Until Page Contains Element ${storage_size_xp} timeout=2m diff --git a/ods_ci/tests/Resources/Page/ODH/ODHDashboard/ODHDataScienceProject/Workbenches.resource b/ods_ci/tests/Resources/Page/ODH/ODHDashboard/ODHDataScienceProject/Workbenches.resource index fa6d15205..52b9d93ce 100644 --- a/ods_ci/tests/Resources/Page/ODH/ODHDashboard/ODHDataScienceProject/Workbenches.resource +++ b/ods_ci/tests/Resources/Page/ODH/ODHDashboard/ODHDataScienceProject/Workbenches.resource @@ -98,6 +98,7 @@ Create Workbench Wait Until Generic Modal Disappears timeout=1 minute Wait Until Project Is Open project_title=${prj_title} +#robocop: disable: line-too-long Add Environment Variables In Workbench [Documentation] Adds the environment variables through the workbench creation page [Arguments] ${env_variables} diff --git a/ods_ci/tests/Tests/400__ods_dashboard/415__ods_dashboard_projects/415__ods_dashboard_projects.robot b/ods_ci/tests/Tests/400__ods_dashboard/415__ods_dashboard_projects/415__ods_dashboard_projects.robot index 7226e5197..0c0c1a08d 100644 --- a/ods_ci/tests/Tests/400__ods_dashboard/415__ods_dashboard_projects/415__ods_dashboard_projects.robot +++ b/ods_ci/tests/Tests/400__ods_dashboard/415__ods_dashboard_projects/415__ods_dashboard_projects.robot @@ -538,8 +538,6 @@ Verify User Can Access Only Its Owned Projects [Setup] Run Keywords ... SeleniumLibrary.Close All Browsers ... AND - ... Set Variables For User Access Test - ... AND ... Delete Data Science Project From CLI displayed_name=${PRJ_TITLE} Launch Data Science Project Main Page username=${TEST_USER_3.USERNAME} password=${TEST_USER_3.PASSWORD} Open Data Science Projects Home Page @@ -588,6 +586,7 @@ Project Suite Setup Set Library Search Order SeleniumLibrary ${to_delete}= Create List ${PRJ_TITLE} Set Suite Variable ${PROJECTS_TO_DELETE} ${to_delete} + Set Variables For User Access Test RHOSi Setup Delete Data Science Projects From CLI ocp_projects=${PROJECTS_TO_DELETE} Launch Data Science Project Main Page