lntest+itest: add new method AssertChannelInGraph
This commit replaces `AssertTopologyChannelOpen` with `AssertChannelInGraph`, which asserts a given channel edge is found. `AssertTopologyChannelOpen` only asserts a given edge has been received via the topology subscription, while we need to make sure the channel is in the graph before continuing our tests.
This commit is contained in:
25 files changed
+110
-87
No files matched your search
@@ -172,10 +172,10 @@ func testSphinxReplayPersistence(ht *lntest.HarnessTest) {
|
||||
invoiceResp := dave.RPC.AddInvoice(invoice)
|
||||
|
||||
// Wait for all channels to be recognized and advertized.
|
||||
ht.AssertTopologyChannelOpen(carol, chanPoint)
|
||||
ht.AssertTopologyChannelOpen(dave, chanPoint)
|
||||
ht.AssertTopologyChannelOpen(carol, chanPointFC)
|
||||
ht.AssertTopologyChannelOpen(fred, chanPointFC)
|
||||
ht.AssertChannelInGraph(carol, chanPoint)
|
||||
ht.AssertChannelInGraph(dave, chanPoint)
|
||||
ht.AssertChannelInGraph(carol, chanPointFC)
|
||||
ht.AssertChannelInGraph(fred, chanPointFC)
|
||||
|
||||
// With the invoice for Dave added, send a payment from Fred paying
|
||||
// to the above generated invoice.
|
||||
@@ -417,7 +417,7 @@ func testMaxPendingChannels(ht *lntest.HarnessTest) {
|
||||
// Ensure that the funding transaction enters a block, and is
|
||||
// properly advertised by Alice.
|
||||
ht.AssertTxInBlock(block, fundingTxID)
|
||||
ht.AssertTopologyChannelOpen(alice, fundingChanPoint)
|
||||
ht.AssertChannelInGraph(alice, fundingChanPoint)
|
||||
|
||||
// The channel should be listed in the peer information
|
||||
// returned by both peers.
|
||||
|
||||
Reference in new issue
Block a user