Exemple #1
0
 def test_username_exists(self):
     exists, ref = UsersDb.username_exists(TEST_USER_NAME)
     assert exists == True
     assert ref.get().id == TEST_USER_ID
Exemple #2
0
 def test_username_exists_not(self):
     exists, ref = UsersDb.username_exists('SOmeNoneExistingNamelksjflkjsf')
     assert exists == False
     assert ref == None
Exemple #3
0
async def get_check(username: str):
    exists, ref = UsersDb.username_exists(username)
    return UserExists(exists=exists)