Example #1
0
 def test_400_when_waffle_is_on(self):
     create_switch('fxa-auth', active=True)
     response = self.client.post(self.url)
     assert response.status_code == 400
Example #2
0
 def setUp(self):
     self.url = reverse('accounts.login')
     create_switch('fxa-auth', active=True)
     patcher = mock.patch('accounts.views.verify.fxa_identify')
     self.fxa_identify = patcher.start()
     self.addCleanup(patcher.stop)
Example #3
0
 def setUp(self):
     self.url = reverse(self.view_name)
     create_switch('fxa-auth', active=True)
     self.fxa_identify = self.patch('accounts.views.verify.fxa_identify')
Example #4
0
 def test_register_404_when_waffle_is_off(self):
     create_switch('fxa-auth', active=False)
     response = self.client.post(self.register_url)
     assert response.status_code == 404
Example #5
0
 def test_login_404_when_waffle_is_off(self):
     create_switch('fxa-auth', active=False)
     response = self.client.post(self.login_url)
     assert response.status_code == 404
Example #6
0
 def test_register_422_when_waffle_is_on(self):
     create_switch('fxa-auth', active=True)
     response = self.client.post(self.register_url)
     assert response.status_code == 422
Example #7
0
 def setUp(self):
     self.url = reverse(self.view_name)
     create_switch('fxa-auth', active=True)
     self.fxa_identify = self.patch('accounts.views.verify.fxa_identify')
Example #8
0
 def setUp(self):
     create_switch('fxa-auth', active=True)
Example #9
0
 def test_source_200_when_waffle_is_on(self):
     create_switch('fxa-auth', active=True)
     response = self.client.get(self.source_url)
     assert response.status_code == 200
Example #10
0
 def test_source_404_when_waffle_is_off(self):
     create_switch('fxa-auth', active=False)
     response = self.client.get(self.source_url)
     assert response.status_code == 404
Example #11
0
 def setUp(self):
     self.url = reverse('accounts.login')
     create_switch('fxa-auth', active=True)
     patcher = mock.patch('accounts.views.verify.fxa_identify')
     self.fxa_identify = patcher.start()
     self.addCleanup(patcher.stop)