aboutsummaryrefslogtreecommitdiff
path: root/test/functional/test_framework/util.py
diff options
context:
space:
mode:
authorSebastian Falbesoner <sebastian.falbesoner@gmail.com>2022-07-10 13:09:51 +0200
committerSebastian Falbesoner <sebastian.falbesoner@gmail.com>2022-07-10 13:09:51 +0200
commit6cbe65c5d7fb23e922e5e0451a6907abb69c7cde (patch)
tree29427c33ac36b3ab2ff44dd889e3ca3cb14afb1c /test/functional/test_framework/util.py
parent194710d8ff398838e4e5bb87b56e19ebed1d6c52 (diff)
test: refactor: pass absolute fee in `create_lots_of_big_transactions` helper
Diffstat (limited to 'test/functional/test_framework/util.py')
-rw-r--r--test/functional/test_framework/util.py5
1 files changed, 1 insertions, 4 deletions
diff --git a/test/functional/test_framework/util.py b/test/functional/test_framework/util.py
index 1ee23f7574..58528b7858 100644
--- a/test/functional/test_framework/util.py
+++ b/test/functional/test_framework/util.py
@@ -512,16 +512,13 @@ def gen_return_txouts():
# Create a spend of each passed-in utxo, splicing in "txouts" to each raw
# transaction to make it large. See gen_return_txouts() above.
def create_lots_of_big_transactions(mini_wallet, node, fee, tx_batch_size, txouts, utxos=None):
- from .messages import COIN
- fee_sats = int(fee * COIN)
txids = []
use_internal_utxos = utxos is None
for _ in range(tx_batch_size):
tx = mini_wallet.create_self_transfer(
utxo_to_spend=None if use_internal_utxos else utxos.pop(),
- fee_rate=0,
+ fee=fee,
)["tx"]
- tx.vout[0].nValue -= fee_sats
tx.vout.extend(txouts)
res = node.testmempoolaccept([tx.serialize().hex()])[0]
assert_equal(res['fees']['base'], fee)