From 263eae853afaa27b1f611df25b762f00c6eff181 Mon Sep 17 00:00:00 2001 From: meherett Date: Mon, 10 Jun 2024 08:48:43 +0300 Subject: [PATCH] Fix: mining_getblocktemplate_longpoll.py & mining_prioritisetransaction.py test --- test/functional/mining_getblocktemplate_longpoll.py | 3 ++- test/functional/mining_prioritisetransaction.py | 3 ++- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/test/functional/mining_getblocktemplate_longpoll.py b/test/functional/mining_getblocktemplate_longpoll.py index ec49b89d6d..966725816a 100755 --- a/test/functional/mining_getblocktemplate_longpoll.py +++ b/test/functional/mining_getblocktemplate_longpoll.py @@ -6,6 +6,7 @@ import random import threading +from decimal import Decimal from test_framework.test_framework import BitcoinTestFramework from test_framework.util import get_rpc_proxy @@ -68,7 +69,7 @@ def run_test(self): with self.nodes[0].assert_debug_log(["ThreadRPCServer method=getblocktemplate"], timeout=3): thr.start() # generate a transaction and submit it - self.miniwallet.send_self_transfer(from_node=random.choice(self.nodes)) + self.miniwallet.send_self_transfer(from_node=random.choice(self.nodes), fee_rate=Decimal("0.004")) # after one minute, every 10 seconds the mempool is probed, so in 80 seconds it should have returned thr.join(60 + 20) assert not thr.is_alive() diff --git a/test/functional/mining_prioritisetransaction.py b/test/functional/mining_prioritisetransaction.py index b5ef70cb01..258d4bcc70 100755 --- a/test/functional/mining_prioritisetransaction.py +++ b/test/functional/mining_prioritisetransaction.py @@ -39,7 +39,7 @@ def clear_prioritisation(self, node): def test_replacement(self): self.log.info("Test tx prioritisation stays after a tx is replaced") conflicting_input = self.wallet.get_utxo() - tx_replacee = self.wallet.create_self_transfer(utxo_to_spend=conflicting_input, fee_rate=Decimal("0.0001")) + tx_replacee = self.wallet.create_self_transfer(utxo_to_spend=conflicting_input, fee_rate=Decimal("0.004")) tx_replacement = self.wallet.create_self_transfer(utxo_to_spend=conflicting_input, fee_rate=Decimal("0.005")) # Add 1 satoshi fee delta to replacee self.nodes[0].prioritisetransaction(tx_replacee["txid"], 0, 100) @@ -79,6 +79,7 @@ def test_diamond(self): tx_o_b, tx_o_c = [self.wallet.send_self_transfer( from_node=self.nodes[0], utxo_to_spend=u, + fee_rate=Decimal("0.004") ) for u in tx_o_a["new_utxos"]] txid_b = tx_o_b["txid"] txid_c = tx_o_c["txid"]