macaroons: convert to use new kvdb abstraction
This commit is contained in:
4 files changed
+28
-25
No files matched your search
@@ -8,7 +8,7 @@ import (
|
||||
"path"
|
||||
"testing"
|
||||
|
||||
"github.com/coreos/bbolt"
|
||||
"github.com/lightningnetwork/lnd/channeldb/kvdb"
|
||||
"github.com/lightningnetwork/lnd/macaroons"
|
||||
"google.golang.org/grpc/metadata"
|
||||
"gopkg.in/macaroon-bakery.v2/bakery"
|
||||
@@ -33,8 +33,9 @@ func setupTestRootKeyStorage(t *testing.T) string {
|
||||
if err != nil {
|
||||
t.Fatalf("Error creating temp dir: %v", err)
|
||||
}
|
||||
db, err := bbolt.Open(path.Join(tempDir, "macaroons.db"), 0600,
|
||||
bbolt.DefaultOptions)
|
||||
db, err := kvdb.Create(
|
||||
kvdb.BoltBackendName, path.Join(tempDir, "macaroons.db"), true,
|
||||
)
|
||||
if err != nil {
|
||||
t.Fatalf("Error opening store DB: %v", err)
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user