def test_edit_organization(self): """A registered admin user can edit an organization's information.""" LoginPage(self).login('admin_user', 'password') page = OrganizationPage(self) page.go_to() page.go_to_organization_page() page.click_on_edit_button() page.try_cancel_and_close() fields = page.get_fields() assert fields["name"].get_attribute("value") == "Organization #0" assert fields["description"].text == "This is a test." assert fields["urls"].text == "" fields["name"].clear() fields["name"].send_keys("Stark Enterprise") fields["description"].clear() fields["description"].send_keys("A technology company.") page.click_on_submit_button() name = self.page_title().text info = page.get_org_description_and_members() print(name) assert "Stark Enterprise".upper() in name assert "A technology company." in info
def test_edit_organization(self): """A registered admin user can edit an organization's information.""" LoginPage(self).login('admin_user', 'password') page = OrganizationPage(self) page.go_to() page.go_to_organization_page() page.click_on_edit_button() page.try_cancel_and_close() fields = page.get_fields() assert fields["name"].get_attribute("value") == "Organization #0" assert fields["description"].text == "This is a test." assert fields["urls"].text == "" fields["name"].clear() fields["name"].send_keys("Stark Enterprise") fields["description"].clear() fields["description"].send_keys("A technology company.") page.click_on_submit_button() name = self.page_title().text info = page.get_org_description_and_members() assert "Stark Enterprise".upper() in name assert "A technology company." in info
def test_archiving_organization(self): """A registered admin user can archive/unarchive an organization.""" LoginPage(self).login('admin_user', 'password') page = OrganizationPage(self) page.go_to() page.go_to_organization_page() page.try_cancel_and_close_archive() page.get_archive_button() archive = page.click_on_archive_and_confirm(final_check=True) assert archive == "Unarchive organization" archive = page.click_on_archive_and_confirm(unarchive=True, final_check=True) assert archive == "Archive organization" archive = page.click_on_archive_and_confirm() page.click_on_edit_button(success=False) page.click_on_close_alert_button() page.click_on_add_project_button()
def test_archiving_organization(self): """A registered admin user can archive/unarchive an organization.""" LoginPage(self).login('admin_user', 'password') page = OrganizationPage(self) page.go_to() page.go_to_organization_page() page.try_cancel_and_close_archive() page.get_archive_button() archive = page.click_on_archive_and_confirm(final_check=True) assert archive == "Unarchive organization" archive = page.click_on_archive_and_confirm(unarchive=True, final_check=True) assert archive == "Archive organization" archive = page.click_on_archive_and_confirm() page.click_on_edit_button(success=False) page.click_on_close_alert_button() page.click_on_add_project_button()