aboutsummaryrefslogtreecommitdiff
path: root/test/functional
diff options
context:
space:
mode:
authorfanquake <fanquake@gmail.com>2021-09-02 17:26:35 +0800
committerfanquake <fanquake@gmail.com>2021-09-02 17:26:53 +0800
commitb997dd211ecfe5d0d6f757b8426ad81e40219143 (patch)
tree98d0fbafff692b7cfc1dbc2e2dcf8bf6b80dd9c3 /test/functional
parent245462b66ce35dfc5b191d245b3b18b7d035dc92 (diff)
parentfa2e9de59f189fe37c3eeb63d79e09983e40a993 (diff)
Merge bitcoin/bitcoin#22809: test: Check that non-signaling BIP125 tx can be replaced via parent
fa2e9de59f189fe37c3eeb63d79e09983e40a993 test: Check that non-signaling BIP125 tx can be replaced via parent (MarcoFalke) Pull request description: While `optout_child_tx` in the `test_no_inherited_signaling` test is reported as "bip125-replaceable", it is not *directly* replaceable. For example by bumping the fee of `optout_child_tx`. However, it is still replaceable *indirectly* via it's BIP-125 signalling parent. Clarify this by extending the test. ACKs for top commit: mjdietzx: Tested ACK fa2e9de59f189fe37c3eeb63d79e09983e40a993 josibake: ACK https://github.com/bitcoin/bitcoin/commit/fa2e9de59f189fe37c3eeb63d79e09983e40a993 Tree-SHA512: b3608beae743dcb6152df4d2cfe1c0af6b4404ba3837f73e1d1431bd7c637f0c7fab0379aaab2218d5cd63e71070a079c0595ec031056058e8d3c933c2bae0a9
Diffstat (limited to 'test/functional')
-rwxr-xr-xtest/functional/feature_rbf.py11
1 files changed, 11 insertions, 0 deletions
diff --git a/test/functional/feature_rbf.py b/test/functional/feature_rbf.py
index 694cca15fd..cb7556feb4 100755
--- a/test/functional/feature_rbf.py
+++ b/test/functional/feature_rbf.py
@@ -618,6 +618,17 @@ class ReplaceByFeeTest(BitcoinTestFramework):
assert_equal(True, self.nodes[0].getmempoolentry(optin_parent_tx['txid'])['bip125-replaceable'])
assert_raises_rpc_error(-26, 'txn-mempool-conflict', self.nodes[0].sendrawtransaction, replacement_child_tx["hex"], 0)
+ self.log.info('Check that the child tx can still be replaced (via a tx that also replaces the parent)')
+ replacement_parent_tx = self.wallet.send_self_transfer(
+ from_node=self.nodes[0],
+ utxo_to_spend=confirmed_utxo,
+ sequence=0xffffffff,
+ fee_rate=Decimal('0.03'),
+ )
+ # Check that child is removed and update wallet utxo state
+ assert_raises_rpc_error(-5, 'Transaction not in mempool', self.nodes[0].getmempoolentry, optout_child_tx['txid'])
+ self.wallet.get_utxo(txid=optout_child_tx['txid'])
+
def test_replacement_relay_fee(self):
tx = self.wallet.send_self_transfer(from_node=self.nodes[0])['tx']