|
1 # Load Google Test Framework |
|
2 set(CMAKE_CXX_STANDARD 17) |
|
3 |
|
4 include(FetchContent) |
|
5 FetchContent_Declare( |
|
6 googletest |
|
7 GIT_REPOSITORY https://github.com/google/googletest.git |
|
8 GIT_TAG e2239ee6043f73722e7aa812a459f54a28552929 # release 1.11.0 |
|
9 ) |
|
10 # For Windows: Prevent overriding the parent project's compiler/linker settings |
|
11 set(gtest_force_shared_crt ON CACHE BOOL "" FORCE) |
|
12 FetchContent_MakeAvailable(googletest) |
|
13 include(GoogleTest) |
|
14 message(STATUS "Google Test made available") |
|
15 |
|
16 add_executable(ucxtest |
|
17 test_utils.cpp |
|
18 test_allocator.cpp |
|
19 test_compare.cpp |
|
20 test_string.cpp |
|
21 test_buffer.cpp |
|
22 test_list.cpp |
|
23 test_tree.cpp |
|
24 test_hash_key.cpp |
|
25 test_map.cpp |
|
26 test_basic_mempool.cpp |
|
27 test_printf.cpp |
|
28 selftest.cpp |
|
29 util_allocator.cpp |
|
30 ) |
|
31 target_link_libraries(ucxtest PRIVATE ucx_static gtest_main) |
|
32 gtest_discover_tests(ucxtest) |