✏️(typo) fix typos
Did you know ? "Successful" actually takes two esses.
This commit is contained in:
committed by
Marie
parent
8fed2606d6
commit
83bec33bdb
@@ -550,7 +550,7 @@ def test_api_mailboxes__domain_owner_or_admin_successful_creation_and_provisioni
|
||||
"""
|
||||
Domain owner/admin should be able to create mailboxes.
|
||||
Provisioning API should be called when owner/admin makes a call.
|
||||
Succesfull 201 response from dimail should trigger mailbox creation on our side.
|
||||
successful 201 response from dimail should trigger mailbox creation on our side.
|
||||
"""
|
||||
# creating all needed objects
|
||||
access = factories.MailDomainAccessFactory(role=role)
|
||||
@@ -805,7 +805,7 @@ def test_api_mailboxes__send_correct_logger_infos(mock_info, mock_error):
|
||||
assert not mock_error.called
|
||||
# Check all expected log messages are present, order doesn't matter
|
||||
expected_messages = {
|
||||
("Token succesfully granted by mail-provisioning API.",),
|
||||
("Token successfully granted by mail-provisioning API.",),
|
||||
(
|
||||
"Mailbox successfully created on domain %s by user %s",
|
||||
str(access.domain),
|
||||
|
||||
@@ -7,7 +7,7 @@ import json
|
||||
|
||||
|
||||
def response_user_created(user_sub):
|
||||
"""mimic dimail response upon succesfull user creation."""
|
||||
"""mimic dimail response upon successful user creation."""
|
||||
return json.dumps(
|
||||
{
|
||||
"name": user_sub,
|
||||
@@ -297,7 +297,7 @@ TOKEN_OK = json.dumps({"access_token": "token", "token_type": "bearer"})
|
||||
|
||||
|
||||
def response_allows_created(user_name, domain_name):
|
||||
"""mimic dimail response upon succesfull allows creation.
|
||||
"""mimic dimail response upon successful allows creation.
|
||||
Dimail expects a name but our names are ProConnect's uuids."""
|
||||
return json.dumps({"user": user_name, "domain": domain_name})
|
||||
|
||||
@@ -306,5 +306,5 @@ def response_allows_created(user_name, domain_name):
|
||||
|
||||
|
||||
def response_mailbox_created(email_address):
|
||||
"""mimic dimail response upon succesfull mailbox creation."""
|
||||
"""mimic dimail response upon successful mailbox creation."""
|
||||
return json.dumps({"email": email_address, "password": "password"})
|
||||
|
||||
@@ -388,7 +388,7 @@ def test_dimail__send_pending_mailboxes(caplog):
|
||||
assert mailbox2.status == enums.MailboxStatusChoices.ENABLED
|
||||
|
||||
log_messages = [msg.message for msg in caplog.records]
|
||||
assert "Token succesfully granted by mail-provisioning API." in log_messages
|
||||
assert "Token successfully granted by mail-provisioning API." in log_messages
|
||||
assert (
|
||||
f"Mailbox successfully created on domain {domain.name} by user None"
|
||||
in log_messages
|
||||
|
||||
@@ -71,7 +71,7 @@ class DimailAPIClient:
|
||||
"Content-Type": "application/json",
|
||||
"Authorization": f"Bearer {response.json()['access_token']}",
|
||||
}
|
||||
logger.info("Token succesfully granted by mail-provisioning API.")
|
||||
logger.info("Token successfully granted by mail-provisioning API.")
|
||||
return headers
|
||||
|
||||
if response.status_code == status.HTTP_403_FORBIDDEN:
|
||||
|
||||
Reference in New Issue
Block a user