-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fix db sequence are not always predictable
- Loading branch information
Showing
1 changed file
with
4 additions
and
4 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
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -46,12 +46,12 @@ def test_list_tenders_content(self): | |
self.assertEqual(response.status_code, 200) | ||
self.assertEqual(response.json(), {"count": 0, "next": None, "previous": None, "results": []}) | ||
|
||
user = UserFactory(kind=User.KIND_BUYER) | ||
user = UserFactory(kind=User.KIND_BUYER, email="[email protected]") | ||
CompanyFactory(name="Lagarde et Fils", users=[user]) | ||
TenderFactory(title="Sébastien Le Lopez", amount="0-42K", author=user, presta_type=["FANFAN", "LA", "TULIPE"]) | ||
|
||
# no associated company | ||
TenderFactory(title="Marc Henry", amount_exact=697) | ||
TenderFactory(title="Marc Henry", amount_exact=697, author__email="[email protected]") | ||
|
||
response = self.client.get(url, headers={"Authorization": "Token bar"}) | ||
self.assertEqual(response.status_code, 200) | ||
|
@@ -65,7 +65,7 @@ def test_list_tenders_content(self): | |
{ | ||
"amount": "0-42K", | ||
"amount_exact": None, | ||
"author_email": "email1@example.com", | ||
"author_email": "lagarde@example.com", | ||
"company_name": "Lagarde et Fils", | ||
"company_slug": "lagarde-et-fils", | ||
"created_at": "2024-06-21T14:23:34+02:00", | ||
|
@@ -80,7 +80,7 @@ def test_list_tenders_content(self): | |
{ | ||
"amount": None, | ||
"amount_exact": 697, | ||
"author_email": "email2@example.com", | ||
"author_email": "henry@example.com", | ||
"created_at": "2024-06-21T14:23:34+02:00", | ||
"kind": "QUOTE", | ||
"presta_type": [], | ||
|