channeldb: remove graph calls from tests

The channeldb no longer depends on the graph. So remove the use of
MakeTestGraph from tests.
This commit is contained in:
Elle Mouton
2025-04-05 19:38:20 +02:00
parent a5c1219999
commit 5d7c6c4b60
2 changed files with 11 additions and 19 deletions

View File

@@ -6,7 +6,6 @@ import (
"github.com/btcsuite/btcwallet/walletdb"
"github.com/go-errors/errors"
graphdb "github.com/lightningnetwork/lnd/graph/db"
"github.com/lightningnetwork/lnd/kvdb"
"github.com/stretchr/testify/require"
)
@@ -22,13 +21,6 @@ func applyMigration(t *testing.T, beforeMigration, afterMigration func(d *DB),
}
cdb.dryRun = dryRun
// Create a test node that will be our source node.
testNode := createTestVertex(t)
graph, err := graphdb.MakeTestGraph(t)
require.NoError(t, err)
require.NoError(t, graph.SetSourceNode(testNode))
// beforeMigration usually used for populating the database
// with test data.
beforeMigration(cdb)