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 )
145 boost::shared_ptr< FuncType > func(
new FuncType( 6 ) );
153 TS_ASSERT_EQUALS( func->getResult(), 21 );
164 boost::shared_ptr< FuncType > func(
new FuncType( 100000000 ) );
172 TS_ASSERT( func->stopped() );
181 boost::shared_ptr< FuncType > func(
new FuncType( 5 ) );
193 TS_ASSERT_EQUALS( func->getResult(), 45 );
197 #ifdef WASSERT_AS_CASSERT
198 #define WASSERT_FLAG_CHANGED
199 #undefine WASSERT_AS_CASSERT
206 boost::shared_ptr< FuncType > func;
215 boost::shared_ptr< FuncType > func(
new FuncType( 5 ) );
219 #ifdef WASSERT_FLAG_CHANGED
220 #define WASSERT_AS_CASSERT
221 #undefine WASSERT_FLAG_CHANGED
257 if( strcmp( e.
what(),
"Test!" ) == 0 )
270 #endif // WWORKERTHREAD_TEST_H