@@ -33,28 +33,28 @@ def set_test_params(self):
33
33
34
34
def run_test (self ):
35
35
self .log .info ("Warning: this test will take about 70 seconds in the best case. Be patient." )
36
+ self .log .info ("Test that longpollid doesn't change between successive getblocktemplate() invocations if nothing else happens" )
36
37
self .nodes [0 ].generate (10 )
37
38
template = self .nodes [0 ].getblocktemplate ({'rules' : ['segwit' ]})
38
39
longpollid = template ['longpollid' ]
39
- # longpollid should not change between successive invocations if nothing else happens
40
40
template2 = self .nodes [0 ].getblocktemplate ({'rules' : ['segwit' ]})
41
41
assert template2 ['longpollid' ] == longpollid
42
42
43
- # Test 1: test that the longpolling wait if we do nothing
43
+ self . log . info ( " Test that longpoll waits if we do nothing" )
44
44
thr = LongpollThread (self .nodes [0 ])
45
45
thr .start ()
46
46
# check that thread still lives
47
47
thr .join (5 ) # wait 5 seconds or until thread exits
48
48
assert thr .is_alive ()
49
49
50
50
miniwallets = [ MiniWallet (node ) for node in self .nodes ]
51
- # Test 2: test that longpoll will terminate if another node generates a block
51
+ self . log . info ( " Test that longpoll will terminate if another node generates a block" )
52
52
miniwallets [1 ].generate (1 ) # generate a block on another node
53
53
# check that thread will exit now that new transaction entered mempool
54
54
thr .join (5 ) # wait 5 seconds or until thread exits
55
55
assert not thr .is_alive ()
56
56
57
- # Test 3: test that longpoll will terminate if we generate a block ourselves
57
+ self . log . info ( " Test that longpoll will terminate if we generate a block ourselves" )
58
58
thr = LongpollThread (self .nodes [0 ])
59
59
thr .start ()
60
60
miniwallets [0 ].generate (1 ) # generate a block on own node
@@ -65,7 +65,7 @@ def run_test(self):
65
65
self .nodes [0 ].generate (100 )
66
66
self .sync_blocks ()
67
67
68
- # Test 4: test that introducing a new transaction into the mempool will terminate the longpoll
68
+ self . log . info ( " Test that introducing a new transaction into the mempool will terminate the longpoll" )
69
69
thr = LongpollThread (self .nodes [0 ])
70
70
thr .start ()
71
71
# generate a random transaction and submit it
0 commit comments