I'm having a problem running django doctests with django-nose. Unit tests added to a /tests directory are running fine, but doctests are not.
I am trying to run doctests on 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 a basic doctest to try to get this to work, e.g.:
"""
>>> 1+1 == 2
True
"""
This is in my models.py. I've tried other doctests actually testing the code and still don't see any tests run. When I run with --verbosity 3, I see one line that may be the issue:
nose.selector: INFO: <models.py path> is executable; skipped
I couldn't find any more info on what this means though.
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 after south in INSTALLED_APPS as specified in the django-nose documentation. I'm using the --with-doctest argument as suggested here: Nose not running Django doctests, and have updated my django-nose to the latest as suggested here: Why isn't django-nose running the doctests in my models?
These are the versions I am using:
django 1.3
python 2.7.1
django-nose 0.1.3
nose 1.1.2
I feel like I'm missing some basic setup here. Let me know if any other info is needed. Any help is appreciated, thanks!