11import re
22
3- from selenium .webdriver .common .by import By
43from selenium .webdriver .common .keys import Keys
5- from selenium .webdriver .support import expected_conditions as EC
6- from selenium .webdriver .support .ui import WebDriverWait
74
85import markers
96import settings
10- from api import osf_api
117from components .accessibility import ApplyA11yRules as a11y
128from components .email_access import EmailAccess
139from pages .dashboard import DashboardPage
1410from pages .landing import LandingPage
1511from pages .login import ForgotPasswordPage , ResetPasswordPage
1612from pages .project import MyProjectsPage
17- from pages .quickfiles import QuickfileDetailPage , QuickfilesPage
1813from pages .register import RegisterPage
1914from pages .search import SearchPage
2015from pages .support import SupportPage
@@ -60,6 +55,7 @@ def test_accessibility(
6055 my_projects_page = MyProjectsPage (driver )
6156 my_projects_page .goto ()
6257 assert MyProjectsPage (driver , verify = True )
58+ my_projects_page .empty_collection_indicator .present ()
6359 a11y .run_axe (
6460 driver ,
6561 session ,
@@ -69,56 +65,6 @@ def test_accessibility(
6965 )
7066
7167
72- @markers .ember_page
73- class TestMyQuickFilesPage :
74- def test_accessibility (
75- self , driver , session , write_files , exclude_best_practice , must_be_logged_in
76- ):
77- """ The Quick Files Page may or may not have any files listed depending on the
78- current user. Users in the testing environment probably will, but the Production
79- user may not.
80- """
81- quickfiles_page = QuickfilesPage (driver )
82- quickfiles_page .goto ()
83- quickfiles_page .loading_indicator .here_then_gone ()
84- assert QuickfilesPage (driver , verify = True )
85- a11y .run_axe (
86- driver ,
87- session ,
88- 'quickfiles' ,
89- write_files = write_files ,
90- exclude_best_practice = exclude_best_practice ,
91- )
92-
93-
94- @markers .ember_page
95- # For this next test we are uploading a text file to the user's Quick Files page so we
96- # don't want to run this in Production.
97- @markers .dont_run_on_prod
98- class TestMyQuickFileDetailPage :
99- def test_accessibility (
100- self , driver , session , write_files , exclude_best_practice , must_be_logged_in
101- ):
102- osf_api .upload_single_quickfile (session )
103- quickfiles_page = QuickfilesPage (driver )
104- quickfiles_page .goto ()
105- quickfiles_page .loading_indicator .here_then_gone ()
106- # click on title of file in table to open the Quick File Detail page
107- quickfiles_page .file_titles [0 ].click ()
108- assert QuickfileDetailPage (driver , verify = True )
109- # wait for mfr iframe to be visible before running axe
110- WebDriverWait (driver , 10 ).until (
111- EC .visibility_of_element_located ((By .ID , 'mfrIframeParent' ))
112- )
113- a11y .run_axe (
114- driver ,
115- session ,
116- 'qfiledet' ,
117- write_files = write_files ,
118- exclude_best_practice = exclude_best_practice ,
119- )
120-
121-
12268@markers .ember_page
12369class TestRegisterPage :
12470 def test_accessibility (self , driver , session , write_files , exclude_best_practice ):
0 commit comments