From b3490f912edec67917dfc60eb58d7f34d311d7ba Mon Sep 17 00:00:00 2001 From: Maxim Lebedev Date: Tue, 28 Dec 2021 06:06:31 +0500 Subject: [PATCH] :truck: Moved bolt testing util to testing/bolttest package --- .../{util/test_bolt.go => testing/bolttest/bolttest.go} | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) rename internal/{util/test_bolt.go => testing/bolttest/bolttest.go} (76%) diff --git a/internal/util/test_bolt.go b/internal/testing/bolttest/bolttest.go similarity index 76% rename from internal/util/test_bolt.go rename to internal/testing/bolttest/bolttest.go index e1160ae..6b02e6f 100644 --- a/internal/util/test_bolt.go +++ b/internal/testing/bolttest/bolttest.go @@ -1,4 +1,4 @@ -package util +package bolttest import ( "os" @@ -9,9 +9,9 @@ import ( bolt "go.etcd.io/bbolt" ) -// TestBolt returns a temporary empty database bbolt in the temporary directory +// New returns a temporary empty database bbolt in the temporary directory // with the cleanup function. -func TestBolt(tb testing.TB) (*bolt.DB, func()) { +func New(tb testing.TB) (*bolt.DB, func()) { tb.Helper() f, err := os.CreateTemp(os.TempDir(), "bbolt_*.db")