Skip to content

Commit 9f54e9a

Browse files
author
MarcoFalke
committed
Merge #16493: test: Fix test failures
fa36aa4 Test: Set -acceptnonstdtxn in feature_fee_estimation (MarcoFalke) fa1bb53 test: Add -acceptnonstdtxn to self.extra_args[3] (MarcoFalke) fa8a823 test: Bump rpc_timeout in feature_dbcrash (MarcoFalke) Pull request description: in feature_dbcrash: * Fixes #16488 * Fixes #16498 in feature_fee_estimation: * Fixes #16518 ACKs for top commit: fanquake: ACK fa36aa4 Tree-SHA512: 9e79a6f954998b196e2a7452f72d2ecf7a6b7f61be610033038e2e40f2feba53e0ee242c7e3cdd94051811e8c96f8ab8031141710da29137fc3acea07cb2dc73
2 parents e653eef + fa36aa4 commit 9f54e9a

File tree

2 files changed

+24
-8
lines changed

2 files changed

+24
-8
lines changed

test/functional/feature_dbcrash.py

Lines changed: 16 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -30,17 +30,27 @@
3030
import random
3131
import time
3232

33-
from test_framework.messages import COIN, COutPoint, CTransaction, CTxIn, CTxOut, ToHex
33+
from test_framework.messages import (
34+
COIN,
35+
COutPoint,
36+
CTransaction,
37+
CTxIn,
38+
CTxOut,
39+
ToHex,
40+
)
3441
from test_framework.test_framework import BitcoinTestFramework
35-
from test_framework.util import assert_equal, create_confirmed_utxos, hex_str_to_bytes
42+
from test_framework.util import (
43+
assert_equal,
44+
create_confirmed_utxos,
45+
hex_str_to_bytes,
46+
)
3647

3748

3849
class ChainstateWriteCrashTest(BitcoinTestFramework):
3950
def set_test_params(self):
4051
self.num_nodes = 4
4152
self.setup_clean_chain = False
42-
# Need a bit of extra time for the nodes to start up for this test
43-
self.rpc_timeout = 90
53+
self.rpc_timeout = 180
4454

4555
# Set -maxmempool=0 to turn off mempool memory sharing with dbcache
4656
# Set -rpcservertimeout=900 to reduce socket disconnects in this
@@ -54,7 +64,8 @@ def set_test_params(self):
5464
self.node2_args = ["-dbcrashratio=24", "-dbcache=16"] + self.base_args
5565

5666
# Node3 is a normal node with default args, except will mine full blocks
57-
self.node3_args = ["-blockmaxweight=4000000"]
67+
# and non-standard txs (e.g. txs with "dust" outputs)
68+
self.node3_args = ["-blockmaxweight=4000000", "-acceptnonstdtxn"]
5869
self.extra_args = [self.node0_args, self.node1_args, self.node2_args, self.node3_args]
5970

6071
def skip_test_if_missing_module(self):

test/functional/feature_fee_estimation.py

Lines changed: 8 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -120,9 +120,16 @@ def check_estimates(node, fees_seen):
120120
else:
121121
assert_greater_than_or_equal(i + 1, e["blocks"])
122122

123+
123124
class EstimateFeeTest(BitcoinTestFramework):
124125
def set_test_params(self):
125126
self.num_nodes = 3
127+
# mine non-standard txs (e.g. txs with "dust" outputs)
128+
self.extra_args = [
129+
["-acceptnonstdtxn", "-maxorphantx=1000", "-whitelist=127.0.0.1"],
130+
["-acceptnonstdtxn", "-blockmaxweight=68000", "-maxorphantx=1000"],
131+
["-acceptnonstdtxn", "-blockmaxweight=32000", "-maxorphantx=1000"],
132+
]
126133

127134
def skip_test_if_missing_module(self):
128135
self.skip_if_no_wallet()
@@ -133,9 +140,7 @@ def setup_network(self):
133140
But first we need to use one node to create a lot of outputs
134141
which we will use to generate our transactions.
135142
"""
136-
self.add_nodes(3, extra_args=[["-maxorphantx=1000", "-whitelist=127.0.0.1"],
137-
["-blockmaxweight=68000", "-maxorphantx=1000"],
138-
["-blockmaxweight=32000", "-maxorphantx=1000"]])
143+
self.add_nodes(3, extra_args=self.extra_args)
139144
# Use node0 to mine blocks for input splitting
140145
# Node1 mines small blocks but that are bigger than the expected transaction rate.
141146
# NOTE: the CreateNewBlock code starts counting block weight at 4,000 weight,

0 commit comments

Comments
 (0)