$include_dir="/home/hyper-archives/boost-users/include"; include("$include_dir/msg-header.inc") ?>
From: Gennadiy Rozental (gennadiy.rozental_at_[hidden])
Date: 2006-06-02 17:08:25
> "Wu Yinghui, Freddie" <yhwu_at_[hidden]> wrote in message 
> news:447FA165.5040008_at_volumeinteractions.com...
> Dear all,
>
> I've been trying to write some test code that involves 2 concurrent
> threads of execution. But I found that there are occasional crashes in
> the test tool code when some BOOST_CHECK_*() are triggered.
>
> So my question is: Are Boost test tools designed to be used in multiple
> threads?
Short answer - no. The test framework is reentrant, but not thread safe. 
This is a conscious decision. At the moment I do not know the best API to 
use for critical section guarding. Your best bet would be to wrap Boost.Test 
tools with your own that does invoke guards. Also you could make sure 
somehow that all test tools invoked from single thread. Or... you could 
present solution that would incorporate fix into test framework.
Gennadiy