Fix get_free_username tests
This commit is contained in:
parent
0b54b16350
commit
b8acee8d30
1 changed files with 2 additions and 2 deletions
|
@ -16,11 +16,11 @@ class TestCASBackend(TestCase):
|
|||
UserModel.objects.create(username="toto2")
|
||||
backend = ENSCASBackend()
|
||||
for _ in range(10):
|
||||
username = backend.get_free_username("toto")
|
||||
username = backend.get_free_username("toto", None)
|
||||
self.assertFalse(UserModel.objects.filter(username=username).exists())
|
||||
UserModel.objects.create(username=username)
|
||||
for _ in range(10):
|
||||
username = backend.get_free_username("tutu")
|
||||
username = backend.get_free_username("tutu", None)
|
||||
self.assertFalse(UserModel.objects.filter(username=username).exists())
|
||||
UserModel.objects.create(username=username)
|
||||
|
||||
|
|
Loading…
Reference in a new issue