So the high-level issue I want to resolve is to ignore test and migration files from the coverage report. The TEST_COVERAGE_WITH_MIGRATIONS flag isn't working for me (want_file from https://github.com/lincolnloop/django-discover-jenkins/blob/master/discover_jenkins/tasks/with_coverage.py#L93-L94 is never being executed for me because the measured_files list comes in empty anyways), which is okay, because I was planning on using the coverage.rc file anyways.
It appears that what's happening is that coverage is first processing the config_file, which properly sets the omits. Then, it reads the omit kwarg passed in, which, in my case, is empty. This, however, overwrites it, so it doesn't omit anything.
My current workaround is to put the omits as the folders setting, though the naming is a little strange (though the implementation works):
TEST_COVERAGE_EXCLUDES_FOLDERS = [
'*/migrations/*',
'*/tests.py',
'*/test_*.py',
]
So the right affordances are in here to make it work, though it did take me some digging to figure out. I would be glad for a fix for the coverage.rc file to be honored in its entirety, but I would also be happy to just see a caveats in the documentation that omit in the coverage.rc file will be ignored and to use the other settings.
Let me know if I can provide any other information or help on this.