2
2
# Copyright (c) 2017-2019 The Bitcoin Core developers
3
3
# Distributed under the MIT software license, see the accompanying
4
4
# file COPYING or http://www.opensource.org/licenses/mit-license.php.
5
- """Test the listsincelast RPC."""
5
+ """Test the listsinceblock RPC."""
6
6
7
7
from test_framework .test_framework import BitcoinTestFramework
8
8
from test_framework .messages import BIP125_SEQUENCE_NUMBER
@@ -38,6 +38,7 @@ def run_test(self):
38
38
self .double_spends_filtered ()
39
39
40
40
def test_no_blockhash (self ):
41
+ self .log .info ("Test no blockhash" )
41
42
txid = self .nodes [2 ].sendtoaddress (self .nodes [0 ].getnewaddress (), 1 )
42
43
blockhash , = self .nodes [2 ].generate (1 )
43
44
blockheight = self .nodes [2 ].getblockheader (blockhash )['height' ]
@@ -63,6 +64,7 @@ def test_no_blockhash(self):
63
64
"transactions" : txs })
64
65
65
66
def test_invalid_blockhash (self ):
67
+ self .log .info ("Test invalid blockhash" )
66
68
assert_raises_rpc_error (- 5 , "Block not found" , self .nodes [0 ].listsinceblock ,
67
69
"42759cde25462784395a337460bde75f58e73d3f08bd31fdc3507cbac856a2c4" )
68
70
assert_raises_rpc_error (- 5 , "Block not found" , self .nodes [0 ].listsinceblock ,
@@ -100,6 +102,7 @@ def test_reorg(self):
100
102
101
103
This test only checks that [tx0] is present.
102
104
'''
105
+ self .log .info ("Test reorg" )
103
106
104
107
# Split network into two
105
108
self .split_network ()
@@ -110,7 +113,7 @@ def test_reorg(self):
110
113
# generate on both sides
111
114
lastblockhash = self .nodes [1 ].generate (6 )[5 ]
112
115
self .nodes [2 ].generate (7 )
113
- self .log .info ('lastblockhash=%s' % (lastblockhash ))
116
+ self .log .debug ('lastblockhash={}' . format (lastblockhash ))
114
117
115
118
self .sync_all (self .nodes [:2 ])
116
119
self .sync_all (self .nodes [2 :])
@@ -155,6 +158,7 @@ def test_double_spend(self):
155
158
until the fork point, and to include all transactions that relate to the
156
159
node wallet.
157
160
'''
161
+ self .log .info ("Test double spend" )
158
162
159
163
self .sync_all ()
160
164
@@ -234,6 +238,7 @@ def test_double_send(self):
234
238
3. It is listed with a confirmation count of 2 (bb3, bb4), not
235
239
3 (aa1, aa2, aa3).
236
240
'''
241
+ self .log .info ("Test double send" )
237
242
238
243
self .sync_all ()
239
244
@@ -302,6 +307,7 @@ def double_spends_filtered(self):
302
307
`listsinceblock` was returning conflicted transactions even if they
303
308
occurred before the specified cutoff blockhash
304
309
'''
310
+ self .log .info ("Test spends filtered" )
305
311
spending_node = self .nodes [2 ]
306
312
dest_address = spending_node .getnewaddress ()
307
313
0 commit comments