Skip to content

Commit

Permalink
Add MainActor isolation to SegmentedUITests
Browse files Browse the repository at this point in the history
  • Loading branch information
Ryan Jarvis committed Nov 13, 2024
1 parent 8595144 commit 0dfa83e
Showing 1 changed file with 5 additions and 3 deletions.
8 changes: 5 additions & 3 deletions Example/ExampleUITests/SegmentedUITests.swift
Original file line number Diff line number Diff line change
Expand Up @@ -14,15 +14,17 @@ import XCTest
#endif

final class SegmentedUITests: ExampleUITestCase {
override var _sectionNavItem: (() throws -> XCUIElement)? {
@MainActor
override var _sectionNavItem: (@MainActor () throws -> XCUIElement)? {
segmentedNavItem
}

override var _picker: (() throws -> XCUIElement)? {
@MainActor
override var _picker: (@MainActor () throws -> XCUIElement)? {
segmentedPicker
}

func testSelectSegmentedPickerItems() throws {
func testSelectSegmentedPickerItems() async throws {
_ = try sectionNavItem().waitForExistence(timeout: 1)
XCTAssert(try sectionNavItem().exists, "Navigation link/tab for 'Segmented' picker must exist")
try sectionNavItem().trigger()
Expand Down

0 comments on commit 0dfa83e

Please sign in to comment.