Skip to content
Bitcoin Roots

v30.3-roots.1 · Commit 8: [PATCH 08/68] ci: restore Roots assurance on Core 30.3 interfaces

test/functional/p2p_opportunistic_1p1c.py

Before: test/functional/p2p_opportunistic_1p1c.py · After: test/functional/p2p_opportunistic_1p1c.py

File metadata
index ef4440b9ecb6013766971ca9973c46d898d0944b..cc124fa3bb50ba6db043b55158132d978e6280dd 100755

Download original patch · Release notes

Diff rows 1–32 of 32. Line numbers refer to the original before/after files.

+ Added− RemovedUnmarked lines are context.

Scroll the code area horizontally to read long lines. The two line-number columns refer to before and after.

test/functional/p2p_opportunistic_1p1c.py CHANGED
@@ -13,7 +13,6 @@ import time
13
13
  from test_framework.blocktools import MAX_STANDARD_TX_WEIGHT
14
14
  from test_framework.mempool_util import (
15
15
  create_large_orphan,
16
- DEFAULT_MIN_RELAY_TX_FEE,
17
16
  fill_mempool,
18
17
  )
19
18
  from test_framework.messages import (
@@ -77,17 +76,22 @@ class PackageRelayTest(BitcoinTestFramework):
77
76
  self.setup_clean_chain = True
78
77
  self.num_nodes = 1
79
78
  self.extra_args = [[
79
+ "-permitbaredatacarrier=1", # Native large orphan fixtures have only an OP_RETURN output.
80
+ "-datacarriersize=100000",
81
+ "-maxscriptsize=100000", # Permit synthetic mempool-filling data carriers.
80
82
  "-maxmempool=5",
83
+ "-permitbarepubkey=1", # Exercise the legacy txid == wtxid relay path.
81
84
  ]]
82
85
 
83
86
  def create_tx_below_mempoolminfee(self, wallet, utxo_to_spend=None):
84
- """Create a 1-input 0.1sat/vB transaction using a confirmed UTXO. Decrement and use
87
+ """Create a 1-input transaction at the node relay fee using a confirmed UTXO. Decrement and use
85
88
  self.sequence so that subsequent calls to this function result in unique transactions."""
86
89
 
87
90
  self.sequence -= 1
88
- assert_greater_than(self.nodes[0].getmempoolinfo()["mempoolminfee"], Decimal(DEFAULT_MIN_RELAY_TX_FEE) / COIN)
91
+ min_relay_fee = self.nodes[0].getnetworkinfo()["relayfee"]
92
+ assert_greater_than(self.nodes[0].getmempoolinfo()["mempoolminfee"], min_relay_fee)
89
93
 
90
- return wallet.create_self_transfer(fee_rate=Decimal(DEFAULT_MIN_RELAY_TX_FEE) / COIN, sequence=self.sequence, utxo_to_spend=utxo_to_spend, confirmed_only=True)
94
+ return wallet.create_self_transfer(fee_rate=min_relay_fee, sequence=self.sequence, utxo_to_spend=utxo_to_spend, confirmed_only=True)
91
95
 
92
96
  @cleanup
93
97
  def test_basic_child_then_parent(self):