diff --git a/internal/pool/bench_test.go b/internal/pool/bench_test.go index fc37b821..9b1fc57d 100644 --- a/internal/pool/bench_test.go +++ b/internal/pool/bench_test.go @@ -83,14 +83,14 @@ func BenchmarkPoolGetRemove(b *testing.B) { }) b.ResetTimer() - + rmvErr := errors.New("Bench test remove") b.RunParallel(func(pb *testing.PB) { for pb.Next() { cn, err := connPool.Get(ctx) if err != nil { b.Fatal(err) } - connPool.Remove(ctx, cn, errors.New("Bench test remove")) + connPool.Remove(ctx, cn, rmvErr) } }) })