File tree Expand file tree Collapse file tree 1 file changed +18
-0
lines changed
src/beman/optional26/tests Expand file tree Collapse file tree 1 file changed +18
-0
lines changed Original file line number Diff line number Diff line change @@ -62,3 +62,21 @@ set_tests_properties(constructor_fails PROPERTIES WILL_FAIL true)
62
62
# Alternatively -- check for a particular regex to pass
63
63
# set_tests_properties(constructor_fails PROPERTIES PASS_REGULAR_EXPRESSION
64
64
# "Assert true")
65
+
66
+ # test if the targets are findable from the build directory
67
+ if(CMAKE_BUILD_TYPE STREQUAL Debug)
68
+ add_test(
69
+ NAME find-package-test
70
+ COMMAND
71
+ ${CMAKE_CTEST_COMMAND}
72
+ # --verbose
73
+ --output-on-failure -C $<CONFIG> --build-and-test
74
+ "${PROJECT_SOURCE_DIR}"
75
+ "${CMAKE_CURRENT_BINARY_DIR}/find-package-test" --build-generator
76
+ ${CMAKE_GENERATOR} --build-makeprogram ${CMAKE_MAKE_PROGRAM}
77
+ --build-options "-DCMAKE_CXX_COMPILER=${CMAKE_CXX_COMPILER}"
78
+ "-DCMAKE_CXX_STANDARD =${CMAKE_CXX_STANDARD}"
79
+ "-DCMAKE_BUILD_TYPE =$< CONFIG>"
80
+ "-DCMAKE_PREFIX_PATH =${CMAKE_PREFIX_PATH}"
81
+ )
82
+ endif()
You can’t perform that action at this time.
0 commit comments