Skip to content

Commit c10b9b4

Browse files
committed
test: extend AIGC tags to event tests
1 parent f585a94 commit c10b9b4

8 files changed

Lines changed: 21 additions & 7 deletions

File tree

‎.agents/skills/openswiftui-test-authoring/SKILL.md‎

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,8 @@ description: Route OpenSwiftUI test authoring and review work to the appropriate
2020
- Follow the organization and naming of the nearest tests in the same target.
2121
- Sort import declarations alphabetically by imported module name, preserving any
2222
attributes attached to each declaration.
23+
- Mark suites/tests that contain AI-generated Swift Testing tests with `.tags(.aigc)`
24+
on `@Suite` or `@Test`. Also add `import OpenSwiftUITestsSupport` if not imported yet.
2325
- In Swift Testing, prefer `@Test(arguments:)` when cases share the same test
2426
body. Keep different behaviors in separate tests.
2527
- Give argument collections explicit types when inference is ambiguous,

‎Tests/OpenSwiftUICoreTests/Event/Event/EventDebugTests.swift‎

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,9 +3,10 @@
33
// OpenSwiftUICoreTests
44

55
@_spi(ForOpenSwiftUIOnly) @testable import OpenSwiftUICore
6+
import OpenSwiftUITestsSupport
67
import Testing
78

8-
@Suite(.serialized)
9+
@Suite(.serialized, .tags(.aigc))
910
struct EventDebugTriggersTests {
1011
@Test
1112
func rawValues() {
@@ -60,6 +61,7 @@ struct EventDebugTriggersTests {
6061
}
6162
}
6263

64+
@Suite(.tags(.aigc))
6365
struct InheritedPhaseDescriptionTests {
6466
@Test(arguments: [
6567
(0, "[ ]"),

‎Tests/OpenSwiftUICoreTests/Event/Event/PanEventTests.swift‎

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,9 +6,10 @@ import Foundation
66
@_spi(ForOpenSwiftUIOnly)
77
@_spi(_)
88
@testable import OpenSwiftUICore
9+
import OpenSwiftUITestsSupport
910
import Testing
1011

11-
@Suite
12+
@Suite(.tags(.aigc))
1213
struct PanEventTests {
1314
@Test
1415
func initializationFromValues() {

‎Tests/OpenSwiftUICoreTests/Event/Gesture/GestureDebugTests.swift‎

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,7 @@ import OpenAttributeGraphShims
1111
@_private(sourceFile: "GestureDebug.swift")
1212
#endif
1313
import OpenSwiftUICore
14+
import OpenSwiftUITestsSupport
1415
#if !OPENSWIFTUI_SWIFT_LOG
1516
import OSLog
1617
#endif
@@ -229,7 +230,10 @@ private func makeData(
229230

230231
#if !OPENSWIFTUI_SWIFT_LOG
231232
@MainActor
232-
@Suite(.disabled(if: isX86_64, "OSLogStore does not reliably return current-process log entries on x86_64 simulator."))
233+
@Suite(
234+
.disabled(if: isX86_64, "OSLogStore does not reliably return current-process log entries on x86_64 simulator."),
235+
.tags(.aigc)
236+
)
233237
struct GestureDebugLogTests {
234238
// NOTE: entry.date has some range diff. So we can't use $0.date > date. Use count instead.
235239
@available(iOS 15, macOS 12, *)
@@ -290,6 +294,7 @@ struct GestureDebugLogTests {
290294
#endif
291295

292296
#if OPENSWIFTUI_ENABLE_PRIVATE_IMPORTS
297+
@Suite(.tags(.aigc))
293298
struct GestureDebugTests {
294299
@Test
295300
func frameDescriptionWithoutParent() {

‎Tests/OpenSwiftUICoreTests/Event/Responder/HitTestBindingModifierTests.swift‎

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,10 +11,11 @@ import OpenAttributeGraphShims
1111
@_private(sourceFile: "HitTestBindingModifier.swift")
1212
#endif
1313
import OpenSwiftUICore
14+
import OpenSwiftUITestsSupport
1415
import Testing
1516

1617
@MainActor
17-
@Suite(.disabled(if: attributeGraphVendor == .oag))
18+
@Suite(.disabled(if: attributeGraphVendor == .oag), .tags(.aigc))
1819
struct HitTestBindingModifierTests {
1920
// MARK: - Point Sampling
2021

‎Tests/OpenSwiftUICoreTests/Event/Responder/MultiViewResponderTests.swift‎

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,10 +6,11 @@
66

77
import OpenAttributeGraphShims
88
@_spi(ForOpenSwiftUIOnly) @testable import OpenSwiftUICore
9+
import OpenSwiftUITestsSupport
910
import Testing
1011

1112
@MainActor
12-
@Suite(.disabled(if: attributeGraphVendor == .oag))
13+
@Suite(.disabled(if: attributeGraphVendor == .oag), .tags(.aigc))
1314
struct MultiViewResponderTests {
1415
@Test
1516
func unchangedChildrenKeepObserverUntilNextChange() {

‎Tests/OpenSwiftUISymbolDualTests/Event/Gesture/GestureDebugDualTests.swift‎

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,7 @@
66
import Foundation
77
@_spi(ForOpenSwiftUIOnly)
88
import OpenSwiftUICore
9+
import OpenSwiftUITestsSupport
910
import OSLog
1011
import Testing
1112

@@ -226,7 +227,7 @@ private func makeData(
226227
}
227228

228229
@MainActor
229-
@Suite(.disabled(if: isX86_64, "OSLogStore does not reliably return current-process log entries on x86_64 simulator."))
230+
@Suite(.disabled(if: isX86_64, "OSLogStore does not reliably return current-process log entries on x86_64 simulator."), .tags(.aigc))
230231
struct GestureDebugDualTests {
231232
// NOTE: entry.date has some range diff. So we can't use $0.date > date. Use count instead.
232233
@available(iOS 15, macOS 12, *)

‎Tests/OpenSwiftUITests/Event/InputEvent/KeyPressTests.swift‎

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,10 +7,11 @@ import OpenAttributeGraphShims
77
@_spi(_)
88
@testable import OpenSwiftUI
99
@_spi(ForOpenSwiftUIOnly) import OpenSwiftUICore
10+
import OpenSwiftUITestsSupport
1011
import Testing
1112

1213
@MainActor
13-
@Suite(.disabled(if: attributeGraphVendor == .oag))
14+
@Suite(.disabled(if: attributeGraphVendor == .oag), .tags(.aigc))
1415
struct KeyPressTests {
1516
@Test(arguments: [
1617
(KeyPress.Phases(), 0, "[]"),

0 commit comments

Comments
 (0)