Skip to content

Commit

Permalink
update test
Browse files Browse the repository at this point in the history
  • Loading branch information
MacOMNI committed Nov 4, 2024
1 parent abe31b7 commit 8ce22a8
Showing 1 changed file with 6 additions and 4 deletions.
10 changes: 6 additions & 4 deletions Networking/Tests/NetworkingTests/MockPeerEventTests.swift
Original file line number Diff line number Diff line change
Expand Up @@ -149,9 +149,10 @@ final class MockPeerEventTests {

// Attempt to connect
try clientConnection.connect(to: listenAddress)
try? await Task.sleep(for: .milliseconds(100))
try? await Task.sleep(for: .milliseconds(200))
#expect(throws: Error.self) {
try clientConnection.createStream()
let stream1 = try clientConnection.createStream()
try stream1.send(data: Data("test data 1".utf8))
}
}

Expand Down Expand Up @@ -255,9 +256,10 @@ final class MockPeerEventTests {

// Attempt to connect
try clientConnection.connect(to: listenAddress)
try? await Task.sleep(for: .milliseconds(100))
try? await Task.sleep(for: .milliseconds(200))
#expect(throws: Error.self) {
try clientConnection.createStream()
let stream1 = try clientConnection.createStream()
try stream1.send(data: Data("test data 1".utf8))
}
}

Expand Down

0 comments on commit 8ce22a8

Please sign in to comment.