Boost logo

Boost Users :

Subject: [Boost-users] [logging+unittest]
From: Witold E Wolski (wewolski_at_[hidden])
Date: 2014-09-19 03:02:26


Hi,

I need to integrate some loggin into my unit to some extend bein
integration tests (hardware).

How best to call this function which sets up boost logging

void init() {

    boost::log::add_file_log("sample.log");

    boost::log::core::get()->set_filter
    (
        boost::log::trivial::severity >= boost::log::trivial::info
    );
}

if I have a test Runner looking like:

#define BOOST_TEST_MODULE MasterTestSuite
#include <boost/test/unit_test.hpp>

Is there a way not have to add the suites manually

Thanks.

-- 
Witold Eryk Wolski

Boost-users list run by williamkempf at hotmail.com, kalb at libertysoft.com, bjorn.karlsson at readsoft.com, gregod at cs.rpi.edu, wekempf at cox.net