@@ -91,7 +91,7 @@ pub static TEST_MINE_ALLOWED_REPLAY_TXS: LazyLock<TestFlag<Vec<String>>> =
91
91
/// Given a tx id, check if it is should be skipped
92
92
/// if not listed in `TEST_MINE_ALLOWED_REPLAY_TXS` flag.
93
93
/// If flag is empty means no tx should be skipped
94
- fn should_skip_replay_tx ( tx_id : Txid ) -> bool {
94
+ fn fault_injection_should_skip_replay_tx ( tx_id : Txid ) -> bool {
95
95
let minable_txs = TEST_MINE_ALLOWED_REPLAY_TXS . get ( ) ;
96
96
let allowed =
97
97
minable_txs. len ( ) == 0 || minable_txs. iter ( ) . any ( |tx_ids| * tx_ids == tx_id. to_hex ( ) ) ;
@@ -104,6 +104,14 @@ fn should_skip_replay_tx(tx_id: Txid) -> bool {
104
104
!allowed
105
105
}
106
106
107
+ #[ cfg( not( any( test, feature = "testing" ) ) ) ]
108
+ /// Given a tx id, check if it is should be skipped
109
+ /// if not listed in `TEST_MINE_ALLOWED_REPLAY_TXS` flag.
110
+ /// If flag is empty means no tx should be skipped
111
+ fn fault_injection_should_skip_replay_tx ( _tx_id : Txid ) -> bool {
112
+ false
113
+ }
114
+
107
115
/// Fully-assembled Stacks anchored, block as well as some extra metadata pertaining to how it was
108
116
/// linked to the burnchain and what view(s) the miner had of the burnchain before and after
109
117
/// completing the block.
@@ -3014,11 +3022,8 @@ fn select_and_apply_transactions_from_vec<B: BlockBuilder>(
3014
3022
debug ! ( "Replay block transaction selection begins (parent height = {tip_height})" ) ;
3015
3023
for replay_tx in replay_transactions {
3016
3024
fault_injection_stall_tx ( ) ;
3017
- #[ cfg( any( test, feature = "testing" ) ) ]
3018
- {
3019
- if should_skip_replay_tx ( replay_tx. txid ( ) ) {
3020
- continue ;
3021
- }
3025
+ if fault_injection_should_skip_replay_tx ( replay_tx. txid ( ) ) {
3026
+ continue ;
3022
3027
}
3023
3028
3024
3029
let txid = replay_tx. txid ( ) ;
0 commit comments