mirror of
https://github.com/lightningnetwork/lnd.git
synced 2025-02-21 22:11:41 +01:00
test: update integration test set up to reflect recent RPC change
A prior commit modified the walletbalance RPC to return satoshi instead of BTC. As a result, we need to update the SetUp method in the networkHarness to ensure we expect the proper value when asserting wallet balances.
This commit is contained in:
parent
7c5af4b851
commit
3b1db2b186
2 changed files with 3 additions and 4 deletions
|
@ -109,8 +109,7 @@ func (b *breachArbiter) Start() error {
|
|||
|
||||
// For each of the channels read from disk, we'll create a channel
|
||||
// state machine in order to watch for any potential channel closures.
|
||||
channelsToWatch := make([]*lnwallet.LightningChannel,
|
||||
len(activeChannels))
|
||||
channelsToWatch := make([]*lnwallet.LightningChannel, len(activeChannels))
|
||||
for i, chanState := range activeChannels {
|
||||
channel, err := lnwallet.NewLightningChannel(nil, b.notifier,
|
||||
b.estimator, chanState)
|
||||
|
|
|
@ -771,7 +771,7 @@ func (n *networkHarness) SetUp() error {
|
|||
}
|
||||
|
||||
// Now block until both wallets have fully synced up.
|
||||
expectedBalance := btcutil.Amount(btcutil.SatoshiPerBitcoin * 10).ToBTC()
|
||||
expectedBalance := int64(btcutil.SatoshiPerBitcoin * 10)
|
||||
balReq := &lnrpc.WalletBalanceRequest{}
|
||||
balanceTicker := time.Tick(time.Millisecond * 50)
|
||||
out:
|
||||
|
@ -1347,7 +1347,7 @@ func (n *networkHarness) SendCoins(ctx context.Context, amt btcutil.Amount,
|
|||
return err
|
||||
}
|
||||
|
||||
if currentBal.Balance == initialBalance.Balance+amt.ToBTC() {
|
||||
if currentBal.Balance == initialBalance.Balance+int64(amt) {
|
||||
return nil
|
||||
}
|
||||
case <-time.After(time.Second * 30):
|
||||
|
|
Loading…
Add table
Reference in a new issue