tester is a basic interface to test functions and test cases in C++
Clone the repository to your directory
git clone --recurse-submodules https://github.com/xaprier/tester.gitEnter the direcotry of the source code
cd tester/Build the makefile with CMake, if you don't have cmake you have to install it.
cmake -G "Unix Makefiles" -B "build"Than our Makefile is ready for build the source code. We have to access the directory of makefile and run make.
cd build && make -j$(nproc)Than our compiled library is ready for run in the directory of the makefile with the name "Tester_simple_app" You can run the sample program with this command
./Tester_simple_appYou can use this project as an library to link your project with CMake.
- Add the repository to any place where you put libs as an git submodule.
git submodule add https://github.com/xaprier/tester.git lib/tester # if you have lib directory in your project for an example- Add the project directory to your CMake project
add_subdirectory(lib/tester)- Link the library to your target
target_link_libraries(myproject PRIVATE Tester) # Tester is the project name in my CMake project.- Everything is complete, now you can use this project as a library in your project.
- CMake(Building project)
- Git(Just for cloning repository)