mity / acutest

Simple header-only C/C++ unit testing facility.
MIT License
347 stars 96 forks source link

“Test Anything Protocol” output mode #16

Closed sandhose closed 5 years ago

sandhose commented 5 years ago

TAP (Test Anything Protocol) is a simple text protocol to deal with test results. It should be quite easy to implement, and would make acutest easily integrate with existing tools.

A TAP output looks like this:

1..4
ok 1 - Input file opened
not ok 2 - First line of the input valid
ok 3 - Read the rest of the file
not ok 4 - Summarized correctly # TODO Not written yet

It would enable for example to produce JUnit XML files for the test results and displaying them in GitLab merge requests, or to display the test results in Jenkins easily

mity commented 5 years ago

I have cooked something in PR #17.

Given I do not have any TAP harnessing running anywhere, it would be cool if you could test it before I merge it.

To enable it, use the new --tap option.