ericholscher / django-test-utils

Utilities for testing Django applications
http://django-test-utils.readthedocs.org/
MIT License
343 stars 69 forks source link

Config and Docs problem #5

Open mountainpaul opened 14 years ago

mountainpaul commented 14 years ago

After following docs I had two problems the first was the docs said to run it as follows. ./manage.py testmaker APP generates the following error: Error: 'APP' is not a valid port number So I reran it as ./manage.py testmaker 8000 APP That starts okay, but when I view the home page I get the following error: Traceback (most recent call last):

File "/home/paul/.virtualenvs/waypoints-env/lib/python2.5/site-packages/Django-1.0.3-py2.5.egg/django/core/servers/basehttp.py", line 279, in run self.result = application(self.environ, self.start_response)

File "/home/paul/.virtualenvs/waypoints-env/lib/python2.5/site-packages/Django-1.0.3-py2.5.egg/django/core/servers/basehttp.py", line 651, in call return self.application(environ, start_response)

File "/home/paul/.virtualenvs/waypoints-env/lib/python2.5/site-packages/Django-1.0.3-py2.5.egg/django/core/handlers/wsgi.py", line 230, in call self.load_middleware()

File "/home/paul/.virtualenvs/waypoints-env/lib/python2.5/site-packages/Django-1.0.3-py2.5.egg/django/core/handlers/base.py", line 41, in load_middleware raise exceptions.ImproperlyConfigured, 'Error importing middleware %s: "%s"' % (mw_module, e)

ImproperlyConfigured: Error importing middleware test_utils.testmaker.middleware.testmaker: "cannot import name importlib"

ericholscher commented 14 years ago

I will fix the documentation. If you don't have importlib, what version of django are you running on? I believe it was introduced in 1.0 or 1.1. I should probably mark what version of Django this supports (probably trunk/latest release)

mountainpaul commented 14 years ago

I'm running Django 1.0.3 importlib appears to be installed Searching for importlib Best match: importlib 1.0.1 Processing importlib-1.0.1-py2.5.egg importlib 1.0.1 is already the active version in easy-install.pth

Using /home/paul/.virtualenvs/pinax-env/lib/python2.5/site-packages/importlib-1.0.1-py2.5.egg Processing dependencies for importlib Finished processing dependencies for importlib

mountainpaul commented 14 years ago

Ahhh, I see it is a different importlib