graph/db+sqldb: implement AddChannelEdge on SQLStore

In this commit, the `AddChannelEdge` method of the SQLStore is
implemented. Like the KVStore implementation, it makes use of the
available channel `batch.Scheduler` and also updates the reject and
channel caches.

This then lets us convert the following 2 unit tests to run against the
SQL backends:
- TestPartialNode
- TestAddChannelEdgeShellNodes
This commit is contained in:
Elle Mouton committed 2025-06-02 14:53:18 +02:00
1 parent c5f159f485
commit d93d104a66
5 files changed
+383 -2

No files matched your search

+2 -2
View File
@@ -261,7 +261,7 @@ func TestNodeInsertionAndDeletion(t *testing.T) {
func TestPartialNode(t *testing.T) {
t.Parallel()
graph := MakeTestGraph(t)
graph := MakeTestGraphNew(t)
// To insert a partial node, we need to add a channel edge that has
// node keys for nodes we are not yet aware
@@ -3332,7 +3332,7 @@ func TestPruneGraphNodes(t *testing.T) {
func TestAddChannelEdgeShellNodes(t *testing.T) {
t.Parallel()
graph := MakeTestGraph(t)
graph := MakeTestGraphNew(t)
// To start, we'll create two nodes, and only add one of them to the
// channel graph.