25 #ifndef WWORKERTHREAD_TEST_H
26 #define WWORKERTHREAD_TEST_H
30 #include <cxxtest/TestSuite.h>
32 #include "../WWorkerThread.h"
33 #include "../WSharedObject.h"
71 for(
int i = 1; i <= *
m_input.get() && !shutdown(); ++i )
143 boost::shared_ptr< FuncType > func(
new FuncType( 6 ) );
151 TS_ASSERT_EQUALS( func->getResult(), 21 );
162 boost::shared_ptr< FuncType > func(
new FuncType( 100000000 ) );
170 TS_ASSERT( func->stopped() );
179 boost::shared_ptr< FuncType > func(
new FuncType( 5 ) );
191 TS_ASSERT_EQUALS( func->getResult(), 45 );
195 #ifdef WASSERT_AS_CASSERT
196 #define WASSERT_FLAG_CHANGED
197 #undefine WASSERT_AS_CASSERT
204 boost::shared_ptr< FuncType > func;
213 boost::shared_ptr< FuncType > func(
new FuncType( 5 ) );
217 #ifdef WASSERT_FLAG_CHANGED
218 #define WASSERT_AS_CASSERT
219 #undefine WASSERT_FLAG_CHANGED
255 if( strcmp( e.
what(),
"Test!" ) == 0 )
268 #endif // WWORKERTHREAD_TEST_H