Skip to content

Commit

Permalink
refactor: move cmake test modules to main cmake file
Browse files Browse the repository at this point in the history
  • Loading branch information
abdes committed Mar 3, 2022
1 parent 0e4c044 commit c2f9fc2
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 7 deletions.
8 changes: 8 additions & 0 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -151,6 +151,11 @@ message(
"-- Building for ${CMAKE_BUILD_TYPE} with OPTION_CONTRACT_MODE : ${OPTION_CONTRACT_MODE}"
)

include(FetchContent)
# We make sure that we have 'third_party' in the name so that the targets get
# excluded from the generated target lists for the various tools.
set(FETCHCONTENT_BASE_DIR ${CMAKE_BINARY_DIR}/third_party_deps)

# ------------------------------------------------------------------------------
# Testing
# ------------------------------------------------------------------------------
Expand All @@ -161,7 +166,10 @@ if(ASAP_BUILD_TESTS)
asap_add_code_coverage_all_targets(EXCLUDE */test/* *googlemock* *googletest*
/usr/*)
include(Valgrind)

include(FetchGoogleTest)
include(GoogleTest)
include(CTest)
endif()

# ------------------------------------------------------------------------------
Expand Down
7 changes: 0 additions & 7 deletions third_party/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -6,13 +6,6 @@

message("=> [third-party modules]")

include(FetchContent)
# We make sure that we have 'third_party' in the name so that the targets get
# excluded from the generated target lists for the various tools.
set(FETCHCONTENT_BASE_DIR ${CMAKE_BINARY_DIR}/third_party_deps)

include(FetchGoogleTest)

# Live at Head philosophy. Always use the latest commit in the main branch in
# your projects.

Expand Down

0 comments on commit c2f9fc2

Please sign in to comment.