def test_find_account_by_username(self):
     '''
     test to check whether the function used to find accounts really works
     '''
     self.new_account.save_account()
     test_account = Accounts('abcd', 'efgh', 'ijkl', 'mnop')
     test_account.save_account()
     found_account = Accounts.find_by_user_name('ijkl')
     self.assertEqual(found_account.user_name, test_account.user_name)
Exemple #2
0
def find_accounts(user_name):
    return Accounts.find_by_user_name(user_name)