Beispiel #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
Beispiel #2
0
 def test_username_exists_not(self):
     exists, ref = UsersDb.username_exists('SOmeNoneExistingNamelksjflkjsf')
     assert exists == False
     assert ref == None
Beispiel #3
0
async def get_check(username: str):
    exists, ref = UsersDb.username_exists(username)
    return UserExists(exists=exists)