From 9e4de3993c92b3d109c85b9b8fb771ea9d28fe56 Mon Sep 17 00:00:00 2001 From: Brandon Williams Date: Mon, 9 Sep 2024 11:23:19 -0400 Subject: [PATCH] Import only the implementation of Testing. --- Sources/SnapshotTesting/AssertSnapshot.swift | 2 +- Sources/SnapshotTesting/Internal/RecordIssue.swift | 2 +- Sources/SnapshotTesting/SnapshotsTestTrait.swift | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/Sources/SnapshotTesting/AssertSnapshot.swift b/Sources/SnapshotTesting/AssertSnapshot.swift index 24868e082..943f2150a 100644 --- a/Sources/SnapshotTesting/AssertSnapshot.swift +++ b/Sources/SnapshotTesting/AssertSnapshot.swift @@ -1,7 +1,7 @@ import XCTest #if canImport(Testing) - import Testing +@_implementationOnly import Testing #endif /// Enhances failure messages with a command line diff tool expression that can be copied and pasted diff --git a/Sources/SnapshotTesting/Internal/RecordIssue.swift b/Sources/SnapshotTesting/Internal/RecordIssue.swift index 214761180..58c22184e 100644 --- a/Sources/SnapshotTesting/Internal/RecordIssue.swift +++ b/Sources/SnapshotTesting/Internal/RecordIssue.swift @@ -1,7 +1,7 @@ import XCTest #if canImport(Testing) - import Testing + @_implementationOnly import Testing #endif var isSwiftTesting: Bool { diff --git a/Sources/SnapshotTesting/SnapshotsTestTrait.swift b/Sources/SnapshotTesting/SnapshotsTestTrait.swift index ae9a51ea3..d93e12222 100644 --- a/Sources/SnapshotTesting/SnapshotsTestTrait.swift +++ b/Sources/SnapshotTesting/SnapshotsTestTrait.swift @@ -1,5 +1,5 @@ #if canImport(Testing) - import Testing +@_implementationOnly import Testing @_spi(Experimental) extension Trait where Self == _SnapshotsTestTrait {