refactor: update prerequisites queryset assignment in CaseCollectionForm and improve test assertions
This commit is contained in:
@@ -131,7 +131,9 @@ def test_collection(db, create_case_collection, create_case, make_case, client,
|
||||
# Check that sorting the exam works
|
||||
|
||||
# First attempt is not logged in
|
||||
assertRedirects(response, f"{reverse('login')}?next=%2Fatlas%2Fcollection%2F1%2Fjson_edit")
|
||||
from urllib.parse import quote
|
||||
expected_next = quote(reverse("atlas:exam_json_edit", kwargs={"pk": collection.pk}))
|
||||
assertRedirects(response, f"{reverse('login')}?next={expected_next}")
|
||||
|
||||
client.force_login(create_user)
|
||||
|
||||
|
||||
Reference in New Issue
Block a user