Skip to content

Commit b2e2a8b

Browse files
committed
Fix tests
1 parent 62116fe commit b2e2a8b

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

readthedocs/rtd_tests/tests/test_api.py

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -344,15 +344,15 @@ def _try_post():
344344

345345
_try_post()
346346

347-
api_user = get(User, staff=False, password='test')
347+
api_user = get(User, is_staff=False, password='test')
348348
assert api_user.is_staff is False
349349
client.force_authenticate(user=api_user)
350350
_try_post()
351351

352352
def test_update_build_without_permission(self):
353353
"""Ensure anonymous/non-staff users cannot update build endpoints."""
354354
client = APIClient()
355-
api_user = get(User, staff=False, password='test')
355+
api_user = get(User, is_staff=False, password='test')
356356
client.force_authenticate(user=api_user)
357357
build = get(Build, project_id=1, version_id=1, state='cloning')
358358
resp = client.put(
@@ -376,7 +376,7 @@ def test_make_build_protected_fields(self):
376376
build = get(Build, project_id=1, version_id=1, builder='foo')
377377
client = APIClient()
378378

379-
api_user = get(User, staff=False, password='test')
379+
api_user = get(User, is_staff=False, password='test')
380380
client.force_authenticate(user=api_user)
381381
resp = client.get('/api/v2/build/{}/'.format(build.pk), format='json')
382382
self.assertEqual(resp.status_code, 200)
@@ -565,7 +565,7 @@ def test_build_filter_by_commit(self):
565565
get(Build, project_id=1, version_id=1, builder='foo', commit='test')
566566
get(Build, project_id=2, version_id=1, builder='foo', commit='other')
567567
client = APIClient()
568-
api_user = get(User, staff=False, password='test')
568+
api_user = get(User, is_staff=False, password='test')
569569
client.force_authenticate(user=api_user)
570570
resp = client.get('/api/v2/build/', {'commit': 'test'}, format='json')
571571
self.assertEqual(resp.status_code, 200)

0 commit comments

Comments
 (0)