diff --git a/itest/lnd_channel_graph_test.go b/itest/lnd_channel_graph_test.go index 566d02c9ca..54ddd2ca21 100644 --- a/itest/lnd_channel_graph_test.go +++ b/itest/lnd_channel_graph_test.go @@ -42,25 +42,23 @@ import ( // thus a following operation will fail if it relies on the channel being // enabled. func testUpdateChanStatus(ht *lntest.HarnessTest) { - // Create two fresh nodes and open a channel between them. - alice, bob := ht.Alice, ht.Bob - args := []string{ + // Prepare params. + chanAmt := btcutil.Amount(100_000) + openChannelParams := lntest.OpenChannelParams{ + Amt: chanAmt, + } + cfg := []string{ "--minbackoff=60s", "--chan-enable-timeout=3s", "--chan-disable-timeout=6s", "--chan-status-sample-interval=0.5s", } - ht.RestartNodeWithExtraArgs(alice, args) - ht.RestartNodeWithExtraArgs(bob, args) - ht.EnsureConnected(alice, bob) + cfgs := [][]string{cfg, cfg} - // Open a channel with 100k satoshis between Alice and Bob with Alice - // being the sole funder of the channel. - chanAmt := btcutil.Amount(100000) - chanPoint := ht.OpenChannel( - alice, bob, lntest.OpenChannelParams{Amt: chanAmt}, - ) - defer ht.CloseChannel(alice, chanPoint) + // Create two fresh nodes and open a channel between them. + chanPoints, nodes := ht.CreateSimpleNetwork(cfgs, openChannelParams) + chanPoint := chanPoints[0] + alice, bob := nodes[0], nodes[1] // assertEdgeDisabled ensures that Alice has the correct Disabled state // for given channel from her DescribeGraph.