From 2bc3536299bed123b76e5ba454fecd0648758d26 Mon Sep 17 00:00:00 2001 From: cuiweixie Date: Tue, 2 Apr 2024 19:33:07 +0800 Subject: [PATCH] p2p/simulations: replace reflect.DeepEqual with maps.Equal --- p2p/simulations/http_test.go | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/p2p/simulations/http_test.go b/p2p/simulations/http_test.go index cd03e600f3..7f990eff0b 100644 --- a/p2p/simulations/http_test.go +++ b/p2p/simulations/http_test.go @@ -21,10 +21,10 @@ import ( "flag" "fmt" "log/slog" + "maps" "math/rand" "net/http/httptest" "os" - "reflect" "sync" "sync/atomic" "testing" @@ -459,7 +459,7 @@ loop: if actual[filter] > expected[filter] { t.Fatalf("received too many msgs for filter: %v", filter) } - if reflect.DeepEqual(actual, expected) { + if maps.Equal(actual, expected) { return }