Skip to content

Commit

Permalink
Don't use async version of expectations in tests
Browse files Browse the repository at this point in the history
  • Loading branch information
joemasilotti committed Sep 13, 2023
1 parent a40fef9 commit f11ab39
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions Tests/SessionTests.swift
Original file line number Diff line number Diff line change
Expand Up @@ -134,13 +134,13 @@ class SessionTests: XCTestCase {
// MARK: - Server

@MainActor
private func visit(_ path: String) async {
private func visit(_ path: String) {
let expectation = self.expectation(description: "Wait for request to load.")
sessionDelegate.didChange = { expectation.fulfill() }

let visitable = TestVisitable(url: url(path))
session.visit(visitable)
await fulfillment(of: [expectation])
wait(for: [expectation])
}

private func url(_ path: String) -> URL {
Expand Down

0 comments on commit f11ab39

Please sign in to comment.