Skip to content

Commit 829cae6

Browse files
committed
Try to fix CLSLogQueueTests
1 parent 99dafa7 commit 829cae6

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

Tests/TecoCLSLoggingTests/CLSLogQueueTests.swift

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ final class CLSLogQueueTests: XCTestCase {
99
let batches = ManagedAtomic(0)
1010
func upload(_ logs: [Cls_LogGroup]) throws -> String {
1111
XCTAssertLessThanOrEqual(logs.count, 2)
12-
batches.wrappingIncrement(ordering: .relaxed)
12+
batches.wrappingIncrement(ordering: .sequentiallyConsistent)
1313
return "mock-upload-id"
1414
}
1515

@@ -27,9 +27,10 @@ final class CLSLogQueueTests: XCTestCase {
2727

2828
// force flush the logger to upload logs
2929
try queue.forceFlush()
30+
try await Task.sleep(nanoseconds: 10_000_000)
3031

3132
// assert batch counts
32-
XCTAssertEqual(batches.load(ordering: .acquiring), 6)
33+
XCTAssertEqual(batches.load(ordering: .sequentiallyConsistent), 6)
3334
}
3435

3536
func testWaitDuration() async throws {

0 commit comments

Comments
 (0)