From 70dacc6478bcb3eb6277df34d1070ec2730f9578 Mon Sep 17 00:00:00 2001 From: Fedor Korotkiy Date: Mon, 17 Apr 2023 14:01:22 +0400 Subject: [PATCH] Fix goroutine leak check --- dao/dao_test.go | 2 +- ledger/ledger_test.go | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/dao/dao_test.go b/dao/dao_test.go index 6b31a3f..eedc2fe 100644 --- a/dao/dao_test.go +++ b/dao/dao_test.go @@ -13,7 +13,7 @@ import ( ) func TestDao(t *testing.T) { - goleak.VerifyNone(t) + t.Cleanup(func() { goleak.VerifyNone(t) }) dsn := pgfixture.Start(t) ctx := context.Background() diff --git a/ledger/ledger_test.go b/ledger/ledger_test.go index 67d7e08..8cf66e2 100644 --- a/ledger/ledger_test.go +++ b/ledger/ledger_test.go @@ -16,7 +16,7 @@ import ( ) func TestLedger(t *testing.T) { - goleak.VerifyNone(t) + t.Cleanup(func() { goleak.VerifyNone(t) }) dsn := pgfixture.Start(t)