Debian Codegraph @

Tests/RunCMake/GoogleTest/Launcher.cmake

raw
1 enable_language(C)
2 include(GoogleTest)
3
4 enable_testing()
5
6 include(xcode_sign_adhoc.cmake)
7
8 add_executable(test_launcher test_launcher.c)
9
10 add_executable(launcher_test launcher_test.c)
11 xcode_sign_adhoc(launcher_test)
12 set(launcher
13 "$<TARGET_FILE:test_launcher>"
14 "" # Verify CMP0178's handling of an empty list item
15 "launcherparam"
16 "--"
17 )
18 set_property(TARGET launcher_test PROPERTY TEST_LAUNCHER "${launcher}")
19 set(emulator
20 "$<TARGET_FILE:test_launcher>"
21 "" # Verify CMP0178's handling of an empty list item
22 "emulatorparam"
23 "--"
24 )
25 set_property(TARGET launcher_test PROPERTY CROSSCOMPILING_EMULATOR "${emulator}")
26
27 gtest_discover_tests(
28 launcher_test
29 EXTRA_ARGS a "" b
30 WORKING_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR}
31 )
32
33 gtest_add_tests(
34 TARGET launcher_test
35 EXTRA_ARGS a "" b
36 WORKING_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR}
37 )