Ejemplo n.º 1
0
 def test_home_user_logged_in(self):
     from carvewithus.views import home
     self.config.testing_securitypolicy(userid='*****@*****.**')
     request = testing.DummyResource()
     response = home(request)
     self.assertEqual(response, {'user_email': '*****@*****.**'})
     pass
Ejemplo n.º 2
0
 def test_home_user_logged_out(self):
     from carvewithus.views import home
     request = testing.DummyRequest()
     request.context = testing.DummyResource()
     response = home(request)
     self.assertEqual(response, {'user_email': None})