Skip to content

Commit

Permalink
fix up tests
Browse files Browse the repository at this point in the history
  • Loading branch information
John Tordoff committed Dec 12, 2024
1 parent b2b73c5 commit a209a8c
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion api_tests/requests/views/test_node_request_list.py
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@
AuthUserFactory
)
from osf.utils.workflows import DefaultStates, NodeRequestTypes
from website.mails import NODE_REQUEST_INSTITUTIONAL_ACCESS_REQUEST


@pytest.mark.django_db
Expand Down Expand Up @@ -255,12 +256,13 @@ def test_email_sent_on_creation(self, mock_mail, app, project, institutional_adm
assert res.status_code == 201

assert mock_mail.call_count == 1
from website.mails import NODE_REQUEST_INSTITUTIONAL_ACCESS_REQUEST

mock_mail.assert_called_with(
to_addr=user_with_affiliation.username,
mail=NODE_REQUEST_INSTITUTIONAL_ACCESS_REQUEST,
user=user_with_affiliation,
bcc_addr=False,
reply_to=False,
**{
'sender': institutional_admin,
'recipient': user_with_affiliation,
Expand Down

0 comments on commit a209a8c

Please sign in to comment.