lntest: add new wait for conf helper method to ChainNotifier
This commit is contained in:
1 parent
12668b8af6
commit
0f59756b40
2 files changed
+42
-5
No files matched your search
@@ -18,6 +18,7 @@ import (
|
||||
"github.com/btcsuite/btcd/chaincfg/chainhash"
|
||||
"github.com/btcsuite/btcd/txscript"
|
||||
"github.com/btcsuite/btcd/wire"
|
||||
"github.com/davecgh/go-spew/spew"
|
||||
"github.com/lightningnetwork/lnd/channeldb"
|
||||
"github.com/lightningnetwork/lnd/lnrpc"
|
||||
"github.com/lightningnetwork/lnd/lnrpc/invoicesrpc"
|
||||
@@ -552,8 +553,10 @@ func (h HarnessTest) WaitForChannelCloseEvent(
|
||||
require.NoError(h, err)
|
||||
|
||||
resp, ok := event.Update.(*lnrpc.CloseStatusUpdate_ChanClose)
|
||||
require.Truef(h, ok, "expected channel close update, instead got %v",
|
||||
event.Update)
|
||||
require.Truef(
|
||||
h, ok, "expected channel close update, instead got %T: %v",
|
||||
event.Update, spew.Sdump(event.Update),
|
||||
)
|
||||
|
||||
txid, err := chainhash.NewHash(resp.ChanClose.ClosingTxid)
|
||||
require.NoErrorf(h, err, "wrong format found in closing txid: %v",
|
||||
|
||||
Reference in new issue
Block a user