From 5d8af439e21e7fa06794d7da89900c67f9939d02 Mon Sep 17 00:00:00 2001 From: Stephen Celis Date: Wed, 11 Sep 2024 11:51:40 -0700 Subject: [PATCH] fix --- Sources/IssueReporting/IsTesting.swift | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/Sources/IssueReporting/IsTesting.swift b/Sources/IssueReporting/IsTesting.swift index 756c87e..e709534 100644 --- a/Sources/IssueReporting/IsTesting.swift +++ b/Sources/IssueReporting/IsTesting.swift @@ -30,9 +30,13 @@ if environment.keys.contains("XCTestBundlePath") { return true } if environment.keys.contains("XCTestConfigurationFilePath") { return true } if environment.keys.contains("XCTestSessionIdentifier") { return true } + return arguments.contains { argument in let path = URL(fileURLWithPath: argument) - return path.lastPathComponent == "xctest" || path.pathExtension == "xctest" + return path.lastPathComponent == "swiftpm-testing-helper" + || argument == "--testing-library" + || path.lastPathComponent == "xctest" + || path.pathExtension == "xctest" } } }