Пример #1
0
 def setUp(self):
     self.authUser = createUser("*****@*****.**","pass1")
     self.messenger = RecordingMessenger()
     for record in EmailRecord.objects.all():
         record.delete()
Пример #2
0
 def test_failsOnInvalidPassword(self):
     createUser('*****@*****.**','pass1')
     
     checker = DjangoAuthChecker()
     user= checker.requestAvatarId(UsernamePassword('*****@*****.**',"wrong_password"))
     self.assertFailure(user, UnauthorizedLogin) 
Пример #3
0
 def setUp(self):
   self.authUser = createUser("*****@*****.**","pass1")
Пример #4
0
 def test_authenticatesValidUser(self):
     createUser('*****@*****.**','pass1')
     
     checker = DjangoAuthChecker()
     user = checker.requestAvatarId(UsernamePassword('*****@*****.**',"pass1"))
     user.addCallback(self._assertUserEqual,'*****@*****.**')