@@ -217,7 +217,13 @@ else()
217
217
add_executable (e2e-steps EXCLUDE_FROM_ALL ${CUKE_DYNAMIC_CPP_STEPS} )
218
218
# Mark this file as generated so it isn't required at CMake generation time (it is necessary when the target gets built though)
219
219
set_source_files_properties (${CUKE_DYNAMIC_CPP_STEPS} PROPERTIES GENERATED TRUE )
220
- target_link_libraries (e2e-steps ${CUKE_LIBRARIES} )
220
+ target_link_libraries (e2e-steps PRIVATE ${CUKE_LIBRARIES} )
221
+ #Boost test lib required for boost specific scenario "Predicate Message"
222
+ if (Boost_UNIT_TEST_FRAMEWORK_FOUND)
223
+ target_link_libraries (e2e-steps PRIVATE ${Boost_UNIT_TEST_FRAMEWORK_LIBRARY} )
224
+ else ()
225
+ set (CUKE_E2E_TAGS "--tags ~@boost" )
226
+ endif ()
221
227
222
228
set (CUKE_COMPILE_DYNAMIC_CPP_STEPS '"${CMAKE_COMMAND} " --build "${CMAKE_BINARY_DIR} " --target e2e-steps')
223
229
@@ -242,16 +248,17 @@ else()
242
248
COMPILE_DYNAMIC_CPP_STEPS=${CUKE_COMPILE_DYNAMIC_CPP_STEPS}
243
249
CUCUMBER_RUBY=${CUCUMBER_RUBY}
244
250
--format=junit "--out=${CMAKE_BINARY_DIR} /features"
251
+ ${CUKE_E2E_TAGS}
245
252
${ARGN}
246
253
${CUKE_FEATURES_DIR}
247
254
DEPENDS cucumber-cpp
248
255
${USES_TERMINAL}
249
256
)
250
257
endfunction (add_feature_target)
251
258
252
- add_feature_target(features --format progress)
253
- add_feature_target(features-pretty --format pretty)
254
- add_feature_target(features-wip --format pretty --tags @wip)
259
+ add_feature_target(features --format progress)
260
+ add_feature_target(features-pretty --format pretty)
261
+ add_feature_target(features-wip --format pretty --tags @wip)
255
262
256
263
else ()
257
264
message (WARNING "Could not find Cucumber: skipping end-to-end tests" )
0 commit comments