diff options
| author | 2019-01-20 11:26:40 +0100 | |
|---|---|---|
| committer | 2019-01-20 11:26:40 +0100 | |
| commit | dc1dca59f1642460effbd7185711c5f691a19e9c (patch) | |
| tree | 1bdb501ff3d6a5d2b772adb6ec520097fb4e2583 /api | |
| parent | Make the flakes happy. (diff) | |
Do not rely on hardcoded ID.
Diffstat (limited to 'api')
| -rw-r--r-- | api/tests/test_infractions.py | 2 | 
1 files changed, 1 insertions, 1 deletions
| diff --git a/api/tests/test_infractions.py b/api/tests/test_infractions.py index 42010973..7c370c17 100644 --- a/api/tests/test_infractions.py +++ b/api/tests/test_infractions.py @@ -181,7 +181,7 @@ class CreationTests(APISubdomainTestCase):          response = self.client.post(url, data=data)          self.assertEqual(response.status_code, 201) -        infraction = Infraction.objects.get(id=1) +        infraction = Infraction.objects.get(id=response.json()['id'])          self.assertAlmostEqual(              infraction.inserted_at,              dt.now(timezone.utc), | 
