7 #ifndef THREADED_TEST_H 8 #define THREADED_TEST_H 12 #include <boost/shared_ptr.hpp> 13 #include <gtest/gtest.h> 65 boost::shared_ptr<util::thread::Thread>
thread_;
bool stopped_
Flag indicating that the thread is stopped.
void waitReady()
Wait for the thread to be ready.
void doWait(bool &flag)
Wait for a selected flag to be set.
bool stopping_
Flag indicating that the thread is stopping.
void waitStopping()
Wait for the thread to be stopping.
void doSignal(bool &flag)
Sets selected flag to true and signals condition variable.
ThreadedTest()
Constructor.
void waitStopped()
Wait for the thread to stop.
void signalReady()
Signal that thread is ready.
util::thread::Mutex mutex_
Mutex used to synchronize threads.
Encapsulation for a condition variable.
bool ready_
Flag indicating that the thread is ready.
Defines the logger used by the top-level component of kea-dhcp-ddns.
Mutex with very simple interface.
util::thread::CondVar condvar_
Condtional variable for thread waits.
void signalStopped()
Signal that thread is stopped.
void signalStopping()
Signal that thread is stopping.
Base class for tests requiring threads.
boost::shared_ptr< util::thread::Thread > thread_
Pointer to server thread.
bool isStopping()
Checks if the thread is stopping.