0
0
Fork 0
mirror of https://github.com/bitcoin/bitcoin.git synced 2025-03-05 14:06:27 -05:00

test: Add sendall test for min-fee setting

This commit is contained in:
Aurèle Oulès 2022-12-01 20:25:58 +01:00
parent 02515117dc
commit cb44c5923a
No known key found for this signature in database
GPG key ID: 55F3976F7001D998

View file

@ -284,6 +284,12 @@ class SendallTest(BitcoinTestFramework):
recipients=[self.remainder_target],
fee_rate=100000)
@cleanup
def sendall_fails_on_low_fee(self):
self.log.info("Test sendall fails if the transaction fee is lower than the minimum fee rate setting")
assert_raises_rpc_error(-8, "Fee rate (0.999 sat/vB) is lower than the minimum fee rate setting (1.000 sat/vB)",
self.wallet.sendall, recipients=[self.recipient], fee_rate=0.999)
@cleanup
def sendall_watchonly_specific_inputs(self):
self.log.info("Test sendall with a subset of UTXO pool in a watchonly wallet")
@ -376,6 +382,9 @@ class SendallTest(BitcoinTestFramework):
# Sendall fails when providing a fee that is too high
self.sendall_fails_on_high_fee()
# Sendall fails when fee rate is lower than minimum
self.sendall_fails_on_low_fee()
# Sendall succeeds with watchonly wallets spending specific UTXOs
self.sendall_watchonly_specific_inputs()