I'm using django-nose
in order to measuring coverage of my test suite.
I followed this doc to do this.
With the standard configuration works well, and i succeed in cover all my application.
I would exclude views
directory from the coverage without install new packages, so I tried to use --ignore-files
parameter in this way:
NOSE_ARGS = [
'--with-coverage',
'--cover-package=apps.my_app',
'--ignore-files=^views\\.'
]
My project structure is
+- root
|-- src
|--- main
|---- apps
|----- my_app
|------ views
|--- test
|---- main
|----- apps
|------ my_app
|------- views
And I run the test suite from project root with the following command:
python src\main\manage.py test --noinput main
Unfortunately it doesn't work correctly, I mean that django-nose seems ignore this option and views directory is included in the coverage.
What i'm missing?