mirror of
https://github.com/GSA/notifications-admin.git
synced 2026-08-24 08:16:51 -04:00
Fixing tests
This commit is contained in:
@@ -1310,6 +1310,8 @@ def test_shows_delete_link_for_error_on_post_request_for_edit_email_reply_to_add
|
|||||||
_expected_status=200,
|
_expected_status=200,
|
||||||
)
|
)
|
||||||
|
|
||||||
|
print(page.prettify())
|
||||||
|
|
||||||
assert page.select_one(".usa-back-link").text.strip() == "Back"
|
assert page.select_one(".usa-back-link").text.strip() == "Back"
|
||||||
assert page.select_one(".usa-back-link")["href"] == url_for(
|
assert page.select_one(".usa-back-link")["href"] == url_for(
|
||||||
".service_email_reply_to",
|
".service_email_reply_to",
|
||||||
@@ -1320,7 +1322,7 @@ def test_shows_delete_link_for_error_on_post_request_for_edit_email_reply_to_add
|
|||||||
== "Error: Enter a valid email address"
|
== "Error: Enter a valid email address"
|
||||||
)
|
)
|
||||||
assert (
|
assert (
|
||||||
page.select_one("input#email_address").get("value")
|
page.select_one("input#reply-to-email-address").get("value")
|
||||||
== "not a valid email address"
|
== "not a valid email address"
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|||||||
@@ -388,7 +388,7 @@ def test_search_recipient_form(
|
|||||||
query_dict = parse_qs(url.query)
|
query_dict = parse_qs(url.query)
|
||||||
assert query_dict == {}
|
assert query_dict == {}
|
||||||
|
|
||||||
assert page.select_one("label[for=to]").text.strip() == expected_search_box_label
|
assert page.select_one("label:contains('Search by')").text.strip() == expected_search_box_label
|
||||||
|
|
||||||
recipient_inputs = page.select("input[name=to]")
|
recipient_inputs = page.select("input[name=to]")
|
||||||
assert len(recipient_inputs) == 2
|
assert len(recipient_inputs) == 2
|
||||||
@@ -421,7 +421,7 @@ def test_api_users_are_told_they_can_search_by_reference_when_service_has_api_ke
|
|||||||
service_id=SERVICE_ONE_ID,
|
service_id=SERVICE_ONE_ID,
|
||||||
message_type=message_type,
|
message_type=message_type,
|
||||||
)
|
)
|
||||||
assert page.select_one("label[for=to]").text.strip() == expected_search_box_label
|
assert page.select_one("label:contains('Search by')").text.strip() == expected_search_box_label
|
||||||
|
|
||||||
|
|
||||||
@pytest.mark.parametrize(
|
@pytest.mark.parametrize(
|
||||||
@@ -448,7 +448,10 @@ def test_api_users_are_not_told_they_can_search_by_reference_when_service_has_no
|
|||||||
service_id=SERVICE_ONE_ID,
|
service_id=SERVICE_ONE_ID,
|
||||||
message_type=message_type,
|
message_type=message_type,
|
||||||
)
|
)
|
||||||
assert page.select_one("label[for=to]").text.strip() == expected_search_box_label
|
|
||||||
|
print(page.prettify())
|
||||||
|
|
||||||
|
assert page.select_one("label:contains('Search by')").text.strip() == expected_search_box_label
|
||||||
|
|
||||||
|
|
||||||
def test_should_show_notifications_for_a_service_with_next_previous(
|
def test_should_show_notifications_for_a_service_with_next_previous(
|
||||||
|
|||||||
Reference in New Issue
Block a user