Boost logo

Boost Users :

From: Gennadiy Rozental (gennadiy.rozental_at_[hidden])
Date: 2006-04-12 13:42:08


"Paul Giaccone" <paulg_at_[hidden]> wrote in message
news:4433AB1C.3080209_at_cinesite.co.uk...
> Boost unit test framework seems to have a race condition in its output.
>
> When I run my test program from a shell, I get this output:
>
> paulg_at_klingon 120% ./CubicTest
> Running 8 test cases...
>
> *** No errors detected
> paulg_at_klingon 121% ./CubicTest>/dev/null
>
> *** No errors detected
>
> Note that the second call above, redirecting output to /dev/null,
> suggests to me that "Running 8 test cases..." goes to standard out and
> "*** No errors detected" goes to standard error.
>
> Because standard error is unbuffered, this can mean that the messages
> are output in the reverse order. This is the case when I run my program
> from Eclipse (under Linux), and, in general, will happen if the tests
> run faster than the time it takes for the buffer to flush to the output.

Ok. I've added flush statement at the end of testing for log stream. This
with happened before report is started.

Gennadiy


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