Opened 17 years ago
Last modified 13 years ago
#263 new enhancement
[PATCH] Support the CUnit xml format
Reported by: | jeberger@… | Owned by: | osimons |
---|---|---|---|
Priority: | major | Milestone: | 0.6.1 |
Component: | Build slave | Version: | 0.5.3 |
Keywords: | Cc: | jeberger@… | |
Operating System: |
Description
Add support for the CUnit xml format (http://cunit.sourceforge.net/)
Attachments (5)
Change History (11)
Changed 17 years ago by jeberger@…
comment:1 Changed 15 years ago by Jérôme M. Berger <jeberger@…>
The first patch counted failed assertions instead of failed tests. Since there is no way to count successful assertions anyway, I've attached a new patch to keep track of which tests were already seen in a failure report and only count failed tests once.
The new patch must be applied after the first one.
comment:2 Changed 15 years ago by osimons
- Owner changed from cmlenz to osimons
Looks useful. The second patch is a patch on top of the first?
I'd really like a unittest case to go with the patch that shows the format and how it is parsed, and would need to update the command-reference docs too.
I don't have a development setup for this, but I see Cunit in macports so installing it should likely not be an issue. Could you help me out with a build script to create output + parse it based for instance on the Cunit example file: http://cunit.sourceforge.net/example.html
Then I can actually test the parsing, and perhaps also help write unittest for the command.
comment:3 Changed 15 years ago by osimons
- Milestone changed from 0.6 to 0.6.1
comment:4 Changed 15 years ago by J. Berger <jeberger@…>
Replying to osimons:
Looks useful. The second patch is a patch on top of the first?
I'd really like a unittest case to go with the patch that shows the format and how it is parsed, and would need to update the command-reference docs too.
I don't have a development setup for this, but I see Cunit in macports so installing it should likely not be an issue. Could you help me out with a build script to create output + parse it based for instance on the Cunit example file: http://cunit.sourceforge.net/example.html
Then I can actually test the parsing, and perhaps also help write unittest for the command.
Sorry I missed that one. Yes, the second patch is on top of the first, and the third is on top of the second ;) I'm attaching a simple example source with some successes and some failures and the corresponding .xml file.
comment:5 Changed 15 years ago by J. Berger <jeberger@…>
I've added a third patch on top of the second. This patch adds "traceback" information to the report so that it can be visible inline in the "Test Results" table (in fact, only the file:line and information about the failed assertions are included, not a full traceback).
comment:6 Changed 13 years ago by J. Berger <jeberger@…>
- Cc jeberger@… added
When I wrote those patches, CUnit did not support ignoring tests. Now it does, but it only reports the total number of ignored tests that were skipped during processing (and not even all of them). According to Documentation/reports.html, Bitten requires a list of the ignored tests. I have submitted a patch to CUnit (number 3511444) to keep track of the ignored tests.
Here is a patch that uses this information to report the number of ignored tests in Bitten. This patch goes on top of the previous three patches.
Patch against trunk revision 519