Skip to content

Commit

Permalink
Simple non-throwing serial queue test
Browse files Browse the repository at this point in the history
  • Loading branch information
mattmassicotte committed Oct 20, 2024
1 parent f66decf commit a781e0a
Showing 1 changed file with 12 additions and 0 deletions.
12 changes: 12 additions & 0 deletions Tests/QueueTests/AsyncSerialQueueTests.swift
Original file line number Diff line number Diff line change
Expand Up @@ -32,4 +32,16 @@ final class AsyncSerialQueueTests: XCTestCase {
throw AsyncSerialQueueError.problem
}
}

func testNonThrowingOperation() async {
let queue = AsyncSerialQueue()

let exp = expectation(description: "executed")

queue.addOperation {
exp.fulfill()
}

await fulfillment(of: [exp], timeout: 1.0)
}
}

0 comments on commit a781e0a

Please sign in to comment.