mirror of
https://github.com/lightningnetwork/lnd.git
synced 2024-11-19 09:53:54 +01:00
test: in async bi-di payment test wait for both sides to see the channel
This commit is contained in:
parent
e324fe5818
commit
10ca654054
@ -2748,11 +2748,14 @@ func testBidirectionalAsyncPayments(net *networkHarness, t *harnessTest) {
|
||||
|
||||
// Wait for Alice to receive the channel edge from the funding manager.
|
||||
ctxt, _ = context.WithTimeout(ctxb, timeout)
|
||||
err = net.Alice.WaitForNetworkChannelOpen(ctxt, chanPoint)
|
||||
if err != nil {
|
||||
if err = net.Alice.WaitForNetworkChannelOpen(ctxt, chanPoint); err != nil {
|
||||
t.Fatalf("alice didn't see the alice->bob channel before "+
|
||||
"timeout: %v", err)
|
||||
}
|
||||
if err = net.Bob.WaitForNetworkChannelOpen(ctxt, chanPoint); err != nil {
|
||||
t.Fatalf("bob didn't see the bob->alice channel before "+
|
||||
"timeout: %v", err)
|
||||
}
|
||||
|
||||
// Open up a payment streams to Alice and to Bob, that we'll use to
|
||||
// send payment between nodes.
|
||||
@ -3043,7 +3046,9 @@ func TestLightningNetworkDaemon(t *testing.T) {
|
||||
ht := newHarnessTest(t1)
|
||||
ht.RunTestCase(testCase, lndHarness)
|
||||
})
|
||||
|
||||
// Stop at the first failure. Mimic behavior of original test
|
||||
// framework.
|
||||
if !success {
|
||||
break
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user