diff options
author | Jon Atack <jon@atack.com> | 2020-12-02 13:55:26 +0100 |
---|---|---|
committer | Jon Atack <jon@atack.com> | 2021-05-09 12:50:04 +0200 |
commit | 847288df07b45ca535c849e518b22818ab492896 (patch) | |
tree | 74a66d7c4ca910a1662e9afd087053707f57f0fb /test/functional/rpc_fundrawtransaction.py | |
parent | 06a90fa0381c790f7bde2ab9bf47d2b22acef4a5 (diff) |
test: fee rate values that cannot be represented as sat/vB
Diffstat (limited to 'test/functional/rpc_fundrawtransaction.py')
-rwxr-xr-x | test/functional/rpc_fundrawtransaction.py | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/test/functional/rpc_fundrawtransaction.py b/test/functional/rpc_fundrawtransaction.py index 256f6c610c..0cce5493fc 100755 --- a/test/functional/rpc_fundrawtransaction.py +++ b/test/functional/rpc_fundrawtransaction.py @@ -771,6 +771,10 @@ class RawTransactionsTest(BitcoinTestFramework): # Test fee rate values that don't pass fixed-point parsing checks. for invalid_value in ["", 0.000000001, 1e-09, 1.111111111, 1111111111111111, "31.999999999999999999999"]: assert_raises_rpc_error(-3, "Invalid amount", node.fundrawtransaction, rawtx, {param: invalid_value, "add_inputs": True}) + # Test fee_rate values that cannot be represented in sat/vB. + for invalid_value in [0.0001, 0.00000001, 0.00099999, 31.99999999, "0.0001", "0.00000001", "0.00099999", "31.99999999"]: + assert_raises_rpc_error(-3, "Invalid amount", + node.fundrawtransaction, rawtx, {"fee_rate": invalid_value, "add_inputs": True}) self.log.info("Test min fee rate checks are bypassed with fundrawtxn, e.g. a fee_rate under 1 sat/vB is allowed") node.fundrawtransaction(rawtx, {"fee_rate": 0.999, "add_inputs": True}) |