initial commit
This commit is contained in:
26
tests/CMakeLists.txt
Normal file
26
tests/CMakeLists.txt
Normal file
@@ -0,0 +1,26 @@
|
||||
cmake_minimum_required(VERSION 3.10.1)
|
||||
|
||||
include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake)
|
||||
conan_basic_setup()
|
||||
|
||||
set(EXEC_TEST
|
||||
"test.cpp"
|
||||
)
|
||||
|
||||
add_executable(exec_test ${EXEC_TEST})
|
||||
|
||||
message("CONAN INCLUDE DIRS:")
|
||||
message("${CONAN_INCLUDE_DIRS}")
|
||||
message("CONAN LIB DIRS:")
|
||||
message("${CONAN_LIBS}")
|
||||
target_include_directories(exec_test
|
||||
PUBLIC
|
||||
${CONAN_INCLUDE_DIRS}
|
||||
)
|
||||
|
||||
target_link_libraries(exec_test
|
||||
PUBLIC
|
||||
gtest
|
||||
)
|
||||
|
||||
add_test(NAME exec_test COMMAND exec_test)
|
||||
10
tests/test.cpp
Normal file
10
tests/test.cpp
Normal file
@@ -0,0 +1,10 @@
|
||||
#include <gtest/gtest.h> // googletest header file
|
||||
|
||||
TEST(StrCompare, CStrNotEqual) {
|
||||
EXPECT_EQ(1, 1);
|
||||
}
|
||||
|
||||
int main(int argc, char **argv) {
|
||||
::testing::InitGoogleTest(&argc, argv);
|
||||
return RUN_ALL_TESTS();
|
||||
}
|
||||
Reference in New Issue
Block a user