From 036a42c08eadbd0a2c462ca61d9d883996be8042 Mon Sep 17 00:00:00 2001 From: Tom Rondeau Date: Thu, 30 Sep 2010 16:08:53 -0400 Subject: Adding an XML outputter for the CPP Unit tests. This is to a) store the output information but also b) for integration with Hudson for logging and displaying the results during the build stages. This only covers a few cases so far and I need to define a better place to save the output files. --- gruel/src/lib/test_gruel.cc | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) (limited to 'gruel/src/lib') diff --git a/gruel/src/lib/test_gruel.cc b/gruel/src/lib/test_gruel.cc index 669303447..cb5f2d36b 100644 --- a/gruel/src/lib/test_gruel.cc +++ b/gruel/src/lib/test_gruel.cc @@ -1,6 +1,6 @@ /* -*- c++ -*- */ /* - * Copyright 2006,2009 Free Software Foundation, Inc. + * Copyright 2006,2009,2010 Free Software Foundation, Inc. * * This file is part of GNU Radio * @@ -21,6 +21,7 @@ */ #include +#include #include "pmt/qa_pmt.h" int @@ -28,8 +29,11 @@ main(int argc, char **argv) { CppUnit::TextTestRunner runner; + std::ofstream xmlfile("cppunit_gruel.xml"); + CppUnit::XmlOutputter *xmlout = new CppUnit::XmlOutputter(&runner.result(), xmlfile); runner.addTest(qa_pmt::suite ()); + runner.setOutputter(xmlout); bool was_successful = runner.run("", false); -- cgit