Skip to content

Commit 68e22b8

Browse files
authored
Fix fetch method causing test-drive tests to be included in CTest list (#18)
1 parent a1ab785 commit 68e22b8

File tree

2 files changed

+5
-2
lines changed

2 files changed

+5
-2
lines changed

Diff for: CMakeLists.txt

+4-2
Original file line numberDiff line numberDiff line change
@@ -96,5 +96,7 @@ install(
9696
)
9797

9898
# add the testsuite
99-
enable_testing()
100-
add_subdirectory("test")
99+
include(CTest)
100+
if(BUILD_TESTING AND TEST_DRIVE_BUILD_TESTING)
101+
add_subdirectory("test")
102+
endif()

Diff for: config/CMakeLists.txt

+1
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,7 @@
1212
# limitations under the License.
1313

1414
option(BUILD_SHARED_LIBS "Whether the libraries built should be shared" FALSE)
15+
option(TEST_DRIVE_BUILD_TESTING "Enable testing for this project" ON)
1516

1617
set(
1718
module-dir

0 commit comments

Comments
 (0)