Closed HannesHolste closed 8 years ago
I think you created this PR vs. updating the existing open one, right? Wanna close the other one (duplicated pushes)?
I think you are missing: https://github.com/qiita-spots/qp-deblur/blob/master/.travis.yml#L40
I created this one because semantically it's a separate issue from the 2 algorithm PRs. I was thinking you can merge this PR first, then the other ones if approved.
And thanks, good catch. Encountering this problem with nosetests --with-coverage
though. I tried googling for 10min and reading docs but didn't find a meaningful solution. Have you run into this before?
$ nosetests --with-coverage
........................
Name Stmts Miss Branch BrPart Cover
-----------------------------------------
Traceback (most recent call last):
File "/home/travis/miniconda3/envs/mdsa/bin/nosetests", line 6, in <module>
sys.exit(nose.run_exit())
File "/home/travis/miniconda3/envs/mdsa/lib/python2.7/site-packages/nose/core.py", line 121, in __init__
**extra_args)
File "/home/travis/miniconda3/envs/mdsa/lib/python2.7/unittest/main.py", line 95, in __init__
self.runTests()
File "/home/travis/miniconda3/envs/mdsa/lib/python2.7/site-packages/nose/core.py", line 207, in runTests
result = self.testRunner.run(self.test)
File "/home/travis/miniconda3/envs/mdsa/lib/python2.7/site-packages/nose/core.py", line 66, in run
result.printErrors()
File "/home/travis/miniconda3/envs/mdsa/lib/python2.7/site-packages/nose/result.py", line 110, in printErrors
self.config.plugins.report(self.stream)
File "/home/travis/miniconda3/envs/mdsa/lib/python2.7/site-packages/nose/plugins/manager.py", line 99, in __call__
return self.call(*arg, **kw)
File "/home/travis/miniconda3/envs/mdsa/lib/python2.7/site-packages/nose/plugins/manager.py", line 167, in simple
result = meth(*arg, **kw)
File "/home/travis/miniconda3/envs/mdsa/lib/python2.7/site-packages/nose/plugins/cover.py", line 190, in report
self.coverInstance.report(modules, file=stream)
File "/home/travis/miniconda3/envs/mdsa/lib/python2.7/site-packages/coverage/control.py", line 985, in report
return reporter.report(morfs, outfile=file)
File "/home/travis/miniconda3/envs/mdsa/lib/python2.7/site-packages/coverage/summary.py", line 140, in report
raise CoverageException("No data to report.")
coverage.misc.CoverageException: No data to report.
The command "nosetests --with-coverage" exited with 1.
The issue is with .coveragerc
, I think these values should be:
omit =
mdsa/tests*
*/__init__.py
*/*/__init__.py
data*
include = scripts/* mdsa/*
I recently saw a similar problem in one of our other repos, ended up doing something like this:
nosetests --with-coverage --cover-package=mdsa
I got rid of the coveragerc thing altogether.
@antgonza. I tried your suggestion but same error msg:
# this file is based on the examples provided on scikit-learn's .coveragerc
[run]
omit =
mdsa/tests*
*/*/__init__.py
data*
source = mdsa
branch = True
include = scripts/* mdsa/*
[report]
exclude_lines =
pragma: no cover
def __repr__
raise NotImplementedError
if __name__ == .__main__.:
omit =
mdsa/tests*
*/*/__init__.py
data*
@ElDeveloper: That worked.
Thanks for suggestions, guys. I made changes and rebased. Ready to merge after review.
Wonderful, thanks @HannesHolste! 👍
Resolves #3.
If you want, you can add the little coverage % indicator to the README, which you need to generate since I don't have access.