Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to output coverage XML with nosetests?

I'm trying to output the coverage XML of my nosetests so they show up on Hudson. The line I'm executing is:

nosetests --with-gae -v --all-modules --with-xunit --with-coverage

I see the coverage output in the console, but there's no xml file containing the coverage data. How can I get it to output the coverage xml?

like image 330
Cuga Avatar asked Jan 21 '11 03:01

Cuga


1 Answers

Once you've run the nosetests command, there will be a .coverage data file in the directory. If you then run coverage xml, it will create a Cobertura-compatible XML file from the .coverage file.

like image 77
Ned Batchelder Avatar answered Sep 24 '22 20:09

Ned Batchelder