Skip to content

Commit

Permalink
add timeout
Browse files Browse the repository at this point in the history
  • Loading branch information
MarcoPolo committed Jan 15, 2025
1 parent b183d5c commit 9f641ae
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions p2p/transport/websocket/websocket_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -615,7 +615,11 @@ func TestHTTPSProxyDoesSocks(t *testing.T) {
_, err = tpt.Dial(context.Background(), maToDial, "")
require.Error(t, err, "This should error as we don't have a real socks server")

if err := <-proxyServerErr; err != nil {
t.Fatal(err)
select {
case <-time.After(1 * time.Second):
case err := <-proxyServerErr:
if err != nil {
t.Fatal(err)
}
}
}

0 comments on commit 9f641ae

Please sign in to comment.