From 98da32ad15823d934108ecb807f3998d45c927b7 Mon Sep 17 00:00:00 2001 From: Stuart Montgomery Date: Wed, 27 Aug 2025 22:11:39 -0500 Subject: [PATCH] Clarify note about supported target types in "Defining test functions" article --- Sources/Testing/Testing.docc/DefiningTests.md | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/Sources/Testing/Testing.docc/DefiningTests.md b/Sources/Testing/Testing.docc/DefiningTests.md index 6b8cc4f00..237a64b4e 100644 --- a/Sources/Testing/Testing.docc/DefiningTests.md +++ b/Sources/Testing/Testing.docc/DefiningTests.md @@ -25,8 +25,9 @@ contains the test: import Testing ``` -- Note: Only import the testing library into a test target. Importing the - testing library into an application, library, or binary target isn't +- Note: Only import the testing library into a test target or library meant for + test targets. Importing the testing library into a target intended for + distribution such as an application, app library, or executable target isn't supported or recommended. Test functions aren't stripped from binaries when building for release, so logic and fixtures of a test may be visible to anyone who inspects a build product that contains a test function.