views:

44

answers:

1

Hi,

I am involved in development of unit level test cases for our project. There are both managed code and native C++ code. After some study I chose NUnit for managed code. I would either use Gallio or FireBenchmarks which is an extension to provide HTML outputs and charts etc.

Do we have extensions like this for cppUnit or Boost.Test ? I have not decided which one to use. If there are none, which of these would be easier to extend to enable such a plugin ?

Please give your suggestions on this.

A: 

You can configure Boost.Test to generate XML output. The doc says:

This log format is designed for automated test results processing. The test log output XML schema depends on the active log level threshold.

This can be enabled by specifying -output_format=XML on the command line, or by setting the environment variable BOOST_TEST_OUTPUT_FORMAT=XML. The related docs are here.

It is also possible to configure Boost.Test at compile time to produce XML output by default (described here)

In order to generate HTML you either need to implement your own formatter (which is possible, but nicely underdocumented, so please ask on the list) or to transform the XML in a postprocessing step.

hkaiser
Thanks Kaiser, Rather than XML, we prefer HTML format. Do we have the xml->HTML formatter? Kindly help on that
sprasad
I don't know of any xml-->html converters, but that doesn't mean there won't exist one. It shouldn't be too dificult to create a custom formatter for Boost.Test directly emitting html, though.
hkaiser