[TIP] Coverage + nose, suppress printing of coverage information
Ned Batchelder
ned at nedbatchelder.com
Sat Aug 2 16:07:44 PDT 2014
On 8/2/14 6:16 PM, Eric Larson wrote:
> Hello,
>
> I am using `nose` combined with `coverage` to test code coverage in
> several projects, and it is working well. However, I would like to be
> able to run nosetests and generate coverage information (i.e., the
> .coverage file) but *not* print the results of the coverage report to
> the terminal.
>
It sounds like you are using the coverage nose plugin. It prints a
textual report when the tests are finished.
> In my case, each PR on Github automatically sends info to Coveralls,
> which generates nice reports, so I don't need to see it. Moreover,
> having the printout makes it more difficult to scroll to the points in
> the tests that might have failed.
>
> Is there a way to generate coverage information but not print it out?
I prefer to use coverage to run nosetests rather than to run coverage
within nose. The nose plugin seems to have no option to skip the
report. "coverage run" will run a program under coverage measurement,
then later (if you wish), "coverage report" will report on the results.
>
> Cheers,
> Eric
>
>
>
> _______________________________________________
> testing-in-python mailing list
> testing-in-python at lists.idyll.org
> http://lists.idyll.org/listinfo/testing-in-python
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.idyll.org/pipermail/testing-in-python/attachments/20140802/79d49906/attachment.htm>
More information about the testing-in-python
mailing list