graph/db: thread context through MarkEdgeZombie

This commit is contained in:
Elle Mouton committed 2026-02-25 15:33:34 +02:00
1 parent bb38aa8922
commit c270367071
6 files changed
+17 -12

No files matched your search

+9 -4
View File
@@ -2929,6 +2929,7 @@ func TestChanUpdatesInHorizonBoundaryConditions(t *testing.T) {
// FilterKnownChanIDs is tested in TestFilterKnownChanIDs.
func TestFilterKnownChanIDsZombieRevival(t *testing.T) {
t.Parallel()
ctx := t.Context()
graph := MakeTestGraph(t)
@@ -2946,9 +2947,13 @@ func TestFilterKnownChanIDsZombieRevival(t *testing.T) {
}
// Mark channel 1 and 2 as zombies.
err := graph.MarkEdgeZombie(scid1.ToUint64(), [33]byte{}, [33]byte{})
err := graph.MarkEdgeZombie(
ctx, scid1.ToUint64(), [33]byte{}, [33]byte{},
)
require.NoError(t, err)
err = graph.MarkEdgeZombie(scid2.ToUint64(), [33]byte{}, [33]byte{})
err = graph.MarkEdgeZombie(
ctx, scid2.ToUint64(), [33]byte{}, [33]byte{},
)
require.NoError(t, err)
require.True(t, isZombie(scid1))
@@ -3299,7 +3304,7 @@ func TestStressTestChannelGraphAPI(t *testing.T) {
}
return graph.MarkEdgeZombie(
channel.id.ToUint64(),
ctx, channel.id.ToUint64(),
node1.PubKeyBytes,
node2.PubKeyBytes,
)
@@ -4592,7 +4597,7 @@ func TestGraphZombieIndex(t *testing.T) {
// If we mark the edge as a zombie manually, then it should show up as
// being a zombie once again.
err = graph.MarkEdgeZombie(
edge.ChannelID, node1.PubKeyBytes, node2.PubKeyBytes,
ctx, edge.ChannelID, node1.PubKeyBytes, node2.PubKeyBytes,
)
require.NoError(t, err, "unable to mark edge as zombie")