mirror of
https://github.com/bitcoin/bitcoin.git
synced 2025-01-10 11:57:28 -03:00
Merge #19893: test: Remove or explain syncwithvalidationinterfacequeue
fa6af31227
test: Document why syncwithvalidationinterfacequeue is needed in tests (MarcoFalke)fa135a13b8
Revert "test: Add missing sync_all to wallet_balance test" (MarcoFalke) Pull request description: syncwithvalidationinterfacequeue is a hidden test-only RPC, so it should not be used when it is not needed. Thus, either remove it or explain why it is needed. ACKs for top commit: fjahr: Code review ACKfa6af31227
Tree-SHA512: de30db4ab521184091ee5beeab02989138cf7cf05088f766a2fb106151b239310b63d5380cb79e2a072f72c5ae9513aecae8eb9c1c7be713771585c3cb04d63a
This commit is contained in:
commit
64156ad4d1
3 changed files with 2 additions and 3 deletions
|
@ -263,8 +263,6 @@ class WalletTest(BitcoinTestFramework):
|
|||
self.log.info('Put txs back into mempool of node 1 (not node 0)')
|
||||
self.nodes[0].invalidateblock(block_reorg)
|
||||
self.nodes[1].invalidateblock(block_reorg)
|
||||
self.sync_blocks()
|
||||
self.nodes[0].syncwithvalidationinterfacequeue()
|
||||
assert_equal(self.nodes[0].getbalance(minconf=0), 0) # wallet txs not in the mempool are untrusted
|
||||
self.nodes[0].generatetoaddress(1, ADDRESS_WATCHONLY)
|
||||
assert_equal(self.nodes[0].getbalance(minconf=0), 0) # wallet txs not in the mempool are untrusted
|
||||
|
|
|
@ -64,7 +64,7 @@ class ImportMultiTest(BitcoinTestFramework):
|
|||
self.nodes[0].generate(1)
|
||||
self.nodes[1].generate(1)
|
||||
timestamp = self.nodes[1].getblock(self.nodes[1].getbestblockhash())['mediantime']
|
||||
self.nodes[1].syncwithvalidationinterfacequeue()
|
||||
self.nodes[1].syncwithvalidationinterfacequeue() # Sync the timestamp to the wallet, so that importmulti works
|
||||
|
||||
node0_address1 = self.nodes[0].getaddressinfo(self.nodes[0].getnewaddress())
|
||||
|
||||
|
|
|
@ -50,6 +50,7 @@ class ResendWalletTransactionsTest(BitcoinTestFramework):
|
|||
block.solve()
|
||||
node.submitblock(ToHex(block))
|
||||
|
||||
# Set correct m_best_block_time, which is used in ResendWalletTransactions
|
||||
node.syncwithvalidationinterfacequeue()
|
||||
now = int(time.time())
|
||||
|
||||
|
|
Loading…
Reference in a new issue