diff --git a/p2p/net/swarm/dial_worker_test.go b/p2p/net/swarm/dial_worker_test.go index c404231270..d9d2ef37a4 100644 --- a/p2p/net/swarm/dial_worker_test.go +++ b/p2p/net/swarm/dial_worker_test.go @@ -115,7 +115,10 @@ func TestDialWorkerLoopBasic(t *testing.T) { t.Fatal("dial didn't complete") } - require.Equal(t, conn, conn2) + // can't use require.Equal here, as this does a deep comparison + if conn != conn2 { + t.Fatal("expecting the same connection from both dials") + } close(reqch) worker.wg.Wait()