Skip to content

Commit

Permalink
fix: offset fee for 1 duff in commission in wallet_basic.py due to mi…
Browse files Browse the repository at this point in the history
…ssing bitcoin#22949
  • Loading branch information
knst committed Sep 22, 2024
1 parent 3ba99b9 commit d6946aa
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion test/functional/wallet_basic.py
Original file line number Diff line number Diff line change
Expand Up @@ -466,7 +466,9 @@ def run_test(self):
self.sync_all(self.nodes[0:3])
postbalance = self.nodes[2].getbalance()
fee = prebalance - postbalance - amount
assert_fee_amount(fee, tx_size, Decimal(fee_rate_btc_kvb))
# TODO: remove workaround after bitcoin/bitcoin#22949 done
workaround_offset = 1
assert_fee_amount(fee, tx_size - workaround_offset, Decimal(fee_rate_btc_kvb))

for key in ["totalFee", "feeRate"]:
assert_raises_rpc_error(-8, "Unknown named parameter key", self.nodes[2].sendtoaddress, address=address, amount=1, fee_rate=1, key=1)
Expand Down

0 comments on commit d6946aa

Please sign in to comment.