-
-
Notifications
You must be signed in to change notification settings - Fork 419
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Why not add a XML (cobertura format) output ? #21
Comments
I have every intention of merging that work back into the coverage.py trunk. I just need to find a little time... |
This feature is now checked in (as of <<changeset df70d70a32b2 (bb)>>), ready for testing. |
Original comment by cjulien (Bitbucket: cjulien, GitHub: cjulien) I test the xml output, and i was happy, my code seemed to be full covered.... but it wasn't.
the line 37 was effectively covered, the 38 was not... with a
it will really show the uncovered lines :)
Another issue in the xml is the filename field :
the filename shown here is the filename without extension....but this is not my filename, it is init.py ! I try to correct this in this way :
Hope it will be usefull :) |
Original comment by Tomi Kallio (Bitbucket: tomikall, GitHub: tomikall) cjulien's proposed fix for the "filename" attribute does the trick, at least Hudson's Cobertura plugin is able to find the right set of source files after applying the change. Here's a diff against the latest xmlreport.py:
What the Cobertura plugin wants is a relative path to a source file from the directory where coverage was run. In Python 2.6, the right path for the "filename" attribute can also be got from "os.path.relpath(cu.filename)". |
OK, I've applied this change (<<changeset e6f11f28504f (bb)>>). I suspect that cu.name is not always the right thing to use, but it certainly works better than before. |
This was necessary to implement receive_until() on TLS enabled connections. Fixes nedbat#21.
Originally reported by Anonymous
Hi,
I found here : https://software.sandia.gov/svn/public/tpl/coverage/branches/3.0.dev (referenced by https://software.sandia.gov/trac/acro/wiki/Development/Resources#TestCoverageAnalysis) an extended version of coverage.py module which support Cobertura output.
With this XML support, we could integrate Python coverage report analysis into tools like Hudson, Sonar...
Why not add it into the main trunk ;) ? (the license seems to still be in GPL...)
The text was updated successfully, but these errors were encountered: