| home oakut |
Compiling Unit tests |
|
To build individual tests, one only needs to specify the the root of the oaklib directory in the compiler include path settings (/I or -I or specifying it in MS VC++ project settings tab).
For MS VC++ or Borland compiler, user must use (link) the dynamic multithread version of the C/C++ library (debug or non-debug). Note that the tests must be built as a dll (Windows) or .so files (unix). Users also need to build oak/test/tmain.cpp and link it with their tests. However, this step can be easily avoided if tests #include <oak/test/tmain.cpp> file in one unit test source file. Note that only one test source file should include tmain.cpp. |