Skip to content

Commit 17b537d

Browse files
committed
WIP
1 parent 603ecc0 commit 17b537d

File tree

1 file changed

+9
-19
lines changed

1 file changed

+9
-19
lines changed

Tests/Tests/ViewTypes/NavigationStackTests.swift

Lines changed: 9 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -1,23 +1,18 @@
11
#if !os(macOS)
22
import SwiftUI
33
import SwiftUIIntrospect
4-
import XCTest
4+
import Testing
55

6-
@available(iOS 16, tvOS 16, *)
76
@MainActor
8-
final class NavigationStackTests: XCTestCase {
7+
@Suite
8+
struct NavigationStackTests {
99
#if canImport(UIKit)
1010
typealias PlatformNavigationStack = UINavigationController
1111
#endif
1212

13-
func testNavigationStack() throws {
14-
guard #available(iOS 16, tvOS 16, *) else {
15-
throw XCTSkip()
16-
}
17-
18-
XCTAssertViewIntrospection(of: PlatformNavigationStack.self) { spies in
19-
let spy = spies[0]
20-
13+
@available(iOS 16, tvOS 16, *)
14+
@Test func introspect() async throws {
15+
try await introspection(of: PlatformNavigationStack.self) { spy in
2116
NavigationStack {
2217
ZStack {
2318
Color.red
@@ -30,14 +25,9 @@ final class NavigationStackTests: XCTestCase {
3025
}
3126
}
3227

33-
func testNavigationStackAsAncestor() throws {
34-
guard #available(iOS 16, tvOS 16, *) else {
35-
throw XCTSkip()
36-
}
37-
38-
XCTAssertViewIntrospection(of: PlatformNavigationStack.self) { spies in
39-
let spy = spies[0]
40-
28+
@available(iOS 16, tvOS 16, *)
29+
@Test func introspectAsAncestor() async throws {
30+
try await introspection(of: PlatformNavigationStack.self) { spy in
4131
NavigationStack {
4232
ZStack {
4333
Color.red

0 commit comments

Comments
 (0)