forked from quic-go/quic-go
fix flaky TestConnectionReceivePrioritization (#4936)
This commit is contained in:
@@ -1458,13 +1458,13 @@ func testConnectionReceivePrioritization(t *testing.T, handshakeComplete bool) i
|
||||
).AnyTimes()
|
||||
}
|
||||
|
||||
errChan := make(chan error, 1)
|
||||
go func() { errChan <- tc.conn.run() }()
|
||||
|
||||
for i := 0; i < 10; i++ {
|
||||
tc.conn.handlePacket(getShortHeaderPacket(t, tc.srcConnID, protocol.PacketNumber(i), []byte("foobar")))
|
||||
}
|
||||
|
||||
errChan := make(chan error, 1)
|
||||
go func() { errChan <- tc.conn.run() }()
|
||||
|
||||
select {
|
||||
case <-done:
|
||||
case <-time.After(time.Second):
|
||||
|
||||
Reference in New Issue
Block a user