itest+lntest: fix itest re the new block driven behavior
This commit is contained in:
10 files changed
+445
-108
No files matched your search
@@ -2591,3 +2591,20 @@ func (h *HarnessTest) AssertWalletLockedBalance(hn *node.HarnessNode,
|
||||
require.NoError(h, err, "%s: timeout checking locked balance",
|
||||
hn.Name())
|
||||
}
|
||||
|
||||
// AssertNumPendingSweeps asserts the number of pending sweeps for the given
|
||||
// node.
|
||||
func (h *HarnessTest) AssertNumPendingSweeps(hn *node.HarnessNode, n int) {
|
||||
err := wait.NoError(func() error {
|
||||
resp := hn.RPC.PendingSweeps()
|
||||
num := len(resp.PendingSweeps)
|
||||
|
||||
if num == n {
|
||||
return nil
|
||||
}
|
||||
|
||||
return fmt.Errorf("want %d , got %d", n, num)
|
||||
}, DefaultTimeout)
|
||||
|
||||
require.NoErrorf(h, err, "%s: check pending sweeps timeout", hn.Name())
|
||||
}
|
||||
Reference in new issue
Block a user