Skip to content

Commit

Permalink
thread safety test improved
Browse files Browse the repository at this point in the history
  • Loading branch information
mecid committed Jan 1, 2024
1 parent 76582cb commit 07bc349
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions Tests/UnidirectionalFlowTests/StoreTests.swift
Original file line number Diff line number Diff line change
Expand Up @@ -172,7 +172,7 @@ final class StoreTests: XCTestCase {

Task {
await withTaskGroup(of: Void.self) { group in
for _ in 1...1_000_000 {
for _ in 1...100_000 {
group.addTask {
await store.send(.increment)
}
Expand All @@ -185,7 +185,7 @@ final class StoreTests: XCTestCase {

wait(for: [expectation], timeout: 200)

XCTAssertEqual(store.counter, 1_000_000)
XCTAssertEqual(store.counter, 100_000)
}
}
}

0 comments on commit 07bc349

Please sign in to comment.