Boost logo

Boost Users :

From: Daryle Walker (darylew_at_[hidden])
Date: 2006-01-04 06:29:53

On 1/3/06 5:32 PM, "Gennadiy Rozental" <gennadiy.rozental_at_[hidden]>

> You need an output operator << for the boost::posix_time::ptime to be able
> to print values in test log.

Or you can put this line:
    BOOST_TEST_DONT_PRINT_LOG_VALUE( boost::posix_time::ptime );
at the file level before the first test that uses ptime. It will indicate
that ptime is unprintable. But any test macro that has the value and try to
print it will print out empty space instead. However, looking at the
Date-Time docs, ptime should have I/O operators. Make sure to #include
<boost/date_time/posix_time/posix_time.hpp>, and not
<boost/date_time/posix_time/posix_time_types.hpp>, which leaves out I/O (so
programs that are purely computation don't need to link a heavy subsystem).
Looking at the OP's code in the previous message, using the basic header was
the mistake (so ignore my original advice).

Daryle Walker
Mac, Internet, and Video Game Junkie
darylew AT hotmail DOT com

Boost-users list run by williamkempf at, kalb at, bjorn.karlsson at, gregod at, wekempf at