diff options
author | Tom Rondeau | 2010-09-30 16:08:53 -0400 |
---|---|---|
committer | Tom Rondeau | 2010-09-30 16:08:53 -0400 |
commit | 036a42c08eadbd0a2c462ca61d9d883996be8042 (patch) | |
tree | d81b162793427d25fd190da528afb8207be3ca88 /gnuradio-core/src/tests/test_runtime.cc | |
parent | c81312cee781a6912eb87f430096f3757e056b28 (diff) | |
download | gnuradio-036a42c08eadbd0a2c462ca61d9d883996be8042.tar.gz gnuradio-036a42c08eadbd0a2c462ca61d9d883996be8042.tar.bz2 gnuradio-036a42c08eadbd0a2c462ca61d9d883996be8042.zip |
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.
Diffstat (limited to 'gnuradio-core/src/tests/test_runtime.cc')
-rw-r--r-- | gnuradio-core/src/tests/test_runtime.cc | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/gnuradio-core/src/tests/test_runtime.cc b/gnuradio-core/src/tests/test_runtime.cc index 8549f2a9b..1efd9a0c0 100644 --- a/gnuradio-core/src/tests/test_runtime.cc +++ b/gnuradio-core/src/tests/test_runtime.cc @@ -1,6 +1,6 @@ /* -*- c++ -*- */ /* - * Copyright 2002 Free Software Foundation, Inc. + * Copyright 2002,2010 Free Software Foundation, Inc. * * This file is part of GNU Radio * @@ -21,6 +21,7 @@ */ #include <cppunit/TextTestRunner.h> +#include <cppunit/XmlOutputter.h> #include <qa_runtime.h> int @@ -28,8 +29,11 @@ main (int argc, char **argv) { CppUnit::TextTestRunner runner; + std::ofstream xmlfile("cppunit_test_runtime.xml"); + CppUnit::XmlOutputter *xmlout = new CppUnit::XmlOutputter(&runner.result(), xmlfile); runner.addTest (qa_runtime::suite ()); + runner.setOutputter(xmlout); bool was_successful = runner.run ("", false); |