зеркало из https://github.com/mozilla/kitsune.git
- Fixing failing tests.
This commit is contained in:
Родитель
7c049ea697
Коммит
d69fae1203
|
@ -76,3 +76,72 @@ class AAQFlow(AAQFormPage, ProductSolutionsPage, TopNavbar, TestUtilities, Quest
|
|||
super()._get_upload_image_button_locator().set_input_files(
|
||||
super().aaq_question_test_data["valid_firefox_question"]["image_path"]
|
||||
)
|
||||
|
||||
def deleting_question_flow(self):
|
||||
super()._click_delete_this_question_question_tools_option()
|
||||
super()._click_delete_this_question_button()
|
||||
|
||||
def editing_question_flow(self, subject='', body='', troubleshoot='', submit_edit=True):
|
||||
if subject != '':
|
||||
super()._clear_subject_input_field()
|
||||
super()._add_text_to_aaq_form_subject_field(subject)
|
||||
|
||||
if body != '':
|
||||
super()._clear_the_question_body_textarea_field()
|
||||
super()._add_text_to_aaq_textarea_field(body)
|
||||
|
||||
if troubleshoot != '':
|
||||
super()._add_text_to_troubleshooting_information_textarea(troubleshoot)
|
||||
|
||||
if submit_edit:
|
||||
super()._click_aaq_edit_submit_button()
|
||||
|
||||
def editing_reply_flow(self, reply_body: str, submit_reply=True):
|
||||
super()._clear_the_question_body_textarea_field()
|
||||
super()._add_text_to_aaq_textarea_field(reply_body)
|
||||
|
||||
if submit_reply:
|
||||
super()._click_on_update_answer_button()
|
||||
else:
|
||||
super()._click_aaq_form_cancel_button()
|
||||
|
||||
def delete_question_reply(self, answer_id: str, delete_reply:bool):
|
||||
super()._click_on_reply_more_options_button(answer_id)
|
||||
super()._click_on_delete_this_post_for_a_certain_reply(answer_id)
|
||||
|
||||
if delete_reply:
|
||||
super()._click_delete_this_question_button()
|
||||
else:
|
||||
super()._click_on_cancel_delete_button()
|
||||
|
||||
def post_question_reply_flow(self,
|
||||
repliant_username: str,
|
||||
reply='',
|
||||
submit_reply=True,
|
||||
quoted_reply=False,
|
||||
reply_for_id='') -> str:
|
||||
if quoted_reply:
|
||||
super()._click_on_reply_more_options_button(reply_for_id)
|
||||
super()._click_on_quote_for_a_certain_reply(reply_for_id)
|
||||
|
||||
if reply != '' and quoted_reply:
|
||||
super()._type_inside_the_post_a_reply_textarea(reply)
|
||||
elif reply != '' and not quoted_reply:
|
||||
super()._add_text_to_post_a_reply_textarea(reply)
|
||||
|
||||
if submit_reply:
|
||||
return super()._click_on_post_reply_button(repliant_username)
|
||||
|
||||
def report_question_abuse(self, answer_id: str, text=''):
|
||||
super()._click_on_reply_more_options_button(answer_id)
|
||||
super()._click_on_report_abuse_for_a_certain_reply(answer_id)
|
||||
|
||||
if text != '':
|
||||
super()._add_text_to_report_abuse_textarea(text)
|
||||
|
||||
super()._click_on_report_abuse_submit_button()
|
||||
super()._click_abuse_modal_close_button()
|
||||
|
||||
def spam_marking_a_reply(self, reply_id: str):
|
||||
super()._click_on_reply_more_options_button(reply_id)
|
||||
super()._click_on_mark_as_spam_for_a_certain_reply(reply_id)
|
||||
|
|
|
@ -1,14 +1,38 @@
|
|||
from playwright.sync_api import Page
|
||||
from playwright_tests.core.testutilities import TestUtilities
|
||||
from playwright_tests.pages.messaging_system_pages.inbox_page import InboxPage
|
||||
from playwright_tests.pages.messaging_system_pages.new_message import NewMessagePage
|
||||
from playwright_tests.pages.messaging_system_pages.sent_messages import SentMessagePage
|
||||
|
||||
|
||||
class MessagingSystemFlows(TestUtilities, NewMessagePage):
|
||||
class MessagingSystemFlows(TestUtilities, NewMessagePage, SentMessagePage, InboxPage):
|
||||
def __init__(self, page: Page):
|
||||
super().__init__(page)
|
||||
|
||||
# Send message form with data flow.
|
||||
def complete_send_message_form_with_data(self, recipient_username: str, message_body: str):
|
||||
super()._type_into_new_message_to_input_field(recipient_username)
|
||||
super()._click_on_a_searched_user(recipient_username)
|
||||
super()._fill_into_new_message_body_textarea(message_body)
|
||||
def complete_send_message_form_with_data(self,
|
||||
recipient_username='',
|
||||
message_body='',
|
||||
submit_message=True):
|
||||
if recipient_username != '':
|
||||
super()._type_into_new_message_to_input_field(recipient_username)
|
||||
super()._click_on_a_searched_user(recipient_username)
|
||||
|
||||
if message_body != '':
|
||||
super()._fill_into_new_message_body_textarea(message_body)
|
||||
|
||||
if submit_message:
|
||||
super()._click_on_new_message_send_button()
|
||||
|
||||
def delete_message_flow(self, username: str,
|
||||
delete_message=True,
|
||||
from_sent_list=False,
|
||||
from_inbox_list=False):
|
||||
if from_sent_list:
|
||||
super()._click_on_sent_message_delete_button(username)
|
||||
|
||||
if from_inbox_list:
|
||||
super()._click_on_inbox_message_delete_button(username)
|
||||
|
||||
if delete_message:
|
||||
super()._click_on_delete_page_delete_button()
|
||||
|
|
|
@ -1,9 +1,20 @@
|
|||
from playwright.sync_api import Page
|
||||
from playwright_tests.core.testutilities import TestUtilities
|
||||
from playwright_tests.pages.top_navbar import TopNavbar
|
||||
from playwright_tests.pages.user_pages.my_profile_edit import MyProfileEdit
|
||||
from playwright_tests.pages.user_pages.my_profile_edit_contribution_areas_page import \
|
||||
MyProfileEditContributionAreasPage
|
||||
from playwright_tests.pages.user_pages.my_profile_edit_settings_page import \
|
||||
MyProfileEditSettingsPage
|
||||
from playwright_tests.pages.user_pages.my_profile_user_navbar import UserNavbar
|
||||
|
||||
|
||||
class EditProfileDataFlow(MyProfileEdit, TestUtilities):
|
||||
class EditProfileDataFlow(MyProfileEdit,
|
||||
TestUtilities,
|
||||
MyProfileEditContributionAreasPage,
|
||||
TopNavbar,
|
||||
UserNavbar,
|
||||
MyProfileEditSettingsPage):
|
||||
def __init__(self, page: Page):
|
||||
super().__init__(page)
|
||||
|
||||
|
@ -50,3 +61,19 @@ class EditProfileDataFlow(MyProfileEdit, TestUtilities):
|
|||
super()._clear_all_input_fields()
|
||||
super()._clear_username_field()
|
||||
super()._clear_biography_textarea_field()
|
||||
|
||||
def check_all_user_settings(self):
|
||||
super()._click_on_settings_profile_option()
|
||||
super()._click_on_all_settings_checkboxes()
|
||||
super()._click_on_update_button()
|
||||
|
||||
def check_all_profile_contribution_areas(self, checked: bool):
|
||||
super()._click_on_settings_profile_option()
|
||||
super()._click_on_edit_contribution_areas_option()
|
||||
|
||||
if not checked:
|
||||
super()._click_on_unchecked_cont_areas_checkboxes()
|
||||
else:
|
||||
super()._click_on_all_checked_cont_areas_checkboxes()
|
||||
|
||||
super()._click_on_update_contribution_areas_button()
|
||||
|
|
|
@ -16,7 +16,7 @@
|
|||
"common_responses_response": "Zoom feature"
|
||||
},
|
||||
"troubleshooting_information_kb_article_url": "https://support.mozilla.org/en-US/kb/use-troubleshooting-information-page-fix-firefox",
|
||||
"troubleshooting_information_textarea_field": "Test Troubleshooting data",
|
||||
"troubleshooting_information": "Test Troubleshooting data",
|
||||
"troubleshoot_product_and_os_versions": ["Test os", "Test product version"],
|
||||
"products_aaq_url": {
|
||||
"Firefox": "https://support.allizom.org/en-US/questions/new/desktop/form",
|
||||
|
|
|
@ -319,8 +319,7 @@ class TestAAQPage(TestUtilities):
|
|||
question_info['aaq_subject']
|
||||
)
|
||||
|
||||
self.sumo_pages.question_page._click_delete_this_question_question_tools_option()
|
||||
self.sumo_pages.question_page._click_delete_this_question_button()
|
||||
self.sumo_pages.aaq_flow.deleting_question_flow()
|
||||
|
||||
self.logger.info(
|
||||
"Verifying that the question is no longer displayed inside My Questions page")
|
||||
|
@ -363,7 +362,7 @@ class TestAAQPage(TestUtilities):
|
|||
|
||||
self.logger.info("Adding text inside the troubleshooting information field")
|
||||
self.sumo_pages.aaq_form_page._add_text_to_troubleshooting_information_textarea(
|
||||
super().aaq_question_test_data["troubleshooting_information_textarea_field"]
|
||||
super().aaq_question_test_data["troubleshooting_information"]
|
||||
)
|
||||
|
||||
self.logger.info("Submitting the aaq question")
|
||||
|
@ -375,7 +374,7 @@ class TestAAQPage(TestUtilities):
|
|||
|
||||
expect(
|
||||
self.sumo_pages.question_page._get_more_information_with_text_locator(
|
||||
super().aaq_question_test_data["troubleshooting_information_textarea_field"]
|
||||
super().aaq_question_test_data["troubleshooting_information"]
|
||||
)
|
||||
).to_be_visible()
|
||||
|
||||
|
@ -383,8 +382,7 @@ class TestAAQPage(TestUtilities):
|
|||
self.sumo_pages.question_page._click_on_the_additional_system_panel_close_button()
|
||||
|
||||
self.logger.info("Deleting the posted question")
|
||||
self.sumo_pages.question_page._click_delete_this_question_question_tools_option()
|
||||
self.sumo_pages.question_page._click_delete_this_question_button()
|
||||
self.sumo_pages.aaq_flow.deleting_question_flow()
|
||||
|
||||
@pytest.mark.aaqPage
|
||||
def test_additional_system_details_user_agent_information(self):
|
||||
|
@ -421,8 +419,7 @@ class TestAAQPage(TestUtilities):
|
|||
self.sumo_pages.question_page._click_on_the_additional_system_panel_close_button()
|
||||
|
||||
self.logger.info("Deleting the posted question")
|
||||
self.sumo_pages.question_page._click_delete_this_question_question_tools_option()
|
||||
self.sumo_pages.question_page._click_delete_this_question_button()
|
||||
self.sumo_pages.aaq_flow.deleting_question_flow()
|
||||
|
||||
@pytest.mark.aaqPage
|
||||
def test_system_details_information(self):
|
||||
|
@ -480,5 +477,4 @@ class TestAAQPage(TestUtilities):
|
|||
)
|
||||
|
||||
self.logger.info("Deleting the posted question")
|
||||
self.sumo_pages.question_page._click_delete_this_question_question_tools_option()
|
||||
self.sumo_pages.question_page._click_delete_this_question_button()
|
||||
self.sumo_pages.aaq_flow.deleting_question_flow()
|
||||
|
|
|
@ -70,8 +70,7 @@ class TestPostedQuestions(TestUtilities):
|
|||
)
|
||||
|
||||
self.logger.info("Deleting the posted question")
|
||||
self.sumo_pages.question_page._click_delete_this_question_question_tools_option()
|
||||
self.sumo_pages.question_page._click_delete_this_question_button()
|
||||
self.sumo_pages.aaq_flow.deleting_question_flow()
|
||||
|
||||
# C2191092, C2191263
|
||||
@pytest.mark.postedQuestions
|
||||
|
@ -108,8 +107,7 @@ class TestPostedQuestions(TestUtilities):
|
|||
))
|
||||
|
||||
self.logger.info("Deleting the posted question")
|
||||
self.sumo_pages.question_page._click_delete_this_question_question_tools_option()
|
||||
self.sumo_pages.question_page._click_delete_this_question_button()
|
||||
self.sumo_pages.aaq_flow.deleting_question_flow()
|
||||
|
||||
# C2191262, C2436105, C2191263
|
||||
# To add image tests
|
||||
|
@ -146,21 +144,12 @@ class TestPostedQuestions(TestUtilities):
|
|||
posted_question['question_details']['question_body']
|
||||
)
|
||||
|
||||
self.logger.info("Adding text inside the Subject field")
|
||||
self.sumo_pages.aaq_form_page._clear_subject_input_field()
|
||||
self.sumo_pages.aaq_form_page._add_text_to_aaq_form_subject_field(
|
||||
super().aaq_question_test_data['valid_firefox_question']['subject_updated']
|
||||
)
|
||||
|
||||
self.logger.info("Adding text inside the body field")
|
||||
self.sumo_pages.aaq_form_page._clear_the_question_body_textarea_field()
|
||||
self.sumo_pages.aaq_form_page._add_text_to_aaq_textarea_field(
|
||||
super().aaq_question_test_data['valid_firefox_question']['body_updated']
|
||||
)
|
||||
|
||||
self.logger.info("Adding information inside the troubleshoot information textarea")
|
||||
self.sumo_pages.aaq_form_page._add_text_to_troubleshooting_information_textarea(
|
||||
super().aaq_question_test_data['troubleshooting_information_textarea_field']
|
||||
self.logger.info("Editing the question with new data")
|
||||
self.sumo_pages.aaq_flow.editing_question_flow(
|
||||
subject=super().aaq_question_test_data['valid_firefox_question']['subject_updated'],
|
||||
body=super().aaq_question_test_data['valid_firefox_question']['body_updated'],
|
||||
troubleshoot=super().aaq_question_test_data['troubleshooting_information'],
|
||||
submit_edit=False
|
||||
)
|
||||
|
||||
self.logger.info("Clicking on the 'Cancel' button")
|
||||
|
@ -210,8 +199,7 @@ class TestPostedQuestions(TestUtilities):
|
|||
))
|
||||
|
||||
self.logger.info("Deleting the posted question")
|
||||
self.sumo_pages.question_page._click_delete_this_question_question_tools_option()
|
||||
self.sumo_pages.question_page._click_delete_this_question_button()
|
||||
self.sumo_pages.aaq_flow.deleting_question_flow()
|
||||
|
||||
# C2191263
|
||||
@pytest.mark.postedQuestions
|
||||
|
@ -244,7 +232,7 @@ class TestPostedQuestions(TestUtilities):
|
|||
)
|
||||
|
||||
self.logger.info("Navigating back to the posted question")
|
||||
self.navigate_back()
|
||||
self.navigate_to_link(posted_question['question_details']['question_page_url'])
|
||||
|
||||
self.logger.info("Signing in with an admin account")
|
||||
self.start_existing_session(super().username_extraction_from_email(
|
||||
|
@ -252,8 +240,7 @@ class TestPostedQuestions(TestUtilities):
|
|||
))
|
||||
|
||||
self.logger.info("Deleting the posted question")
|
||||
self.sumo_pages.question_page._click_delete_this_question_question_tools_option()
|
||||
self.sumo_pages.question_page._click_delete_this_question_button()
|
||||
self.sumo_pages.aaq_flow.deleting_question_flow()
|
||||
|
||||
# C2191262, C2436105, C2191263
|
||||
# To add image tests
|
||||
|
@ -293,26 +280,13 @@ class TestPostedQuestions(TestUtilities):
|
|||
|
||||
)
|
||||
|
||||
self.logger.info("Adding text inside the Subject field")
|
||||
self.sumo_pages.aaq_form_page._clear_subject_input_field()
|
||||
self.sumo_pages.aaq_form_page._add_text_to_aaq_form_subject_field(
|
||||
super().aaq_question_test_data['valid_firefox_question']['subject_updated']
|
||||
self.logger.info("Editing the question with new data")
|
||||
self.sumo_pages.aaq_flow.editing_question_flow(
|
||||
subject=super().aaq_question_test_data['valid_firefox_question']['subject_updated'],
|
||||
body=super().aaq_question_test_data['valid_firefox_question']['body_updated'],
|
||||
troubleshoot=super().aaq_question_test_data['troubleshooting_information']
|
||||
)
|
||||
|
||||
self.logger.info("Adding text inside the body field")
|
||||
self.sumo_pages.aaq_form_page._clear_the_question_body_textarea_field()
|
||||
self.sumo_pages.aaq_form_page._add_text_to_aaq_textarea_field(
|
||||
super().aaq_question_test_data['valid_firefox_question']['body_updated']
|
||||
)
|
||||
|
||||
self.logger.info("Adding information inside the troubleshoot information textarea")
|
||||
self.sumo_pages.aaq_form_page._add_text_to_troubleshooting_information_textarea(
|
||||
super().aaq_question_test_data['troubleshooting_information_textarea_field']
|
||||
)
|
||||
|
||||
self.logger.info("Clicking on the 'Submit' button")
|
||||
self.sumo_pages.aaq_form_page._click_aaq_edit_submit_button()
|
||||
|
||||
self.logger.info("Verifying that the 'Modified' text is displayed")
|
||||
expect(
|
||||
self.sumo_pages.question_page._get_modified_question_locator()
|
||||
|
@ -350,7 +324,7 @@ class TestPostedQuestions(TestUtilities):
|
|||
self.logger.info("Verifying that the more information section displays the update")
|
||||
expect(
|
||||
self.sumo_pages.question_page._get_more_information_with_text_locator(
|
||||
super().aaq_question_test_data['troubleshooting_information_textarea_field']
|
||||
super().aaq_question_test_data['troubleshooting_information']
|
||||
)
|
||||
).to_be_visible()
|
||||
|
||||
|
@ -364,8 +338,7 @@ class TestPostedQuestions(TestUtilities):
|
|||
))
|
||||
|
||||
self.logger.info("Deleting the posted question")
|
||||
self.sumo_pages.question_page._click_delete_this_question_question_tools_option()
|
||||
self.sumo_pages.question_page._click_delete_this_question_button()
|
||||
self.sumo_pages.aaq_flow.deleting_question_flow()
|
||||
|
||||
# C2191263
|
||||
@pytest.mark.postedQuestions
|
||||
|
@ -378,9 +351,7 @@ class TestPostedQuestions(TestUtilities):
|
|||
"question")
|
||||
posted_question_two = self.post_firefox_product_question_flow('TEST_ACCOUNT_12')
|
||||
|
||||
self.navigate_to_link(
|
||||
posted_question_one['question_details']['question_page_url']
|
||||
)
|
||||
self.navigate_to_link(posted_question_one['question_details']['question_page_url'])
|
||||
|
||||
self.logger.info("Verifying that the 'Delete this question' option is not available")
|
||||
expect(
|
||||
|
@ -400,9 +371,7 @@ class TestPostedQuestions(TestUtilities):
|
|||
403
|
||||
)
|
||||
|
||||
self.navigate_to_link(
|
||||
posted_question_two['question_details']['question_page_url']
|
||||
)
|
||||
self.navigate_to_link(posted_question_two['question_details']['question_page_url'])
|
||||
|
||||
self.logger.info("Verifying that the 'Delete this question' option is not available")
|
||||
expect(
|
||||
|
@ -423,7 +392,7 @@ class TestPostedQuestions(TestUtilities):
|
|||
)
|
||||
|
||||
self.logger.info("Navigating back to the question page and deleting session cookies")
|
||||
self.navigate_back()
|
||||
self.navigate_to_link(posted_question_two['question_details']['question_page_url'])
|
||||
|
||||
self.logger.info("Signing in with a admin user account")
|
||||
self.start_existing_session(super().username_extraction_from_email(
|
||||
|
@ -443,16 +412,12 @@ class TestPostedQuestions(TestUtilities):
|
|||
).to_have_url(posted_question_two['question_details']['question_page_url'])
|
||||
|
||||
self.logger.info("Deleting the posted question")
|
||||
self.sumo_pages.question_page._click_delete_this_question_question_tools_option()
|
||||
self.sumo_pages.question_page._click_delete_this_question_button()
|
||||
self.sumo_pages.aaq_flow.deleting_question_flow()
|
||||
|
||||
self.navigate_to_link(
|
||||
posted_question_one['question_details']['question_page_url']
|
||||
)
|
||||
self.navigate_to_link(posted_question_one['question_details']['question_page_url'])
|
||||
|
||||
self.logger.info("Deleting the posted question")
|
||||
self.sumo_pages.question_page._click_delete_this_question_question_tools_option()
|
||||
self.sumo_pages.question_page._click_delete_this_question_button()
|
||||
self.sumo_pages.aaq_flow.deleting_question_flow()
|
||||
|
||||
# C2191264, C2191265
|
||||
# To add coverage for images as well
|
||||
|
@ -586,11 +551,6 @@ class TestPostedQuestions(TestUtilities):
|
|||
self.user_secrets_accounts["TEST_ACCOUNT_MODERATOR"]
|
||||
))
|
||||
|
||||
self.logger.info("Adding text inside the textarea field")
|
||||
self.sumo_pages.question_page._add_text_to_post_a_reply_textarea(
|
||||
super().aaq_question_test_data['valid_firefox_question']['question_reply']
|
||||
)
|
||||
|
||||
self.logger.info("Verifying that the 'needs more information from the user' checkbox is "
|
||||
"available")
|
||||
expect(
|
||||
|
@ -602,8 +562,11 @@ class TestPostedQuestions(TestUtilities):
|
|||
self.sumo_pages.question_page._get_add_image_section_locator()
|
||||
).to_be_visible()
|
||||
|
||||
self.logger.info("Clicking on the 'Post a reply button'")
|
||||
reply_id = self.sumo_pages.question_page._click_on_post_reply_button(repliant_username)
|
||||
self.logger.info("Submitting a reply to the question")
|
||||
reply_id = self.sumo_pages.aaq_flow.post_question_reply_flow(
|
||||
repliant_username=repliant_username,
|
||||
reply=super().aaq_question_test_data['valid_firefox_question']['question_reply']
|
||||
)
|
||||
|
||||
self.logger.info("Verifying that posted reply is visible")
|
||||
expect(
|
||||
|
@ -647,15 +610,12 @@ class TestPostedQuestions(TestUtilities):
|
|||
self.sumo_pages.question_page._get_thread_locked_locator()
|
||||
).to_be_hidden()
|
||||
|
||||
self.logger.info("Posting a question reply")
|
||||
self.logger.info("Adding text inside the textarea field")
|
||||
self.sumo_pages.question_page._add_text_to_post_a_reply_textarea(
|
||||
super().aaq_question_test_data['valid_firefox_question']['question_reply']
|
||||
self.logger.info("Submitting a reply to the question")
|
||||
reply_id_two = self.sumo_pages.aaq_flow.post_question_reply_flow(
|
||||
repliant_username=second_repliant,
|
||||
reply=super().aaq_question_test_data['valid_firefox_question']['question_reply']
|
||||
)
|
||||
|
||||
self.logger.info("Clicking on the 'Post a reply button'")
|
||||
reply_id_two = self.sumo_pages.question_page._click_on_post_reply_button(second_repliant)
|
||||
|
||||
self.logger.info("Verifying that the posted reply is visible")
|
||||
|
||||
expect(
|
||||
|
@ -668,16 +628,14 @@ class TestPostedQuestions(TestUtilities):
|
|||
))
|
||||
|
||||
self.logger.info("Deleting the posted question")
|
||||
self.sumo_pages.question_page._click_delete_this_question_question_tools_option()
|
||||
self.sumo_pages.question_page._click_delete_this_question_button()
|
||||
self.sumo_pages.aaq_flow.deleting_question_flow()
|
||||
|
||||
self.navigate_to_link(
|
||||
posted_question['question_details']['question_page_url']
|
||||
)
|
||||
|
||||
self.logger.info("Deleting the posted question")
|
||||
self.sumo_pages.question_page._click_delete_this_question_question_tools_option()
|
||||
self.sumo_pages.question_page._click_delete_this_question_button()
|
||||
self.sumo_pages.aaq_flow.deleting_question_flow()
|
||||
|
||||
# C2191267, C2191116, C2134136, C2191091
|
||||
@pytest.mark.postedQuestions
|
||||
|
@ -842,16 +800,14 @@ class TestPostedQuestions(TestUtilities):
|
|||
)
|
||||
|
||||
self.logger.info("Deleting the posted question")
|
||||
self.sumo_pages.question_page._click_delete_this_question_question_tools_option()
|
||||
self.sumo_pages.question_page._click_delete_this_question_button()
|
||||
self.sumo_pages.aaq_flow.deleting_question_flow()
|
||||
|
||||
self.navigate_to_link(
|
||||
question_info_one['question_page_url']
|
||||
)
|
||||
|
||||
self.logger.info("Deleting the posted question")
|
||||
self.sumo_pages.question_page._click_delete_this_question_question_tools_option()
|
||||
self.sumo_pages.question_page._click_delete_this_question_button()
|
||||
self.sumo_pages.aaq_flow.deleting_question_flow()
|
||||
|
||||
# To work on adding a check inside the moderate forum content page
|
||||
# C2191491
|
||||
|
@ -958,8 +914,7 @@ class TestPostedQuestions(TestUtilities):
|
|||
))
|
||||
|
||||
self.logger.info("Deleting the posted question")
|
||||
self.sumo_pages.question_page._click_delete_this_question_question_tools_option()
|
||||
self.sumo_pages.question_page._click_delete_this_question_button()
|
||||
self.sumo_pages.aaq_flow.deleting_question_flow()
|
||||
|
||||
# C2191096, C2191098, C2191100
|
||||
@pytest.mark.postedQuestions
|
||||
|
@ -1097,8 +1052,7 @@ class TestPostedQuestions(TestUtilities):
|
|||
))
|
||||
|
||||
self.logger.info("Deleting the posted question")
|
||||
self.sumo_pages.question_page._click_delete_this_question_question_tools_option()
|
||||
self.sumo_pages.question_page._click_delete_this_question_button()
|
||||
self.sumo_pages.aaq_flow.deleting_question_flow()
|
||||
|
||||
# C2191091
|
||||
@pytest.mark.postedQuestions
|
||||
|
@ -1135,8 +1089,7 @@ class TestPostedQuestions(TestUtilities):
|
|||
).to_be_visible()
|
||||
|
||||
self.logger.info("Deleting the posted question")
|
||||
self.sumo_pages.question_page._click_delete_this_question_question_tools_option()
|
||||
self.sumo_pages.question_page._click_delete_this_question_button()
|
||||
self.sumo_pages.aaq_flow.deleting_question_flow()
|
||||
|
||||
# C2191268
|
||||
@pytest.mark.postedQuestions
|
||||
|
@ -1145,12 +1098,10 @@ class TestPostedQuestions(TestUtilities):
|
|||
"question")
|
||||
posted_question = self.post_firefox_product_question_flow('TEST_ACCOUNT_12')
|
||||
|
||||
self.logger.info("Posting a reply to the question")
|
||||
self.sumo_pages.question_page._add_text_to_post_a_reply_textarea(
|
||||
super().aaq_question_test_data['valid_firefox_question']['question_reply']
|
||||
)
|
||||
reply_id_one = self.sumo_pages.question_page._click_on_post_reply_button(
|
||||
posted_question['username_one']
|
||||
self.logger.info("Submitting a reply to the question")
|
||||
reply_id_one = self.sumo_pages.aaq_flow.post_question_reply_flow(
|
||||
repliant_username=posted_question['username_one'],
|
||||
reply=super().aaq_question_test_data['valid_firefox_question']['question_reply']
|
||||
)
|
||||
|
||||
self.logger.info("Signin in with a different non admin user")
|
||||
|
@ -1158,11 +1109,11 @@ class TestPostedQuestions(TestUtilities):
|
|||
self.user_secrets_accounts["TEST_ACCOUNT_13"]
|
||||
))
|
||||
|
||||
self.logger.info("Posting a reply to the question")
|
||||
self.sumo_pages.question_page._add_text_to_post_a_reply_textarea(
|
||||
super().aaq_question_test_data['valid_firefox_question']['question_reply']
|
||||
self.logger.info("Submitting a reply to the question")
|
||||
reply_id_two = self.sumo_pages.aaq_flow.post_question_reply_flow(
|
||||
repliant_username=username_two,
|
||||
reply=super().aaq_question_test_data['valid_firefox_question']['question_reply']
|
||||
)
|
||||
reply_id_two = self.sumo_pages.question_page._click_on_post_reply_button(username_two)
|
||||
|
||||
self.logger.info("Clicking on the self reply menu and verifying that the 'mark as spam' "
|
||||
"option is not displayed for non-admin users")
|
||||
|
@ -1191,8 +1142,7 @@ class TestPostedQuestions(TestUtilities):
|
|||
))
|
||||
|
||||
self.logger.info("Clicking on the 'Mark as Spam' option for one of the replies")
|
||||
self.sumo_pages.question_page._click_on_reply_more_options_button(reply_id_one)
|
||||
self.sumo_pages.question_page._click_on_mark_as_spam_for_a_certain_reply(reply_id_one)
|
||||
self.sumo_pages.aaq_flow.spam_marking_a_reply(reply_id_one)
|
||||
|
||||
self.logger.info("Verifying that the 'Marked as spam' message is displayed for that reply")
|
||||
check.equal(
|
||||
|
@ -1234,8 +1184,7 @@ class TestPostedQuestions(TestUtilities):
|
|||
self.user_secrets_accounts["TEST_ACCOUNT_MODERATOR"]
|
||||
))
|
||||
self.logger.info("Clicking on the 'Mark as Spam' option for one of the replies")
|
||||
self.sumo_pages.question_page._click_on_reply_more_options_button(reply_id_one)
|
||||
self.sumo_pages.question_page._click_on_mark_as_spam_for_a_certain_reply(reply_id_one)
|
||||
self.sumo_pages.aaq_flow.spam_marking_a_reply(reply_id_one)
|
||||
|
||||
self.logger.info("Verifying that the 'Marked as spam' message is no longer displayed")
|
||||
expect(
|
||||
|
@ -1291,8 +1240,7 @@ class TestPostedQuestions(TestUtilities):
|
|||
))
|
||||
|
||||
self.logger.info("Deleting the posted question")
|
||||
self.sumo_pages.question_page._click_delete_this_question_question_tools_option()
|
||||
self.sumo_pages.question_page._click_delete_this_question_button()
|
||||
self.sumo_pages.aaq_flow.deleting_question_flow()
|
||||
|
||||
# Need to expand this to contain additional text format.
|
||||
# C2191270, C2191259
|
||||
|
@ -1305,12 +1253,10 @@ class TestPostedQuestions(TestUtilities):
|
|||
|
||||
page_url = self.get_page_url()
|
||||
|
||||
self.logger.info("Posting a reply to the question")
|
||||
self.sumo_pages.question_page._add_text_to_post_a_reply_textarea(
|
||||
super().aaq_question_test_data['valid_firefox_question']['question_reply']
|
||||
)
|
||||
reply_id = self.sumo_pages.question_page._click_on_post_reply_button(
|
||||
posted_question['username_one']
|
||||
self.logger.info("Submitting a reply to the question")
|
||||
reply_id = self.sumo_pages.aaq_flow.post_question_reply_flow(
|
||||
repliant_username=posted_question['username_one'],
|
||||
reply=super().aaq_question_test_data['valid_firefox_question']['question_reply']
|
||||
)
|
||||
|
||||
self.logger.info("Verifying that the reply contains the correct name and user status")
|
||||
|
@ -1360,12 +1306,12 @@ class TestPostedQuestions(TestUtilities):
|
|||
)
|
||||
|
||||
self.logger.info("Navigating back")
|
||||
self.navigate_back()
|
||||
self.logger.info("Posting a reply to the question")
|
||||
self.sumo_pages.question_page._add_text_to_post_a_reply_textarea(
|
||||
super().aaq_question_test_data['valid_firefox_question']['question_reply']
|
||||
self.navigate_to_link(page_url)
|
||||
|
||||
reply_id = self.sumo_pages.aaq_flow.post_question_reply_flow(
|
||||
repliant_username=username_two,
|
||||
reply=super().aaq_question_test_data['valid_firefox_question']['question_reply']
|
||||
)
|
||||
reply_id = self.sumo_pages.question_page._click_on_post_reply_button(username_two)
|
||||
|
||||
self.logger.info(
|
||||
"Verifying that the reply contains the correct name and no user status")
|
||||
|
@ -1396,17 +1342,11 @@ class TestPostedQuestions(TestUtilities):
|
|||
super().aaq_question_test_data['valid_firefox_question']['question_reply']
|
||||
)
|
||||
|
||||
self.logger.info("Clearing the textarea field")
|
||||
self.sumo_pages.aaq_form_page._clear_the_question_body_textarea_field()
|
||||
|
||||
self.logger.info("Adding new text inside the textarea field")
|
||||
self.sumo_pages.aaq_form_page._add_text_to_aaq_textarea_field(
|
||||
super().aaq_question_test_data['valid_firefox_question']['updated_reply']
|
||||
self.sumo_pages.aaq_flow.editing_reply_flow(
|
||||
reply_body=super().aaq_question_test_data['valid_firefox_question']['updated_reply'],
|
||||
submit_reply=False
|
||||
)
|
||||
|
||||
self.logger.info("Clicking on the 'Cancel' option")
|
||||
self.sumo_pages.aaq_form_page._click_aaq_form_cancel_button()
|
||||
|
||||
self.logger.info("Verifying that the question reply is the original one")
|
||||
check.equal(
|
||||
self.sumo_pages.question_page._get_posted_reply_text(reply_id).strip(),
|
||||
|
@ -1430,17 +1370,10 @@ class TestPostedQuestions(TestUtilities):
|
|||
super().aaq_question_test_data['valid_firefox_question']['question_reply']
|
||||
)
|
||||
|
||||
self.logger.info("Clearing the textarea field")
|
||||
self.sumo_pages.aaq_form_page._clear_the_question_body_textarea_field()
|
||||
|
||||
self.logger.info("Adding new text inside the textarea field")
|
||||
self.sumo_pages.aaq_form_page._add_text_to_aaq_textarea_field(
|
||||
super().aaq_question_test_data['valid_firefox_question']['updated_reply']
|
||||
self.sumo_pages.aaq_flow.editing_reply_flow(
|
||||
reply_body=super().aaq_question_test_data['valid_firefox_question']['updated_reply']
|
||||
)
|
||||
|
||||
self.logger.info("Clicking on the 'Update Answer' button")
|
||||
self.sumo_pages.aaq_form_page._click_on_update_answer_button()
|
||||
|
||||
self.logger.info("Verifying that the reply contains the updated text")
|
||||
check.equal(
|
||||
self.sumo_pages.question_page._get_posted_reply_text(reply_id).strip(),
|
||||
|
@ -1459,8 +1392,7 @@ class TestPostedQuestions(TestUtilities):
|
|||
))
|
||||
|
||||
self.logger.info("Deleting the posted question")
|
||||
self.sumo_pages.question_page._click_delete_this_question_question_tools_option()
|
||||
self.sumo_pages.question_page._click_delete_this_question_button()
|
||||
self.sumo_pages.aaq_flow.deleting_question_flow()
|
||||
|
||||
# C2191272
|
||||
@pytest.mark.postedQuestions
|
||||
|
@ -1473,11 +1405,9 @@ class TestPostedQuestions(TestUtilities):
|
|||
page_url = self.get_page_url()
|
||||
|
||||
self.logger.info("Posting a reply to the question")
|
||||
self.sumo_pages.question_page._add_text_to_post_a_reply_textarea(
|
||||
super().aaq_question_test_data['valid_firefox_question']['question_reply']
|
||||
)
|
||||
reply_id = self.sumo_pages.question_page._click_on_post_reply_button(
|
||||
posted_question['username_one']
|
||||
reply_id = self.sumo_pages.aaq_flow.post_question_reply_flow(
|
||||
repliant_username=posted_question['username_one'],
|
||||
reply=super().aaq_question_test_data['valid_firefox_question']['question_reply']
|
||||
)
|
||||
|
||||
self.logger.info("Verifying that the 'Delete this post' option is not available for self "
|
||||
|
@ -1503,7 +1433,7 @@ class TestPostedQuestions(TestUtilities):
|
|||
)
|
||||
|
||||
self.logger.info("Navigating back")
|
||||
self.navigate_back()
|
||||
self.navigate_to_link(posted_question['question_details']['question_page_url'])
|
||||
|
||||
if username == 'TEST_ACCOUNT_13':
|
||||
username_two = self.start_existing_session(super().username_extraction_from_email(
|
||||
|
@ -1511,13 +1441,14 @@ class TestPostedQuestions(TestUtilities):
|
|||
))
|
||||
|
||||
self.logger.info("Posting a reply to the question")
|
||||
self.sumo_pages.question_page._add_text_to_post_a_reply_textarea(
|
||||
super().aaq_question_test_data['valid_firefox_question']['question_reply']
|
||||
self.sumo_pages.aaq_flow.post_question_reply_flow(
|
||||
repliant_username=username_two,
|
||||
reply=super().aaq_question_test_data['valid_firefox_question']['question_reply']
|
||||
)
|
||||
self.sumo_pages.question_page._click_on_post_reply_button(username_two)
|
||||
|
||||
self.logger.info("Verifying that the 'Delete this post' option is not available for "
|
||||
"replies posted by others")
|
||||
self.sumo_pages.question_page._click_on_reply_more_options_button(reply_id)
|
||||
expect(
|
||||
self.sumo_pages.question_page._get_delete_this_post_reply_locator(reply_id)
|
||||
).to_be_hidden()
|
||||
|
@ -1540,35 +1471,21 @@ class TestPostedQuestions(TestUtilities):
|
|||
)
|
||||
|
||||
self.logger.info("Navigating back")
|
||||
self.navigate_back()
|
||||
self.navigate_to_link(posted_question['question_details']['question_page_url'])
|
||||
|
||||
self.logger.info("Signing in with an admin account")
|
||||
self.start_existing_session(super().username_extraction_from_email(
|
||||
self.user_secrets_accounts["TEST_ACCOUNT_MODERATOR"]
|
||||
))
|
||||
|
||||
self.logger.info("Clicking on the more options for the reply")
|
||||
self.sumo_pages.question_page._click_on_reply_more_options_button(reply_id)
|
||||
|
||||
self.logger.info("Clicking on the 'Delete this post' option")
|
||||
self.sumo_pages.question_page._click_on_delete_this_post_for_a_certain_reply(reply_id)
|
||||
|
||||
self.logger.info("Clicking on the cancel delete button")
|
||||
self.sumo_pages.question_page._click_on_cancel_delete_button()
|
||||
self.sumo_pages.aaq_flow.delete_question_reply(reply_id, delete_reply=False)
|
||||
|
||||
self.logger.info("Verifying that the reply was not deleted")
|
||||
expect(
|
||||
self.sumo_pages.question_page._get_posted_reply_locator(reply_id)
|
||||
).to_be_visible()
|
||||
|
||||
self.logger.info("Clicking on the more options for the reply")
|
||||
self.sumo_pages.question_page._click_on_reply_more_options_button(reply_id)
|
||||
|
||||
self.logger.info("Clicking on the 'Delete this post' option")
|
||||
self.sumo_pages.question_page._click_on_delete_this_post_for_a_certain_reply(reply_id)
|
||||
|
||||
self.logger.info("Clicking on the delete button")
|
||||
self.sumo_pages.question_page._click_delete_this_question_button()
|
||||
self.sumo_pages.aaq_flow.delete_question_reply(reply_id, delete_reply=True)
|
||||
|
||||
self.logger.info("Verifying that the reply is no longer displayed")
|
||||
expect(
|
||||
|
@ -1576,8 +1493,7 @@ class TestPostedQuestions(TestUtilities):
|
|||
).to_be_hidden()
|
||||
|
||||
self.logger.info("Deleting the posted question")
|
||||
self.sumo_pages.question_page._click_delete_this_question_question_tools_option()
|
||||
self.sumo_pages.question_page._click_delete_this_question_button()
|
||||
self.sumo_pages.aaq_flow.deleting_question_flow()
|
||||
|
||||
# C2192383, C2191224
|
||||
# Need to re-verify this for signed out case before submitting this
|
||||
|
@ -1663,8 +1579,7 @@ class TestPostedQuestions(TestUtilities):
|
|||
).to_be_hidden()
|
||||
|
||||
self.logger.info("Deleting the posted question")
|
||||
self.sumo_pages.question_page._click_delete_this_question_question_tools_option()
|
||||
self.sumo_pages.question_page._click_delete_this_question_button()
|
||||
self.sumo_pages.aaq_flow.deleting_question_flow()
|
||||
|
||||
# C2192384
|
||||
@pytest.mark.postedQuestions
|
||||
|
@ -1674,11 +1589,9 @@ class TestPostedQuestions(TestUtilities):
|
|||
posted_question = self.post_firefox_product_question_flow('TEST_ACCOUNT_12')
|
||||
|
||||
self.logger.info("Posting a reply to the question")
|
||||
self.sumo_pages.question_page._add_text_to_post_a_reply_textarea(
|
||||
super().aaq_question_test_data['valid_firefox_question']['question_reply']
|
||||
)
|
||||
reply_id = self.sumo_pages.question_page._click_on_post_reply_button(
|
||||
posted_question['username_one']
|
||||
reply_id = self.sumo_pages.aaq_flow.post_question_reply_flow(
|
||||
repliant_username=posted_question['username_one'],
|
||||
reply=super().aaq_question_test_data['valid_firefox_question']['question_reply']
|
||||
)
|
||||
|
||||
self.logger.info("Deleting user session")
|
||||
|
@ -1782,8 +1695,7 @@ class TestPostedQuestions(TestUtilities):
|
|||
)
|
||||
|
||||
self.logger.info("Deleting the posted question")
|
||||
self.sumo_pages.question_page._click_delete_this_question_question_tools_option()
|
||||
self.sumo_pages.question_page._click_delete_this_question_button()
|
||||
self.sumo_pages.aaq_flow.deleting_question_flow()
|
||||
|
||||
# Need to add test for preview as well.
|
||||
# C2260447, C2260448, C2191244, C2191242
|
||||
|
@ -1795,16 +1707,14 @@ class TestPostedQuestions(TestUtilities):
|
|||
|
||||
# Using a user which doesn't have any special permissions applied & which doesn't belong to
|
||||
# any group in order to catch cases like https://github.com/mozilla/sumo/issues/1676
|
||||
posted_question = self.post_firefox_product_question_flow('TEST_ACCOUNT_MESSAGE_6')
|
||||
posted_question = self.post_firefox_product_question_flow('TEST_ACCOUNT_12')
|
||||
question_id = self.sumo_pages.question_page._get_question_id()
|
||||
|
||||
if quote_on == "reply":
|
||||
self.logger.info("Posting a reply to the question")
|
||||
self.sumo_pages.question_page._add_text_to_post_a_reply_textarea(
|
||||
super().aaq_question_test_data['valid_firefox_question']['question_reply']
|
||||
)
|
||||
reply_id = self.sumo_pages.question_page._click_on_post_reply_button(
|
||||
posted_question['username_one']
|
||||
reply_id = self.sumo_pages.aaq_flow.post_question_reply_flow(
|
||||
repliant_username=posted_question['username_one'],
|
||||
reply=super().aaq_question_test_data['valid_firefox_question']['question_reply']
|
||||
)
|
||||
|
||||
username_two = self.start_existing_session(super().username_extraction_from_email(
|
||||
|
@ -1812,25 +1722,21 @@ class TestPostedQuestions(TestUtilities):
|
|||
))
|
||||
|
||||
if quote_on == "reply":
|
||||
self.logger.info("Clicking on the more options for the reply")
|
||||
self.sumo_pages.question_page._click_on_reply_more_options_button(reply_id)
|
||||
|
||||
self.logger.info("Clicking on 'Quote' option")
|
||||
self.sumo_pages.question_page._click_on_quote_for_a_certain_reply(reply_id)
|
||||
self.logger.info("Posting a quoted reply for question reply")
|
||||
quote_id = self.sumo_pages.aaq_flow.post_question_reply_flow(
|
||||
repliant_username=username_two,
|
||||
reply=super().aaq_question_test_data['valid_firefox_question']['updated_reply'],
|
||||
quoted_reply=True,
|
||||
reply_for_id=reply_id
|
||||
)
|
||||
else:
|
||||
self.logger.info("Clicking on the more options for the question")
|
||||
self.sumo_pages.question_page._click_on_reply_more_options_button(question_id)
|
||||
|
||||
self.logger.info("Clicking on 'Quote' option")
|
||||
self.sumo_pages.question_page._click_on_quote_for_a_certain_reply(question_id)
|
||||
|
||||
self.logger.info("Adding test to the textarea field")
|
||||
self.sumo_pages.question_page._type_inside_the_post_a_reply_textarea(
|
||||
super().aaq_question_test_data['valid_firefox_question']['updated_reply']
|
||||
)
|
||||
|
||||
self.logger.info("Posting the reply")
|
||||
quote_id = self.sumo_pages.question_page._click_on_post_reply_button(username_two)
|
||||
self.logger.info("Posting a quoted reply for question")
|
||||
quote_id = self.sumo_pages.aaq_flow.post_question_reply_flow(
|
||||
repliant_username=username_two,
|
||||
reply=super().aaq_question_test_data['valid_firefox_question']['updated_reply'],
|
||||
quoted_reply=True,
|
||||
reply_for_id=question_id
|
||||
)
|
||||
|
||||
self.logger.info("Verifying that the original repliant is displayed inside the quote")
|
||||
check.is_in(
|
||||
|
@ -1881,25 +1787,21 @@ class TestPostedQuestions(TestUtilities):
|
|||
))
|
||||
|
||||
if quote_on == "reply":
|
||||
self.logger.info("Clicking on the more options for the reply")
|
||||
self.sumo_pages.question_page._click_on_reply_more_options_button(reply_id)
|
||||
|
||||
self.logger.info("Clicking on 'Quote' option")
|
||||
self.sumo_pages.question_page._click_on_quote_for_a_certain_reply(reply_id)
|
||||
self.logger.info("Posting a quoted reply for question reply")
|
||||
quote_id = self.sumo_pages.aaq_flow.post_question_reply_flow(
|
||||
repliant_username=username_two,
|
||||
reply=super().aaq_question_test_data['valid_firefox_question']['updated_reply'],
|
||||
quoted_reply=True,
|
||||
reply_for_id=reply_id
|
||||
)
|
||||
else:
|
||||
self.logger.info("Clicking on the more options for the reply")
|
||||
self.sumo_pages.question_page._click_on_reply_more_options_button(question_id)
|
||||
|
||||
self.logger.info("Clicking on 'Quote' option")
|
||||
self.sumo_pages.question_page._click_on_quote_for_a_certain_reply(question_id)
|
||||
|
||||
self.logger.info("Adding test to the textarea field")
|
||||
self.sumo_pages.question_page._type_inside_the_post_a_reply_textarea(
|
||||
super().aaq_question_test_data['valid_firefox_question']['updated_reply']
|
||||
)
|
||||
|
||||
self.logger.info("Posting the reply")
|
||||
quote_id = self.sumo_pages.question_page._click_on_post_reply_button(username_two)
|
||||
self.logger.info("Posting a quoted reply for question reply")
|
||||
quote_id = self.sumo_pages.aaq_flow.post_question_reply_flow(
|
||||
repliant_username=username_two,
|
||||
reply=super().aaq_question_test_data['valid_firefox_question']['updated_reply'],
|
||||
quoted_reply=True,
|
||||
reply_for_id=question_id
|
||||
)
|
||||
|
||||
self.logger.info("Verifying that the original repliant is displayed inside the quote")
|
||||
check.is_in(
|
||||
|
@ -1945,8 +1847,7 @@ class TestPostedQuestions(TestUtilities):
|
|||
)
|
||||
|
||||
self.logger.info("Deleting the posted question")
|
||||
self.sumo_pages.question_page._click_delete_this_question_question_tools_option()
|
||||
self.sumo_pages.question_page._click_delete_this_question_button()
|
||||
self.sumo_pages.aaq_flow.deleting_question_flow()
|
||||
|
||||
# To add tests for "I have this problem, too" option
|
||||
# C2191117, C2191223, C2191226
|
||||
|
@ -2004,12 +1905,9 @@ class TestPostedQuestions(TestUtilities):
|
|||
self.user_secrets_accounts['TEST_ACCOUNT_12']
|
||||
))
|
||||
|
||||
self.logger.info("Posting a reply to the question")
|
||||
self.sumo_pages.question_page._add_text_to_post_a_reply_textarea(
|
||||
super().aaq_question_test_data['valid_firefox_question']['question_reply']
|
||||
)
|
||||
reply_id = self.sumo_pages.question_page._click_on_post_reply_button(
|
||||
posted_question['username_one']
|
||||
reply_id = self.sumo_pages.aaq_flow.post_question_reply_flow(
|
||||
repliant_username=posted_question['username_one'],
|
||||
reply=super().aaq_question_test_data['valid_firefox_question']['question_reply']
|
||||
)
|
||||
|
||||
self.logger.info("Deleting user session")
|
||||
|
@ -2080,8 +1978,7 @@ class TestPostedQuestions(TestUtilities):
|
|||
))
|
||||
|
||||
self.logger.info("Deleting the posted question")
|
||||
self.sumo_pages.question_page._click_delete_this_question_question_tools_option()
|
||||
self.sumo_pages.question_page._click_delete_this_question_button()
|
||||
self.sumo_pages.aaq_flow.deleting_question_flow()
|
||||
|
||||
# C2191227
|
||||
# Currently fails due to https://github.com/mozilla/sumo/issues/1216
|
||||
|
@ -2247,8 +2144,7 @@ class TestPostedQuestions(TestUtilities):
|
|||
)
|
||||
|
||||
self.logger.info("Deleting the posted question")
|
||||
self.sumo_pages.question_page._click_delete_this_question_question_tools_option()
|
||||
self.sumo_pages.question_page._click_delete_this_question_button()
|
||||
self.sumo_pages.aaq_flow.deleting_question_flow()
|
||||
|
||||
# C2260449, C2260450, C2191243, C2191245
|
||||
@pytest.mark.postedQuestions
|
||||
|
@ -2264,11 +2160,9 @@ class TestPostedQuestions(TestUtilities):
|
|||
|
||||
if flagged_content == "question_reply":
|
||||
self.logger.info("Posting a reply to the question")
|
||||
self.sumo_pages.question_page._add_text_to_post_a_reply_textarea(
|
||||
super().aaq_question_test_data['valid_firefox_question']['question_reply']
|
||||
)
|
||||
reply_id = self.sumo_pages.question_page._click_on_post_reply_button(
|
||||
posted_question['username_one']
|
||||
reply_id = self.sumo_pages.aaq_flow.post_question_reply_flow(
|
||||
repliant_username=posted_question['username_one'],
|
||||
reply=super().aaq_question_test_data['valid_firefox_question']['question_reply']
|
||||
)
|
||||
|
||||
self.logger.info("Deleting user session")
|
||||
|
@ -2306,32 +2200,15 @@ class TestPostedQuestions(TestUtilities):
|
|||
))
|
||||
|
||||
if flagged_content == "question_content":
|
||||
self.logger.info("Clicking on the more options for the question")
|
||||
self.sumo_pages.question_page._click_on_reply_more_options_button(
|
||||
self.sumo_pages.question_page._get_question_id()
|
||||
)
|
||||
|
||||
self.logger.info("Clicking on the report abuse option")
|
||||
self.sumo_pages.question_page._click_on_report_abuse_for_a_certain_reply(
|
||||
self.sumo_pages.question_page._get_question_id()
|
||||
self.sumo_pages.aaq_flow.report_question_abuse(
|
||||
answer_id=self.sumo_pages.question_page._get_question_id(),
|
||||
text=super().aaq_question_test_data['valid_firefox_question']['report_abuse_text']
|
||||
)
|
||||
else:
|
||||
self.logger.info("Clicking on the more options for the question reply")
|
||||
self.sumo_pages.question_page._click_on_reply_more_options_button(reply_id)
|
||||
|
||||
self.logger.info("Clicking on the report abuse option")
|
||||
self.sumo_pages.question_page._click_on_report_abuse_for_a_certain_reply(reply_id)
|
||||
|
||||
self.logger.info("Adding text inside the report abuse textarea field")
|
||||
self.sumo_pages.question_page._add_text_to_report_abuse_textarea(
|
||||
super().aaq_question_test_data['valid_firefox_question']['report_abuse_text']
|
||||
)
|
||||
|
||||
self.logger.info("Clicking on submit button")
|
||||
self.sumo_pages.question_page._click_on_report_abuse_submit_button()
|
||||
|
||||
self.logger.info("Closing the report this modal button")
|
||||
self.sumo_pages.question_page._click_abuse_modal_close_button()
|
||||
self.sumo_pages.aaq_flow.report_question_abuse(
|
||||
answer_id=reply_id,
|
||||
text=super().aaq_question_test_data['valid_firefox_question']['report_abuse_text']
|
||||
)
|
||||
|
||||
if username == "TEST_ACCOUNT_13":
|
||||
self.logger.info("Signing in with a admin account")
|
||||
|
@ -2374,8 +2251,7 @@ class TestPostedQuestions(TestUtilities):
|
|||
self.navigate_to_link(posted_question['question_details']['question_page_url'])
|
||||
|
||||
self.logger.info("Deleting the posted question")
|
||||
self.sumo_pages.question_page._click_delete_this_question_question_tools_option()
|
||||
self.sumo_pages.question_page._click_delete_this_question_button()
|
||||
self.sumo_pages.aaq_flow.deleting_question_flow()
|
||||
|
||||
# C2191261
|
||||
@pytest.mark.postedQuestions
|
||||
|
@ -2496,8 +2372,7 @@ class TestPostedQuestions(TestUtilities):
|
|||
self.user_secrets_accounts["TEST_ACCOUNT_MODERATOR"]
|
||||
))
|
||||
self.logger.info("Deleting the posted question")
|
||||
self.sumo_pages.question_page._click_delete_this_question_question_tools_option()
|
||||
self.sumo_pages.question_page._click_delete_this_question_button()
|
||||
self.sumo_pages.aaq_flow.deleting_question_flow()
|
||||
|
||||
def post_firefox_product_question_flow(self, username: str):
|
||||
username_one = self.start_existing_session(super().username_extraction_from_email(
|
||||
|
|
|
@ -29,6 +29,8 @@ class TestKBArticleShowHistory(TestUtilities, KBArticleShowHistoryPageMessages):
|
|||
self.logger.info("Create a new simple article")
|
||||
article_details = self.sumo_pages.submit_kb_article_flow.submit_simple_kb_article()
|
||||
|
||||
article_url = self.get_page_url()
|
||||
|
||||
self.logger.info("Fetching the revision id")
|
||||
revision_id = self.sumo_pages.kb_article_show_history_page._get_last_revision_id()
|
||||
revision_id_number = self.number_extraction_from_string(revision_id)
|
||||
|
@ -53,7 +55,7 @@ class TestKBArticleShowHistory(TestUtilities, KBArticleShowHistoryPageMessages):
|
|||
)
|
||||
|
||||
self.logger.info("Navigating back")
|
||||
self.navigate_back()
|
||||
self.navigate_to_link(article_url)
|
||||
|
||||
self.logger.info("Verifying that the delete button for the article is not displayed")
|
||||
expect(
|
||||
|
@ -74,7 +76,7 @@ class TestKBArticleShowHistory(TestUtilities, KBArticleShowHistoryPageMessages):
|
|||
)
|
||||
|
||||
self.logger.info("Navigating back")
|
||||
self.navigate_back()
|
||||
self.navigate_to_link(article_url)
|
||||
|
||||
self.logger.info("Delete user session")
|
||||
self.delete_cookies()
|
||||
|
@ -89,7 +91,7 @@ class TestKBArticleShowHistory(TestUtilities, KBArticleShowHistoryPageMessages):
|
|||
FxAPageMessages.AUTH_PAGE_URL in self.get_page_url()
|
||||
)
|
||||
self.logger.info("Navigating back")
|
||||
self.navigate_back()
|
||||
self.navigate_to_link(article_url)
|
||||
|
||||
self.logger.info("Verifying that manually navigating to the delete endpoint returns the "
|
||||
"auth page")
|
||||
|
@ -104,7 +106,7 @@ class TestKBArticleShowHistory(TestUtilities, KBArticleShowHistoryPageMessages):
|
|||
)
|
||||
|
||||
self.logger.info("Navigating back")
|
||||
self.navigate_back()
|
||||
self.navigate_to_link(article_url)
|
||||
|
||||
self.logger.info("Verifying that the delete button is not available for the only revision")
|
||||
expect(
|
||||
|
@ -250,6 +252,8 @@ class TestKBArticleShowHistory(TestUtilities, KBArticleShowHistoryPageMessages):
|
|||
self.logger.info("Create a new simple article")
|
||||
self.sumo_pages.submit_kb_article_flow.submit_simple_kb_article()
|
||||
|
||||
article_url = self.get_page_url()
|
||||
|
||||
self.logger.info("Verifying that no users are added inside the contributors list")
|
||||
expect(
|
||||
self.sumo_pages.kb_article_show_history_page._get_all_contributors_locator()
|
||||
|
@ -334,7 +338,7 @@ class TestKBArticleShowHistory(TestUtilities, KBArticleShowHistoryPageMessages):
|
|||
)
|
||||
|
||||
self.logger.info("Navigating back")
|
||||
self.navigate_back()
|
||||
self.navigate_to_link(article_url)
|
||||
|
||||
self.logger.info("Clicking on the Article menu option")
|
||||
self.sumo_pages.kb_article_page._click_on_article_option()
|
||||
|
@ -367,7 +371,7 @@ class TestKBArticleShowHistory(TestUtilities, KBArticleShowHistoryPageMessages):
|
|||
)
|
||||
|
||||
self.logger.info("Navigating back")
|
||||
self.navigate_back()
|
||||
self.navigate_to_link(article_url)
|
||||
|
||||
self.logger.info("Signing in with a normal account")
|
||||
self.start_existing_session(super().username_extraction_from_email(
|
||||
|
|
|
@ -392,7 +392,7 @@ class TestKBArticleCreationAndAccess(TestUtilities, KBArticleRevision):
|
|||
)
|
||||
|
||||
self.logger.info("Navigating back to the article page and signing in with admin")
|
||||
self.navigate_back()
|
||||
self.navigate_to_link(article_url)
|
||||
|
||||
expect(
|
||||
self.page
|
||||
|
@ -429,7 +429,7 @@ class TestKBArticleCreationAndAccess(TestUtilities, KBArticleRevision):
|
|||
)
|
||||
|
||||
self.logger.info("Navigating back")
|
||||
self.navigate_back()
|
||||
self.navigate_to_link(article_url)
|
||||
|
||||
expect(
|
||||
self.page
|
||||
|
@ -455,7 +455,7 @@ class TestKBArticleCreationAndAccess(TestUtilities, KBArticleRevision):
|
|||
)
|
||||
|
||||
self.logger.info("Navigating back to the article page")
|
||||
self.navigate_back()
|
||||
self.navigate_to_link(article_url)
|
||||
|
||||
expect(
|
||||
self.page
|
||||
|
|
|
@ -12,7 +12,6 @@ class TestFooter(TestUtilities):
|
|||
@pytest.mark.footerSectionTests
|
||||
def test_all_footer_links_are_working(self):
|
||||
self.logger.info("Verifying that footer links are not broken")
|
||||
|
||||
for link in self.sumo_pages.footer_section._get_all_footer_links():
|
||||
relative_url = link.get_attribute("href")
|
||||
|
||||
|
|
|
@ -16,8 +16,8 @@ class TestHomepage(TestUtilities):
|
|||
def test_join_our_community_card_learn_more_redirects_to_contribute_page(self):
|
||||
self.logger.info("Clicking on the 'Learn More' option")
|
||||
self.sumo_pages.homepage._click_learn_more_option()
|
||||
self.logger.info("Verifying that we are redirected to the 'Contribute' page successfully")
|
||||
|
||||
self.logger.info("Verifying that we are redirected to the 'Contribute' page successfully")
|
||||
assert (
|
||||
self.get_page_url()
|
||||
== ContributePageMessages.STAGE_CONTRIBUTE_PAGE_URL
|
||||
|
@ -29,7 +29,6 @@ class TestHomepage(TestUtilities):
|
|||
self.logger.info(
|
||||
"Verifying that the 'Join Our Community' card has the correct strings applied"
|
||||
)
|
||||
|
||||
assert (
|
||||
self.sumo_pages.homepage._get_community_card_title()
|
||||
== HomepageMessages.JOIN_OUR_COMMUNITY_CARD_TITLE
|
||||
|
@ -43,30 +42,22 @@ class TestHomepage(TestUtilities):
|
|||
self.logger.info(
|
||||
"Verifying that the correct number of featured articles are present on the homepage"
|
||||
)
|
||||
|
||||
check.equal(
|
||||
self.sumo_pages.homepage._get_number_of_featured_articles(),
|
||||
HomepageMessages.EXPECTED_FEATURED_ARTICLES_COUNT,
|
||||
"Unexpected featured article count"
|
||||
)
|
||||
|
||||
self.logger.info(
|
||||
"Clicking on each featured article card and verifying that the user is redirected to "
|
||||
"the correct article page."
|
||||
)
|
||||
self.logger.info("Clicking on each featured article card and verifying that the user is "
|
||||
"redirected to the correct article page.")
|
||||
counter = 0
|
||||
for featured_article in self.sumo_pages.homepage._get_featured_articles_titles():
|
||||
articles_names = self.sumo_pages.homepage._get_featured_articles_titles()
|
||||
|
||||
self.logger.info(
|
||||
f"Clicking on: {articles_names[counter]} article card"
|
||||
)
|
||||
self.logger.info(f"Clicking on: {articles_names[counter]} article card")
|
||||
self.sumo_pages.homepage._click_on_a_featured_card(counter)
|
||||
|
||||
self.logger.info(
|
||||
"Verifying that the correct article title is displayed."
|
||||
)
|
||||
|
||||
self.logger.info("Verifying that the correct article title is displayed.")
|
||||
assert (
|
||||
self.sumo_pages.kb_article_page._get_text_of_article_title()
|
||||
== articles_names[counter]
|
||||
|
@ -80,10 +71,8 @@ class TestHomepage(TestUtilities):
|
|||
# C873774
|
||||
@pytest.mark.homePageTests
|
||||
def test_product_cards_are_functional_and_redirect_to_the_proper_support_page(self):
|
||||
self.logger.info(
|
||||
"Verifying that the product cards are redirecting to the correct support page"
|
||||
)
|
||||
|
||||
self.logger.info("Verifying that the product cards are redirecting to the correct "
|
||||
"support page")
|
||||
card_titles = self.sumo_pages.homepage._get_text_of_product_card_titles()
|
||||
counter = 0
|
||||
for product_card in card_titles:
|
||||
|
|
|
@ -23,19 +23,16 @@ class TestMessagingSystem(TestUtilities):
|
|||
))
|
||||
|
||||
self.logger.info("Navigating to the inbox page")
|
||||
|
||||
self.sumo_pages.top_navbar._click_on_inbox_option()
|
||||
|
||||
self.logger.info(
|
||||
"Clearing the inbox if there are messages"
|
||||
)
|
||||
|
||||
if self.sumo_pages.inbox_page._are_inbox_messages_displayed():
|
||||
self.sumo_pages.inbox_page._delete_all_inbox_messages()
|
||||
self.logger.info("Messages found. Clearing the list")
|
||||
|
||||
self.logger.info("Verifying that the correct page message is displayed")
|
||||
|
||||
self.logger.info("Verifying that the correct message is displayed")
|
||||
check.equal(
|
||||
self.sumo_pages.inbox_page._get_text_of_inbox_no_message_header(),
|
||||
InboxPageMessages.NO_MESSAGES_IN_INBOX_TEXT,
|
||||
|
@ -47,20 +44,15 @@ class TestMessagingSystem(TestUtilities):
|
|||
)
|
||||
|
||||
self.logger.info("Navigating to the 'Sent Messages' page")
|
||||
|
||||
self.sumo_pages.mess_system_user_navbar._click_on_messaging_system_navbar_sent_messages()
|
||||
|
||||
self.logger.info(
|
||||
"Verifying if there are messages displayed inside the inbox section. "
|
||||
"If there are, we are clearing them all"
|
||||
)
|
||||
|
||||
self.logger.info("Verifying if there are messages displayed inside the inbox section. If "
|
||||
"there are, we are clearing them all")
|
||||
if self.sumo_pages.sent_message_page._are_sent_messages_displayed():
|
||||
self.sumo_pages.sent_message_page._delete_all_displayed_sent_messages()
|
||||
self.logger.info("Messages found. Clearing the list")
|
||||
|
||||
self.logger.info("Verifying that the correct page message is displayed")
|
||||
|
||||
check.equal(
|
||||
self.sumo_pages.sent_message_page._get_sent_messages_no_message_text(),
|
||||
SentMessagesPageMessages.NO_MESSAGES_IN_SENT_MESSAGES_TEXT,
|
||||
|
@ -79,13 +71,14 @@ class TestMessagingSystem(TestUtilities):
|
|||
self.user_secrets_accounts["TEST_ACCOUNT_MESSAGE_2"]
|
||||
)
|
||||
|
||||
self.logger.info("Signing in with user one")
|
||||
self.logger.info("Signing in with a simple user account")
|
||||
self.start_existing_session(super().username_extraction_from_email(
|
||||
self.user_secrets_accounts["TEST_ACCOUNT_MESSAGE_1"]
|
||||
))
|
||||
|
||||
user_one = self.sumo_pages.top_navbar._get_text_of_logged_in_username()
|
||||
|
||||
self.logger.info("Navigating to the profile page for user two")
|
||||
self.navigate_to_link(
|
||||
MyProfileMessages.get_my_profile_stage_url(username=user_two)
|
||||
)
|
||||
|
@ -93,9 +86,7 @@ class TestMessagingSystem(TestUtilities):
|
|||
self.logger.info("Clicking on the 'Private Message button'")
|
||||
self.sumo_pages.my_profile_page._click_on_private_message_button()
|
||||
|
||||
self.logger.info(
|
||||
"Verifying that the receiver is automatically added inside the 'To' field"
|
||||
)
|
||||
self.logger.info("Verifying that the receiver is automatically added inside the To field")
|
||||
# Firefox GH runner fails here. We are running this assertion only in Chrome for now
|
||||
if self.requested_browser == "chrome":
|
||||
assert self.sumo_pages.new_message_page._get_user_to_text() == user_two, (
|
||||
|
@ -103,14 +94,11 @@ class TestMessagingSystem(TestUtilities):
|
|||
f"Received: {self.sumo_pages.new_message_page._get_user_to_text()}"
|
||||
)
|
||||
|
||||
self.logger.info("Adding text into the new message textarea field")
|
||||
self.sumo_pages.new_message_page._fill_into_new_message_body_textarea(
|
||||
self.user_message_test_data["valid_user_message"]["message"]
|
||||
self.logger.info("Sending a message to the user")
|
||||
self.sumo_pages.messaging_system_flow.complete_send_message_form_with_data(
|
||||
message_body=self.user_message_test_data["valid_user_message"]["message"]
|
||||
)
|
||||
|
||||
self.logger.info("Clicking on the 'Send' button")
|
||||
self.sumo_pages.new_message_page._click_on_new_message_send_button()
|
||||
|
||||
self.logger.info("Verifying that the correct message sent banner is displayed")
|
||||
check.equal(
|
||||
self.sumo_pages.inbox_page._get_text_inbox_page_message_banner_text(),
|
||||
|
@ -122,10 +110,8 @@ class TestMessagingSystem(TestUtilities):
|
|||
f"{self.sumo_pages.inbox_page._get_text_inbox_page_message_banner_text()}",
|
||||
)
|
||||
|
||||
self.logger.info(
|
||||
"Clicking on the 'Sent Messages option' "
|
||||
"and verifying that the message was successfully sent"
|
||||
)
|
||||
self.logger.info("Clicking on the 'Sent Messages option' and verifying that the message "
|
||||
"was successfully sent")
|
||||
self.sumo_pages.mess_system_user_navbar._click_on_messaging_system_navbar_sent_messages()
|
||||
|
||||
self.logger.info("Verifying that the sent message is displayed")
|
||||
|
@ -133,11 +119,8 @@ class TestMessagingSystem(TestUtilities):
|
|||
username=user_two
|
||||
)).to_be_visible()
|
||||
|
||||
self.logger.info(
|
||||
"Deleting the message from the sent messages link "
|
||||
"and verifying that the message is no longer displayed"
|
||||
)
|
||||
|
||||
self.logger.info("Deleting the message from the sent messages link and verifying that "
|
||||
"the message is no longer displayed")
|
||||
self.sumo_pages.sent_message_page._click_on_sent_message_delete_button(username=user_two)
|
||||
self.sumo_pages.sent_message_page._click_on_delete_page_delete_button()
|
||||
|
||||
|
@ -157,24 +140,19 @@ class TestMessagingSystem(TestUtilities):
|
|||
).to_be_hidden()
|
||||
|
||||
self.logger.info("Signing in with the user which received the message")
|
||||
|
||||
self.start_existing_session(super().username_extraction_from_email(
|
||||
self.user_secrets_accounts["TEST_ACCOUNT_MESSAGE_2"]
|
||||
))
|
||||
|
||||
self.logger.info(
|
||||
"Accessing the Inbox section " "and verifying that the message was received"
|
||||
)
|
||||
self.logger.info("Accessing the Inbox section and verifying that the message was received")
|
||||
self.sumo_pages.top_navbar._click_on_inbox_option()
|
||||
|
||||
expect(self.sumo_pages.inbox_page._inbox_message(
|
||||
username=user_one
|
||||
)).to_be_visible()
|
||||
|
||||
self.logger.info(
|
||||
"Deleting the message and verifying that it "
|
||||
"is no longer displayed inside the inbox section"
|
||||
)
|
||||
self.logger.info("Deleting the message and verifying that it is no longer displayed "
|
||||
"inside the inbox section")
|
||||
self.sumo_pages.inbox_page._click_on_inbox_message_delete_button(username=user_one)
|
||||
|
||||
self.sumo_pages.inbox_page._click_on_delete_page_delete_button()
|
||||
|
@ -184,7 +162,6 @@ class TestMessagingSystem(TestUtilities):
|
|||
).to_be_hidden()
|
||||
|
||||
self.logger.info("Verifying that the correct banner is displayed")
|
||||
|
||||
check.equal(
|
||||
self.sumo_pages.sent_message_page._get_sent_messages_page_deleted_banner_text(),
|
||||
SentMessagesPageMessages.DELETE_MESSAGE_BANNER_TEXT,
|
||||
|
@ -209,16 +186,13 @@ class TestMessagingSystem(TestUtilities):
|
|||
|
||||
user_one = self.sumo_pages.top_navbar._get_text_of_logged_in_username()
|
||||
|
||||
self.logger.info(
|
||||
"Accessing the 'New Message page " "and sending a message to another user'"
|
||||
)
|
||||
self.logger.info("Accessing the New Message page and sending a message to another user")
|
||||
self.sumo_pages.top_navbar._click_on_inbox_option()
|
||||
self.sumo_pages.mess_system_user_navbar._click_on_messaging_system_navbar_new_message()
|
||||
self.sumo_pages.messaging_system_flow.complete_send_message_form_with_data(
|
||||
recipient_username=test_user,
|
||||
message_body=super().user_message_test_data["valid_user_message"]["message"],
|
||||
)
|
||||
self.sumo_pages.new_message_page._click_on_new_message_send_button()
|
||||
|
||||
self.logger.info("Verifying that the correct banner is displayed")
|
||||
check.equal(
|
||||
|
@ -231,9 +205,8 @@ class TestMessagingSystem(TestUtilities):
|
|||
f"{self.sumo_pages.inbox_page._get_text_inbox_page_message_banner_text()}",
|
||||
)
|
||||
|
||||
self.logger.info(
|
||||
"Verifying that the sent message is displayed inside the 'sent messages' page"
|
||||
)
|
||||
self.logger.info("Verifying that the sent message is displayed inside the 'sent "
|
||||
"messages' page")
|
||||
self.sumo_pages.mess_system_user_navbar._click_on_messaging_system_navbar_sent_messages()
|
||||
|
||||
expect(self.sumo_pages.sent_message_page._sent_messages(test_user)).to_be_visible()
|
||||
|
@ -241,11 +214,8 @@ class TestMessagingSystem(TestUtilities):
|
|||
self.logger.info("Clearing the sent messages list")
|
||||
self.sumo_pages.sent_message_page._delete_all_displayed_sent_messages()
|
||||
|
||||
self.logger.info(
|
||||
"Signing in with the receiver account and verifying that the message "
|
||||
"is displayed inside the inbox section"
|
||||
)
|
||||
|
||||
self.logger.info("Signing in with the receiver account and verifying that the message is "
|
||||
"displayed inside the inbox section")
|
||||
self.start_existing_session(super().username_extraction_from_email(
|
||||
self.user_secrets_accounts["TEST_ACCOUNT_MESSAGE_4"]
|
||||
))
|
||||
|
@ -257,7 +227,6 @@ class TestMessagingSystem(TestUtilities):
|
|||
)).to_be_visible()
|
||||
|
||||
self.logger.info("Clearing the inbox")
|
||||
|
||||
self.sumo_pages.inbox_page._delete_all_inbox_messages()
|
||||
|
||||
# C891412, C891413
|
||||
|
@ -274,22 +243,19 @@ class TestMessagingSystem(TestUtilities):
|
|||
self.logger.info("Accessing the inbox section via the top-navbar")
|
||||
self.sumo_pages.top_navbar._click_on_inbox_option()
|
||||
|
||||
self.logger.info(
|
||||
"Verifying that we are on the correct page "
|
||||
"and the 'Inbox' navbar option is highlighted"
|
||||
)
|
||||
self.logger.info("Verifying that we are on the correct page and the 'Inbox' navbar "
|
||||
"option is highlighted")
|
||||
expect(self.page).to_have_url(InboxPageMessages.INBOX_PAGE_STAGE_URL)
|
||||
|
||||
expect(
|
||||
self.sumo_pages.mess_system_user_navbar._get_inbox_navbar_element()
|
||||
).to_have_css("background-color", InboxPageMessages.NAVBAR_INBOX_SELECTED_BG_COLOR)
|
||||
|
||||
self.logger.info("Clicking on the sent messages navbar option")
|
||||
self.sumo_pages.mess_system_user_navbar._click_on_messaging_system_navbar_sent_messages()
|
||||
|
||||
self.logger.info(
|
||||
"Verifying that we are on the correct page "
|
||||
"and the 'Sent Messages' page is successfully displayed"
|
||||
)
|
||||
self.logger.info("Verifying that we are on the correct page and the 'Sent Messages' page "
|
||||
"is successfully displayed")
|
||||
expect(
|
||||
self.page
|
||||
).to_have_url(SentMessagesPageMessages.SENT_MESSAGES_PAGE_URL)
|
||||
|
@ -317,10 +283,8 @@ class TestMessagingSystem(TestUtilities):
|
|||
self.logger.info("Clicking on the navbar inbox messaging system navbar option")
|
||||
self.sumo_pages.mess_system_user_navbar._click_on_messaging_system_navbar_inbox()
|
||||
|
||||
self.logger.info(
|
||||
"Verifying that we are on the correct page "
|
||||
"and the 'Inbox' navbar option is highlighted"
|
||||
)
|
||||
self.logger.info("Verifying that we are on the correct page and the 'Inbox' navbar "
|
||||
"option is highlighted")
|
||||
expect(self.page).to_have_url(InboxPageMessages.INBOX_PAGE_STAGE_URL)
|
||||
|
||||
expect(
|
||||
|
@ -341,19 +305,17 @@ class TestMessagingSystem(TestUtilities):
|
|||
self.logger.info("Accessing the New Message page")
|
||||
self.sumo_pages.top_navbar._click_on_inbox_option()
|
||||
self.sumo_pages.mess_system_user_navbar._click_on_messaging_system_navbar_new_message()
|
||||
|
||||
self.logger.info("Submitting the form without any data")
|
||||
self.sumo_pages.new_message_page._click_on_new_message_send_button()
|
||||
|
||||
self.logger.info("Verifying that we are still on the 'New Message page'")
|
||||
expect(self.page).to_have_url(NewMessagePageMessages.NEW_MESSAGE_PAGE_STAGE_URL)
|
||||
|
||||
self.logger.info("Adding a valid user inside the 'To' field")
|
||||
self.sumo_pages.new_message_page._type_into_new_message_to_input_field(text=user_two)
|
||||
self.sumo_pages.new_message_page._click_on_a_searched_user(username=user_two)
|
||||
|
||||
self.logger.info(
|
||||
"Clicking the 'Send' button and verifying that we are still on the same page"
|
||||
self.logger.info("Sending a message and verifying that we are on the same page")
|
||||
self.sumo_pages.messaging_system_flow.complete_send_message_form_with_data(
|
||||
recipient_username=user_two
|
||||
)
|
||||
self.sumo_pages.new_message_page._click_on_new_message_send_button()
|
||||
|
||||
expect(self.page).to_have_url(NewMessagePageMessages.NEW_MESSAGE_PAGE_STAGE_URL)
|
||||
|
||||
|
@ -383,7 +345,6 @@ class TestMessagingSystem(TestUtilities):
|
|||
# ]
|
||||
# )
|
||||
self.logger.info("Adding 9990 characters inside the input field")
|
||||
|
||||
self.sumo_pages.new_message_page._fill_into_new_message_body_textarea(
|
||||
text=super().user_message_test_data["valid_user_message"][
|
||||
"9990_characters_long_message"
|
||||
|
@ -395,6 +356,7 @@ class TestMessagingSystem(TestUtilities):
|
|||
f"Expected: {NewMessagePageMessages.TEN_CHARACTERS_REMAINING_MESSAGE}"
|
||||
f"Displayed: {self.sumo_pages.new_message_page._get_characters_remaining_text()}",
|
||||
)
|
||||
|
||||
self.logger.info("Verifying that the characters remaining color is the expected one")
|
||||
expect(self.sumo_pages.new_message_page._get_characters_remaining_text_element()
|
||||
).to_have_css("color", NewMessagePageMessages.ENOUGH_CHARACTERS_REMAINING_COLOR)
|
||||
|
@ -409,7 +371,6 @@ class TestMessagingSystem(TestUtilities):
|
|||
# )
|
||||
|
||||
self.logger.info("Adding one character inside the textarea field")
|
||||
|
||||
self.sumo_pages.new_message_page._type_into_new_message_body_textarea(
|
||||
text=super().user_message_test_data["valid_user_message"]["one_character_message"]
|
||||
)
|
||||
|
@ -437,7 +398,6 @@ class TestMessagingSystem(TestUtilities):
|
|||
# )
|
||||
|
||||
self.logger.info("Adding 9 characters inside the textarea field")
|
||||
|
||||
self.sumo_pages.new_message_page._type_into_new_message_body_textarea(
|
||||
text=super().user_message_test_data["valid_user_message"]["9_characters_message"]
|
||||
)
|
||||
|
@ -475,6 +435,7 @@ class TestMessagingSystem(TestUtilities):
|
|||
user_two = super().username_extraction_from_email(
|
||||
super().user_secrets_accounts["TEST_ACCOUNT_13"]
|
||||
)
|
||||
|
||||
self.logger.info("Signing in with a normal user account")
|
||||
self.start_existing_session(super().username_extraction_from_email(
|
||||
self.user_secrets_accounts["TEST_ACCOUNT_12"]
|
||||
|
@ -489,6 +450,7 @@ class TestMessagingSystem(TestUtilities):
|
|||
self.sumo_pages.messaging_system_flow.complete_send_message_form_with_data(
|
||||
recipient_username=user_two,
|
||||
message_body=super().user_message_test_data["valid_user_message"]["message"],
|
||||
submit_message=False
|
||||
)
|
||||
|
||||
self.logger.info("Clicking on the 'Cancel' button")
|
||||
|
@ -501,9 +463,8 @@ class TestMessagingSystem(TestUtilities):
|
|||
|
||||
expect(self.page).to_have_url(InboxPageMessages.INBOX_PAGE_STAGE_URL)
|
||||
|
||||
self.logger.info(
|
||||
"Navigating to the 'Sent Messages' page nad verifying that the message was not sent"
|
||||
)
|
||||
self.logger.info("Navigating to the 'Sent Messages' page nad verifying that the message "
|
||||
"was not sent")
|
||||
self.sumo_pages.mess_system_user_navbar._click_on_messaging_system_navbar_sent_messages()
|
||||
|
||||
expect(self.sumo_pages.sent_message_page._sent_messages(username=user_two)
|
||||
|
@ -514,9 +475,8 @@ class TestMessagingSystem(TestUtilities):
|
|||
self.user_secrets_accounts["TEST_ACCOUNT_13"]
|
||||
))
|
||||
|
||||
self.logger.info(
|
||||
"Navigating to the receiver inbox and verifying that no message was received"
|
||||
)
|
||||
self.logger.info("Navigating to the receiver inbox and verifying that no message was "
|
||||
"received")
|
||||
self.sumo_pages.top_navbar._click_on_inbox_option()
|
||||
|
||||
expect(
|
||||
|
@ -547,6 +507,7 @@ class TestMessagingSystem(TestUtilities):
|
|||
self.sumo_pages.messaging_system_flow.complete_send_message_form_with_data(
|
||||
recipient_username=test_user,
|
||||
message_body=super().user_message_test_data["valid_user_message"]["message"],
|
||||
submit_message=False
|
||||
)
|
||||
|
||||
self.logger.info("Clicking on the 'Preview' button")
|
||||
|
@ -558,7 +519,6 @@ class TestMessagingSystem(TestUtilities):
|
|||
).to_be_visible()
|
||||
|
||||
self.logger.info("Verifying that all the preview items are displayed")
|
||||
|
||||
check.equal(
|
||||
self.sumo_pages.new_message_page._get_text_of_test_data_first_paragraph_text(),
|
||||
NewMessagePageMessages.PREVIEW_MESSAGE_CONTENT_FIRST_PARAGRAPH_TEXT,
|
||||
|
@ -622,10 +582,8 @@ class TestMessagingSystem(TestUtilities):
|
|||
self.sumo_pages.new_message_page._new_message_preview_internal_link_test_data_element()
|
||||
).to_be_visible()
|
||||
|
||||
self.logger.info(
|
||||
"Clicking on the internal link and "
|
||||
"verifying that the user is redirected to the correct article"
|
||||
)
|
||||
self.logger.info("Clicking on the internal link and verifying that the user is "
|
||||
"redirected to the correct article")
|
||||
self.sumo_pages.new_message_page._click_on_preview_internal_link()
|
||||
|
||||
assert (
|
||||
|
@ -637,9 +595,8 @@ class TestMessagingSystem(TestUtilities):
|
|||
f"Received: {self.sumo_pages.kb_article_page._get_text_of_article_title()}"
|
||||
)
|
||||
|
||||
self.logger.info(
|
||||
"Verifying that the message was no sent by checking the 'Sent Messages page'"
|
||||
)
|
||||
self.logger.info("Verifying that the message was no sent by checking the 'Sent Messages "
|
||||
"page'")
|
||||
self.sumo_pages.top_navbar._click_on_inbox_option()
|
||||
|
||||
self.sumo_pages.mess_system_user_navbar._click_on_messaging_system_navbar_sent_messages()
|
||||
|
@ -648,12 +605,8 @@ class TestMessagingSystem(TestUtilities):
|
|||
self.sumo_pages.sent_message_page._sent_messages(username=test_user)
|
||||
).to_be_hidden()
|
||||
|
||||
self.logger.info(
|
||||
"Signing in with the potential message receiver "
|
||||
"and verifying that no message was received"
|
||||
)
|
||||
|
||||
self.logger.info("Signing in with a normal user account")
|
||||
self.logger.info("Signing in with the potential message receiver and verifying that no "
|
||||
"message was received")
|
||||
self.start_existing_session(super().username_extraction_from_email(
|
||||
self.user_secrets_accounts["TEST_ACCOUNT_13"]
|
||||
))
|
||||
|
@ -672,37 +625,29 @@ class TestMessagingSystem(TestUtilities):
|
|||
)
|
||||
|
||||
self.logger.info("Signing in with a normal user account")
|
||||
|
||||
self.start_existing_session(super().username_extraction_from_email(
|
||||
self.user_secrets_accounts["TEST_ACCOUNT_MESSAGE_5"]
|
||||
))
|
||||
|
||||
user_one = self.sumo_pages.top_navbar._get_text_of_logged_in_username()
|
||||
|
||||
self.logger.info(
|
||||
"Accessing the 'New Message' page and sending a message to a different user"
|
||||
)
|
||||
self.logger.info("Accessing the 'New Message' page and sending a message to a different "
|
||||
"user")
|
||||
self.sumo_pages.top_navbar._click_on_inbox_option()
|
||||
self.sumo_pages.mess_system_user_navbar._click_on_messaging_system_navbar_new_message()
|
||||
self.sumo_pages.messaging_system_flow.complete_send_message_form_with_data(
|
||||
recipient_username=test_user,
|
||||
message_body=super().user_message_test_data["valid_user_message"]["message"],
|
||||
)
|
||||
self.sumo_pages.new_message_page._click_on_new_message_send_button()
|
||||
|
||||
self.logger.info("Navigating to the sent messages page")
|
||||
|
||||
self.sumo_pages.mess_system_user_navbar._click_on_messaging_system_navbar_sent_messages()
|
||||
|
||||
self.logger.info("Clicking on the 'Delete Selected' button")
|
||||
|
||||
self.sumo_pages.sent_message_page._click_on_delete_selected_button()
|
||||
|
||||
self.logger.info(
|
||||
"Verifying that the correct message is displayed "
|
||||
"and is no longer displayed when dismissed"
|
||||
)
|
||||
|
||||
self.logger.info("Verifying that the correct message is displayed and is no longer "
|
||||
"displayed when dismissed")
|
||||
check.equal(
|
||||
self.sumo_pages.sent_message_page._get_sent_messages_page_deleted_banner_text(),
|
||||
SentMessagesPageMessages.NO_MESSAGES_SELECTED_BANNER_TEXT,
|
||||
|
@ -713,30 +658,22 @@ class TestMessagingSystem(TestUtilities):
|
|||
f"{self.sumo_pages.sent_message_page._get_sent_messages_page_deleted_banner_text()}",
|
||||
)
|
||||
|
||||
self.logger.info(
|
||||
"Verifying that the message is still listed inside the sent messages section"
|
||||
)
|
||||
|
||||
self.logger.info("Verifying that the message is still listed inside the sent messages "
|
||||
"section")
|
||||
expect(
|
||||
self.sumo_pages.sent_message_page._sent_messages(username=test_user)
|
||||
).to_be_visible()
|
||||
|
||||
self.logger.info("Sending another message to self twice")
|
||||
|
||||
for i in range(2):
|
||||
self.sumo_pages.mess_system_user_navbar._click_on_messaging_system_navbar_new_message()
|
||||
self.sumo_pages.messaging_system_flow.complete_send_message_form_with_data(
|
||||
recipient_username=user_one,
|
||||
message_body=super().user_message_test_data["valid_user_message"]["message"],
|
||||
)
|
||||
self.sumo_pages.new_message_page._click_on_new_message_send_button()
|
||||
|
||||
self.logger.info(
|
||||
"Clicking on the 'delete selected' button while no messages is selected "
|
||||
"and verifying that the correct "
|
||||
"banner is displayed"
|
||||
)
|
||||
|
||||
self.logger.info("Clicking on the 'delete selected' button while no messages is selected "
|
||||
"and verifying that the correct banner is displayed")
|
||||
self.sumo_pages.inbox_page._click_on_inbox_delete_selected_button()
|
||||
|
||||
check.equal(
|
||||
|
@ -768,10 +705,8 @@ class TestMessagingSystem(TestUtilities):
|
|||
f"Received: {self.sumo_pages.inbox_page._get_text_inbox_page_message_banner_text()}",
|
||||
)
|
||||
|
||||
self.logger.info(
|
||||
"Navigating to the sent messages section and "
|
||||
"clearing all messages via the 'delete selected button'"
|
||||
)
|
||||
self.logger.info("Navigating to the sent messages section and clearing all messages via "
|
||||
"the 'delete selected button'")
|
||||
self.sumo_pages.mess_system_user_navbar._click_on_messaging_system_navbar_sent_messages()
|
||||
|
||||
self.sumo_pages.sent_message_page._delete_all_sent_messages_via_delete_selected_button()
|
||||
|
@ -786,7 +721,6 @@ class TestMessagingSystem(TestUtilities):
|
|||
).to_be_hidden()
|
||||
|
||||
self.logger.info("Verifying that the correct banner is displayed")
|
||||
|
||||
check.equal(
|
||||
self.sumo_pages.sent_message_page._get_sent_messages_page_deleted_banner_text(),
|
||||
SentMessagesPageMessages.MULTIPLE_MESSAGES_DELETION_BANNER_TEXT,
|
||||
|
@ -800,7 +734,6 @@ class TestMessagingSystem(TestUtilities):
|
|||
self.logger.info(
|
||||
"Signing in with the receiver account and navigating to the inbox section"
|
||||
)
|
||||
|
||||
self.start_existing_session(super().username_extraction_from_email(
|
||||
self.user_secrets_accounts["TEST_ACCOUNT_MESSAGE_6"]
|
||||
))
|
||||
|
@ -808,7 +741,6 @@ class TestMessagingSystem(TestUtilities):
|
|||
self.sumo_pages.top_navbar._click_on_inbox_option()
|
||||
|
||||
self.logger.info("Verifying that the messages are displayed inside the inbox section")
|
||||
|
||||
expect(
|
||||
self.sumo_pages.inbox_page._inbox_message(username=user_one)
|
||||
).to_be_visible()
|
||||
|
@ -818,16 +750,13 @@ class TestMessagingSystem(TestUtilities):
|
|||
)
|
||||
self.sumo_pages.inbox_page._delete_all_inbox_messages_via_delete_selected_button()
|
||||
|
||||
self.logger.info(
|
||||
"Verifying that the messages are no longer displayed inside the inbox section"
|
||||
)
|
||||
|
||||
self.logger.info("Verifying that the messages are no longer displayed inside the inbox "
|
||||
"section")
|
||||
expect(
|
||||
self.sumo_pages.inbox_page._inbox_message(username=user_one)
|
||||
).to_be_hidden()
|
||||
|
||||
self.logger.info("Verifying that the correct banner is displayed")
|
||||
|
||||
check.equal(
|
||||
self.sumo_pages.inbox_page._get_text_inbox_page_message_banner_text(),
|
||||
InboxPageMessages.MESSAGE_DELETED_BANNER_TEXT,
|
||||
|
|
|
@ -11,16 +11,13 @@ class TestTopNavbar(TestUtilities):
|
|||
@pytest.mark.topNavbarTests
|
||||
def test_number_of_options_not_signed_in(self):
|
||||
self.logger.info("Verifying that the SUMO logo is successfully displayed")
|
||||
|
||||
image = self.sumo_pages.top_navbar._get_sumo_nav_logo()
|
||||
image_link = image.get_attribute("src")
|
||||
response = requests.get(image_link, stream=True)
|
||||
check.is_true(response.status_code < 400, f"The {image_link} image is broken")
|
||||
|
||||
self.logger.info(
|
||||
"Verifying that top-navbar contains only Get Help & "
|
||||
"Contribute options for non signed-in state"
|
||||
)
|
||||
self.logger.info("Verifying that top-navbar contains only Get Help & Contribute options "
|
||||
"for non signed-in state")
|
||||
top_navbar_items = self.sumo_pages.top_navbar._get_available_menu_titles()
|
||||
expected_top_navbar_items = [
|
||||
TopNavbarMessages.GET_HELP_OPTION_TEXT,
|
||||
|
@ -45,11 +42,8 @@ class TestTopNavbar(TestUtilities):
|
|||
response = requests.get(image_link, stream=True)
|
||||
check.is_true(response.status_code < 400, f"The {image_link} image is broken")
|
||||
|
||||
self.logger.info(
|
||||
"Verifying that the top-navbar contains Get Help, "
|
||||
"Contributor Tools and Contribute options"
|
||||
)
|
||||
|
||||
self.logger.info("Verifying that the top-navbar contains Get Help, Contributor Tools and "
|
||||
"Contribute options")
|
||||
top_navbar_items = self.sumo_pages.top_navbar._get_available_menu_titles()
|
||||
expected_top_navbar_items = [
|
||||
TopNavbarMessages.GET_HELP_OPTION_TEXT,
|
||||
|
@ -72,11 +66,8 @@ class TestTopNavbar(TestUtilities):
|
|||
self.logger.info("Signing the user out from SUMO by clearing session cookies")
|
||||
self.delete_cookies()
|
||||
|
||||
self.logger.info(
|
||||
"Verifying that top-navbar contains only Get Help & "
|
||||
"Contribute options for non signed-in state"
|
||||
)
|
||||
|
||||
self.logger.info("Verifying that top-navbar contains only Get Help & Contribute options "
|
||||
"for non signed-in state")
|
||||
top_navbar_items = self.sumo_pages.top_navbar._get_available_menu_titles()
|
||||
expected_top_navbar_items = [
|
||||
TopNavbarMessages.GET_HELP_OPTION_TEXT,
|
||||
|
|
|
@ -20,20 +20,10 @@ class TestEditContributionAreas(TestUtilities):
|
|||
|
||||
original_user = self.sumo_pages.top_navbar._get_text_of_logged_in_username()
|
||||
|
||||
self.logger.info("Clicking on the 'Edit Contribution areas option'")
|
||||
self.sumo_pages.top_navbar._click_on_settings_profile_option()
|
||||
|
||||
self.sumo_pages.user_navbar._click_on_edit_contribution_areas_option()
|
||||
|
||||
self.logger.info("Clicking on all checkboxes")
|
||||
self.sumo_pages.edit_my_profile_con_areas_page._click_on_unchecked_cont_areas_checkboxes()
|
||||
|
||||
self.logger.info("Clicking on the 'Update' button")
|
||||
|
||||
self.sumo_pages.edit_my_profile_con_areas_page._click_on_update_contribution_areas_button()
|
||||
self.logger.info("Checking all contributor checkboxes")
|
||||
self.sumo_pages.edit_profile_flow.check_all_profile_contribution_areas(checked=False)
|
||||
|
||||
self.logger.info("Verifying that the correct notification banner text is displayed")
|
||||
|
||||
check.equal(
|
||||
self.sumo_pages.edit_my_profile_con_areas_page._edit_con_areas_pref_banner_txt(),
|
||||
EditContributionAreasPageMessages.PREFERENCES_SAVED_NOTIFICATION_BANNER_TEXT,
|
||||
|
@ -53,10 +43,8 @@ class TestEditContributionAreas(TestUtilities):
|
|||
self.sumo_pages.edit_my_profile_con_areas_page._get_contrib_areas_checkbox_labels()
|
||||
)
|
||||
|
||||
self.logger.info(
|
||||
"Accessing the my profile page and verifying that "
|
||||
"the displayed groups are the correct ones"
|
||||
)
|
||||
self.logger.info("Accessing the my profile page and verifying that the displayed groups "
|
||||
"are the correct ones")
|
||||
self.sumo_pages.user_navbar._click_on_my_profile_option()
|
||||
|
||||
assert (
|
||||
|
@ -68,19 +56,16 @@ class TestEditContributionAreas(TestUtilities):
|
|||
f"received: {self.sumo_pages.my_profile_page._get_my_profile_groups_items_text()}"
|
||||
)
|
||||
|
||||
self.logger.info(
|
||||
"Signing in with a different account and verifying "
|
||||
"that the original user groups are displayed"
|
||||
)
|
||||
self.logger.info("Signing in with a different account and verifying that the original "
|
||||
"user groups are displayed")
|
||||
self.start_existing_session(super().username_extraction_from_email(
|
||||
self.user_secrets_accounts['TEST_ACCOUNT_13']
|
||||
))
|
||||
|
||||
self.navigate_to_link(MyProfileMessages.get_my_profile_stage_url(original_user))
|
||||
|
||||
self.logger.info(
|
||||
"Verifying that the user groups is successfully displayed for the original user"
|
||||
)
|
||||
self.logger.info("Verifying that the user groups is successfully displayed for the "
|
||||
"original user")
|
||||
assert (
|
||||
self.sumo_pages.my_profile_page._get_my_profile_groups_items_text()
|
||||
== contribution_options
|
||||
|
@ -95,21 +80,9 @@ class TestEditContributionAreas(TestUtilities):
|
|||
self.user_secrets_accounts['TEST_ACCOUNT_12']
|
||||
))
|
||||
|
||||
self.logger.info(
|
||||
"Accessing the edit contribution areas page and unchecking all the checkboxes"
|
||||
)
|
||||
self.sumo_pages.top_navbar._click_on_settings_profile_option()
|
||||
|
||||
self.sumo_pages.user_navbar._click_on_edit_contribution_areas_option()
|
||||
|
||||
(self.sumo_pages.edit_my_profile_con_areas_page
|
||||
._click_on_all_checked_cont_areas_checkboxes())
|
||||
|
||||
self.logger.info(
|
||||
"Clicking on the update button and verifying that "
|
||||
"the correct notification banner is displayed"
|
||||
)
|
||||
self.sumo_pages.edit_my_profile_con_areas_page._click_on_update_contribution_areas_button()
|
||||
self.logger.info("Unchecking all contributor checkboxes and verifying that the correct "
|
||||
"notification banner is displayed")
|
||||
self.sumo_pages.edit_profile_flow.check_all_profile_contribution_areas(checked=True)
|
||||
|
||||
check.equal(
|
||||
self.sumo_pages.edit_my_profile_con_areas_page._edit_con_areas_pref_banner_txt(),
|
||||
|
@ -121,10 +94,8 @@ class TestEditContributionAreas(TestUtilities):
|
|||
f"{self.sumo_pages.edit_my_profile_con_areas_page._edit_con_areas_pref_banner_txt()}",
|
||||
)
|
||||
|
||||
self.logger.info(
|
||||
"Verifying that the profile groups section is no longer "
|
||||
"displayed inside the profile section"
|
||||
)
|
||||
self.logger.info("Verifying that the profile groups section is no longer displayed "
|
||||
"inside the profile section")
|
||||
self.sumo_pages.user_navbar._click_on_my_profile_option()
|
||||
|
||||
expect(
|
||||
|
@ -140,10 +111,8 @@ class TestEditContributionAreas(TestUtilities):
|
|||
|
||||
self.navigate_to_link(MyProfileMessages.get_my_profile_stage_url(original_user))
|
||||
|
||||
self.logger.info(
|
||||
"Verifying that the groups section is not longer displayed for the original user"
|
||||
)
|
||||
|
||||
self.logger.info("Verifying that the groups section is not longer displayed for the "
|
||||
"original user")
|
||||
expect(
|
||||
self.sumo_pages.my_profile_page._groups_section_element()
|
||||
).to_be_hidden()
|
||||
|
|
|
@ -17,13 +17,7 @@ class TestEditMySettings(TestUtilities):
|
|||
self.user_secrets_accounts['TEST_ACCOUNT_12']
|
||||
))
|
||||
|
||||
self.sumo_pages.top_navbar._click_on_settings_profile_option()
|
||||
|
||||
self.logger.info("Clicking on all available checkboxes")
|
||||
self.sumo_pages.edit_my_profile_settings_page._click_on_all_settings_checkboxes()
|
||||
|
||||
self.logger.info("Clicking on the 'Update' button")
|
||||
self.sumo_pages.edit_my_profile_settings_page._click_on_update_button()
|
||||
self.sumo_pages.edit_profile_flow.check_all_user_settings()
|
||||
|
||||
self.logger.info("Verifying that the correct notification banner is displayed")
|
||||
check.equal(
|
||||
|
@ -45,9 +39,7 @@ class TestEditMySettings(TestUtilities):
|
|||
"Unchecking all the available checkboxes and clicking on the 'Update' button"
|
||||
)
|
||||
|
||||
self.sumo_pages.edit_my_profile_settings_page._click_on_all_settings_checkboxes()
|
||||
|
||||
self.sumo_pages.edit_my_profile_settings_page._click_on_update_button()
|
||||
self.sumo_pages.edit_profile_flow.check_all_user_settings()
|
||||
|
||||
self.logger.info("Verifying that the correct notification banner is displayed")
|
||||
|
||||
|
|
Загрузка…
Ссылка в новой задаче