mirror of
https://github.com/refraction-networking/uquic.git
synced 2025-04-04 20:57:36 +03:00
fix flaky HTTP/3 client unit test
This commit is contained in:
parent
3fff444db3
commit
393695d774
1 changed files with 2 additions and 2 deletions
|
@ -309,9 +309,9 @@ var _ = Describe("Client", func() {
|
|||
canceled := make(chan struct{})
|
||||
gomock.InOrder(
|
||||
str.EXPECT().CancelWrite(quic.ErrorCode(errorRequestCanceled)).Do(func(quic.ErrorCode) { close(canceled) }),
|
||||
str.EXPECT().CancelWrite(gomock.Any()).MaxTimes(1).Do(func(quic.ErrorCode) { close(done) }),
|
||||
str.EXPECT().CancelRead(quic.ErrorCode(errorRequestCanceled)).Do(func(quic.ErrorCode) { close(done) }),
|
||||
)
|
||||
str.EXPECT().CancelRead(quic.ErrorCode(errorRequestCanceled))
|
||||
str.EXPECT().CancelWrite(gomock.Any()).MaxTimes(1)
|
||||
str.EXPECT().Read(gomock.Any()).DoAndReturn(func([]byte) (int, error) {
|
||||
cancel()
|
||||
<-canceled
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue