File tree Expand file tree Collapse file tree 1 file changed +3
-1
lines changed Expand file tree Collapse file tree 1 file changed +3
-1
lines changed Original file line number Diff line number Diff line change 50
50
51
51
52
52
TIME_RANGE_STEP = 600 # ten-minute steps
53
+ TIME_RANGE_MTP = TIME_GENESIS_BLOCK + 194 * TIME_RANGE_STEP
53
54
TIME_RANGE_END = TIME_GENESIS_BLOCK + 200 * TIME_RANGE_STEP
54
55
55
56
@@ -103,6 +104,7 @@ def _test_getblockchaininfo(self):
103
104
res = self .nodes [0 ].getblockchaininfo ()
104
105
105
106
assert_equal (res ['time' ], TIME_RANGE_END - TIME_RANGE_STEP )
107
+ assert_equal (res ['mediantime' ], TIME_RANGE_MTP )
106
108
107
109
# result should have these additional pruning keys if manual pruning is enabled
108
110
assert_equal (sorted (res .keys ()), sorted (['pruneheight' , 'automatic_pruning' ] + keys ))
@@ -310,7 +312,7 @@ def _test_getblockheader(self):
310
312
assert_is_hash_string (header ['merkleroot' ])
311
313
assert_is_hash_string (header ['bits' ], length = None )
312
314
assert isinstance (header ['time' ], int )
313
- assert isinstance (header ['mediantime' ], int )
315
+ assert_equal (header ['mediantime' ], TIME_RANGE_MTP )
314
316
assert isinstance (header ['nonce' ], int )
315
317
assert isinstance (header ['version' ], int )
316
318
assert isinstance (int (header ['versionHex' ], 16 ), int )
You can’t perform that action at this time.
0 commit comments