Read-only mirrors. Development, issues and pull requests are on GitHub.

summaryrefslogtreecommitdiffhomepage
path: root/extras
diff options
context:
space:
mode:
authorPhil Nash2026-07-10 16:42:51 +0100
committerMartin Hořeňovský2026-07-22 20:50:17 +0200
commiteb431764b4cb9b6fa2296a034b4231064f8e464e (patch)
treef486843060010eabadde982f69a7da2175c3ae10 /extras
parentae5d271da2c88b859d6365281ac075112115d4b1 (diff)
downloadcatch3-eb431764b4cb9b6fa2296a034b4231064f8e464e.tar.gz
Document that DISCOVERY_MODE PRE_TEST should be used with catch_discover_tests when used with XCode.
This addresses https://github.com/catchorg/Catch2/issues/2411 by making the "workaround" the official approach and is consistent with how gtest and cmake deal with the same situation.
Diffstat (limited to 'extras')
-rw-r--r--extras/Catch.cmake6
1 files changed, 6 insertions, 0 deletions
diff --git a/extras/Catch.cmake b/extras/Catch.cmake
index 657bb724..9426f67f 100644
--- a/extras/Catch.cmake
+++ b/extras/Catch.cmake
@@ -146,6 +146,12 @@ same as the Catch name; see also ``TEST_PREFIX`` and ``TEST_SUFFIX``.
calling ``catch_discover_tests``. This provides a mechanism for globally selecting
a preferred test discovery behavior without having to modify each call site.
+ On Apple Silicon with the Xcode generator you must use ``PRE_TEST``. With the
+ default ``POST_BUILD`` mode the build fails with ``Result: Subprocess killed``,
+ because macOS on Apple Silicon refuses to run unsigned binaries and Xcode
+ code-signs the test executable only after the post-build script that
+ ``POST_BUILD`` mode uses to run it for test discovery. See Catch2 issue #2411.
+
``SKIP_IS_FAILURE``
Disables skipped test detection.