File tree Expand file tree Collapse file tree 2 files changed +11
-0
lines changed
Expand file tree Collapse file tree 2 files changed +11
-0
lines changed Original file line number Diff line number Diff line change @@ -30,6 +30,11 @@ def run_test(self):
3030 print "Mining blocks..."
3131
3232 min_relay_tx_fee = self .nodes [0 ].getnetworkinfo ()['relayfee' ]
33+ # This test is not meant to test fee estimation and we'd like
34+ # to be sure all txs are sent at a consistent desired feerate
35+ for node in self .nodes :
36+ node .settxfee (min_relay_tx_fee )
37+
3338 # if the fee's positive delta is higher than this value tests will fail,
3439 # neg. delta always fail the tests.
3540 # The size of the signature of every input may be at most 2 bytes larger
@@ -447,6 +452,10 @@ def run_test(self):
447452 wait_bitcoinds ()
448453
449454 self .nodes = start_nodes (4 , self .options .tmpdir )
455+ # This test is not meant to test fee estimation and we'd like
456+ # to be sure all txs are sent at a consistent desired feerate
457+ for node in self .nodes :
458+ node .settxfee (min_relay_tx_fee )
450459
451460 connect_nodes_bi (self .nodes ,0 ,1 )
452461 connect_nodes_bi (self .nodes ,1 ,2 )
Original file line number Diff line number Diff line change @@ -33,7 +33,9 @@ def run_test(self):
3333 inputs = [{ "txid" : us0 ["txid" ], "vout" : us0 ["vout" ]}]
3434 outputs = {self .nodes [0 ].getnewaddress () : 0.0001 }
3535 tx = self .nodes [0 ].createrawtransaction (inputs , outputs )
36+ self .nodes [0 ].settxfee (self .relayfee ) # specifically fund this tx with low fee
3637 txF = self .nodes [0 ].fundrawtransaction (tx )
38+ self .nodes [0 ].settxfee (0 ) # return to automatic fee selection
3739 txFS = self .nodes [0 ].signrawtransaction (txF ['hex' ])
3840 txid = self .nodes [0 ].sendrawtransaction (txFS ['hex' ])
3941 self .nodes [0 ].lockunspent (True , [us0 ])
You can’t perform that action at this time.
0 commit comments