def test_archived_projects_appear_for_admin_user(self): """The option to filter active/archived projects is available to organization administrators.""" LoginPage(self).login('default5', 'password1') page = ProjectListPage(self) page.go_to_and_check_on_page() project_title = page.get_project_title_in_table() assert project_title == 'Linux Kernel' project_title = page.sort_table_by("descending") assert project_title == 'Project Gutenberg' page.sort_table_by("ascending") page.click_archive_filter("Archived") project_title = page.get_project_title_in_table() assert project_title == 'Zealous Archived Project Archived' project_title = page.sort_table_by("descending") assert project_title == 'Zealous Archived Project Archived' page.sort_table_by("ascending") page.click_archive_filter("All") project_title = page.get_project_title_in_table() assert project_title == 'Linux Kernel' project_title = page.sort_table_by("descending") assert project_title == 'Zealous Archived Project Archived' page.sort_table_by("ascending") page.click_archive_filter("Archived") page.click_archive_filter("Active") project_title = page.get_project_title_in_table() assert project_title == 'Linux Kernel'
def test_archived_projects_appear_for_admin_user(self): """The option to filter active/archived projects is available to organization administrators.""" LoginPage(self).login("default5", "password1") page = ProjectListPage(self) page.go_to_and_check_on_page() project_title = page.get_project_title_in_table() assert project_title == "Linux Kernel" project_title = page.sort_table_by("descending") assert project_title == "Project Gutenberg" page.sort_table_by("ascending") page.click_archive_filter("Archived") project_title = page.get_project_title_in_table() assert project_title == "Zealous Archived Project Archived" project_title = page.sort_table_by("descending") assert project_title == "Zealous Archived Project Archived" page.sort_table_by("ascending") page.click_archive_filter("All") project_title = page.get_project_title_in_table() assert project_title == "Linux Kernel" project_title = page.sort_table_by("descending") assert project_title == "Zealous Archived Project Archived" page.sort_table_by("ascending") page.click_archive_filter("Archived") page.click_archive_filter("Active") project_title = page.get_project_title_in_table() assert project_title == "Linux Kernel"
def test_archived_projects_appear_in_long_lists(self): """If the project list spans two pages, and an archived project appears on the second page, the archive filter option should still appear""" ProjectFactory.create_batch(10) LoginPage(self).login('default5', 'password1') page = ProjectListPage(self) page.go_to_and_check_on_page() project_title = page.get_project_title_in_table() assert project_title == 'Linux Kernel' project_title = page.sort_table_by("descending") assert project_title == 'Project Gutenberg' page.sort_table_by("ascending") page.click_archive_filter("Archived") project_title = page.get_project_title_in_table() assert project_title == 'Zealous Archived Project Archived' project_title = page.sort_table_by("descending") assert project_title == 'Zealous Archived Project Archived' page.sort_table_by("ascending") page.click_archive_filter("All") project_title = page.get_project_title_in_table() assert project_title == 'Linux Kernel' project_title = page.sort_table_by("descending") assert project_title == 'Zealous Archived Project Archived' page.sort_table_by("ascending") page.click_archive_filter("Archived") page.click_archive_filter("Active") project_title = page.get_project_title_in_table() assert project_title == 'Linux Kernel'
def test_archived_projects_appear_in_long_lists(self): """If the project list spans two pages, and an archived project appears on the second page, the archive filter option should still appear""" ProjectFactory.create_batch(10) LoginPage(self).login("default5", "password1") page = ProjectListPage(self) page.go_to_and_check_on_page() project_title = page.get_project_title_in_table() assert project_title == "Linux Kernel" project_title = page.sort_table_by("descending") assert project_title == "Project Gutenberg" page.sort_table_by("ascending") page.click_archive_filter("Archived") project_title = page.get_project_title_in_table() assert project_title == "Zealous Archived Project Archived" project_title = page.sort_table_by("descending") assert project_title == "Zealous Archived Project Archived" page.sort_table_by("ascending") page.click_archive_filter("All") project_title = page.get_project_title_in_table() assert project_title == "Linux Kernel" project_title = page.sort_table_by("descending") assert project_title == "Zealous Archived Project Archived" page.sort_table_by("ascending") page.click_archive_filter("Archived") page.click_archive_filter("Active") project_title = page.get_project_title_in_table() assert project_title == "Linux Kernel"