diff accounts/tests/view_tests.py @ 690:988782c6ce6c

For #48, rework blocking code to use fail2ban.
author Brian Neal <bgneal@gmail.com>
date Sun, 01 Sep 2013 00:15:42 -0500
parents 8e6b8ffe5f34
children
line wrap: on
line diff
--- a/accounts/tests/view_tests.py	Sat Aug 31 14:50:03 2013 -0500
+++ b/accounts/tests/view_tests.py	Sun Sep 01 00:15:42 2013 -0500
@@ -10,7 +10,6 @@
 from django.contrib.auth.models import User
 from django.contrib.auth.hashers import check_password
 
-from antispam.rate_limit import unblock_ip
 from accounts.models import PendingUser
 from accounts.models import IllegalUsername
 from accounts.models import IllegalEmail
@@ -35,9 +34,6 @@
         IllegalUsername.objects.create(username='illegalusername')
         IllegalEmail.objects.create(email='illegal@example.com')
 
-    def tearDown(self):
-        unblock_ip('127.0.0.1')
-
     def test_get_view(self):
         """
         Test a simple get of the registration view
@@ -223,7 +219,7 @@
             'question2': 'non blank',
             })
 
-        self.assertEqual(response.status_code, 403)
+        self.assertEqual(response.status_code, 200)
 
     def test_success(self):
         """