Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

Merge remote-tracking branch 'brad/tests'

  • Loading branch information...
commit 035012d1e7f39d5c31c64911d0622767314f5a2f 2 parents 0873d26 + 3ba2151
Dan Fairs authored
View
7 README → README.rst
@@ -8,3 +8,10 @@ they can convert their temporary user account to a real user account.
`Read the full documentation`_.
.. _Read the full documentation: http://django-lazysignup.readthedocs.org/
+
+Tests
+=====
+
+To run the tests, do the following::
+
+(cd testproject && python manage.py test lazysignup)
View
3  test-requirements.txt
@@ -1 +1,2 @@
-mock==1.0b1
+Django>=1.4
+mock>=1.0
View
8 testproject/manage.py 100644 → 100755
@@ -1,14 +1,18 @@
#!/usr/bin/env python
from django.core.management import execute_manager
-import imp
+import imp, os, sys
+
+
try:
imp.find_module('settings') # Assumed to be in the same directory.
except ImportError:
- import sys
sys.stderr.write("Error: Can't find the file 'settings.py' in the directory containing %r. It appears you've customized things.\nYou'll have to run django-admin.py, passing it your settings module.\n" % __file__)
sys.exit(1)
import settings
+path = os.path.realpath(os.path.dirname(__file__))
+sys.path.append(os.path.join(path, '..'))
+
if __name__ == "__main__":
execute_manager(settings)
View
3  testproject/settings.py
@@ -1,5 +1,5 @@
# Settings to be used when running unit tests
-# python manage.py test --settings=lazysignup.test_settings lazysignup
+# python manage.py test lazysignup
DATABASES = {
'default': {
@@ -32,6 +32,7 @@
]
ROOT_URLCONF = 'testproject.urls'
+SECRET_KEY = 'non-empty-key'
SECRET_KEY = '12345'
Please sign in to comment.
Something went wrong with that request. Please try again.