diff --git a/core/gossipsub_test.go b/core/gossipsub_test.go index 6393f7c..2e02c99 100644 --- a/core/gossipsub_test.go +++ b/core/gossipsub_test.go @@ -200,7 +200,7 @@ func TestGossipSimulation(t *testing.T) { <-time.After(time.Second * 4) // TODO: avoid timeout // starting fresh trace after subscriptions - startupFaucets := traceFaucets{} + startupFaucets := newTraceFaucets() pubsubRpcCount := new(atomic.Uint64) for _, ctrl := range ctrls { startupFaucets.add(ctrl.psTracer.faucets) @@ -278,7 +278,7 @@ func TestGossipSimulation(t *testing.T) { <-time.After(time.Second * 2) // TODO: avoid timeout - faucets := traceFaucets{} + faucets := newTraceFaucets() var pubsubRpcCount uint64 for _, ctrl := range ctrls { nodeFaucets := ctrl.psTracer.faucets diff --git a/core/pubsub_trace.go b/core/pubsub_trace.go index 32017ad..075cc30 100644 --- a/core/pubsub_trace.go +++ b/core/pubsub_trace.go @@ -93,7 +93,7 @@ func (pst *psTracer) Reset() { defer pst.lock.Unlock() pst.events = nil - pst.faucets = traceFaucets{} + pst.faucets = newTraceFaucets() } func (pst *psTracer) Events() []eventFields {