예제 #1
0
 def test_link_card(self):    
     
     acc = "acc"
     pwd = "pwd"
     dbRoutine.create_account(acc, pwd)
     account = dbRoutine.retrieve_account(acc, pwd)
     dbRoutine.create_fc("biology", "q", "a")
예제 #2
0
 def test_link_session(self):
     
     acc = "acc"
     pwd = "pwd"
     dbRoutine.create_account(acc, pwd)
     account = dbRoutine.retrieve_account(acc, pwd)
     dbRoutine.create_fc("biology", "q", "a")
     session = dbRoutine.create_session("biology", 17)
     dbRoutine.link_session(account.getName(), session)
     sessions = account.getSessions()
     
     self.assertEqual(1, sessions.count())
예제 #3
0
 def test_delete_user_account(self):
     
     acc = "acc"
     pwd = "pwd"
     
     dbRoutine.create_account(acc, pwd)
     user_account = User.objects.create_user(acc, "", pwd)
     
     account = dbRoutine.retrieve_account(acc, pwd)
     #account.values().values_list('id', flat=True)
     
     account.delete()
     user_account.delete()