I have a problem with django doctests with django nose. Unit tests added to the / tests directory work fine, but the exercises are not.
I am trying to run doctrines in my season module:
python manage.py test season
and get this output:
nosetests --verbosity 1 season --with-doctest Creating test database for alias 'default'... ---------------------------------------------------------------------- Ran 0 tests in 0.001s OK Destroying test database for alias 'default'...
I'm just trying to do a basic lesson to try to get this to work, for example:
""" >>> 1+1 == 2 True """
This is in my models.py. I have tried other doctrines that actually test the code, and still don't see any tests. When I run with --verbosity 3, I see one line, which may be the problem:
nose.selector: INFO: <models.py path> is executable; skipped
I could no longer find information on what this means.
Relevant snippets from settings.py:
INSTALLED_APPS = ( 'south', 'django_nose', 'season', ) # Django-nose configuration TEST_RUNNER = 'django_nose.NoseTestSuiteRunner' NOSE_ARGS = ['--with-doctest']
django_nose is located after the south at INSTALLED_APPS, as indicated in the django-nose documentation. I use the --with-doctest argument suggested here: Nose doesn't launch Django boards , and updated my django nose to the last, as suggested here: Why doesn't the django nose launch doctrines in my models?
These are the versions I use:
django 1.3
python 2.7.1
django-nose 0.1.3
nose 1.1.2
I feel like I am missing a basic setup here. Let me know if any other information is needed. Any help is appreciated, thanks!