-
Notifications
You must be signed in to change notification settings - Fork 133
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
24c7acd
commit 853b3ee
Showing
2 changed files
with
3 additions
and
62 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -43,7 +43,7 @@ def test_waitlist_signup(mock_send_email, client_with_mocks): | |
assert response.status_code == 201 | ||
|
||
|
||
def test_duplicate_email(client_with_mocks): | ||
def test_duplicate_email(mock_send_email, client_with_mocks): | ||
client, mock_db = client_with_mocks | ||
# Simulate an existing user in the database | ||
mock_db.query.return_value.filter.return_value.first.return_value = MagicMock() | ||
|
@@ -53,14 +53,14 @@ def test_duplicate_email(client_with_mocks): | |
) | ||
assert response.status_code == 400 | ||
|
||
def test_invalid_email(client_with_mocks): | ||
def test_invalid_email(mock_send_email, client_with_mocks): | ||
client, _ = client_with_mocks | ||
response = client.post( | ||
"/api/v1/waitlist/", json={"email": "invalid_email", "full_name": "Test User"} | ||
) | ||
assert response.status_code == 422 | ||
|
||
def test_signup_with_empty_name(client_with_mocks): | ||
def test_signup_with_empty_name(mock_send_email, client_with_mocks): | ||
client, _ = client_with_mocks | ||
response = client.post( | ||
"/api/v1/waitlist/", json={"email": "[email protected]", "full_name": ""} | ||
|