Skip to content

Commit

Permalink
update tests
Browse files Browse the repository at this point in the history
  • Loading branch information
jedie committed Aug 28, 2018
1 parent b0103fb commit 50d60bf
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion for_runners/tests/test_admin.py
Original file line number Diff line number Diff line change
Expand Up @@ -38,9 +38,13 @@ def test_staff_upload(self):
)
# debug_response(response)

tracks = GpxModel.objects.all()
self.assertEqual(tracks.count(), 1)
new_track = tracks[0]

self.assertRedirects(
response,
expected_url="/en/admin/for_runners/gpxmodel/",
expected_url="/en/admin/for_runners/gpxmodel/%i/change/" % new_track.pk,
status_code=302,
target_status_code=200,
fetch_redirect_response=False
Expand Down

0 comments on commit 50d60bf

Please sign in to comment.