diff options
Diffstat (limited to 'tests/block_test_util.go')
-rw-r--r-- | tests/block_test_util.go | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/tests/block_test_util.go b/tests/block_test_util.go index d47c2b101..2090afce7 100644 --- a/tests/block_test_util.go +++ b/tests/block_test_util.go @@ -365,8 +365,8 @@ func (s *BlockTest) validateBlockHeader(h *btHeader, h2 *types.Header) error { return fmt.Errorf("GasUsed: expected: %v, decoded: %v", expectedGasUsed, h2.GasUsed) } - expectedTimestamp := mustConvertUint(h.Timestamp, 16) - if expectedTimestamp != h2.Time { + expectedTimestamp := mustConvertBigInt(h.Timestamp, 16) + if expectedTimestamp.Cmp(h2.Time) != 0 { return fmt.Errorf("Timestamp: expected: %v, decoded: %v", expectedTimestamp, h2.Time) } @@ -461,7 +461,7 @@ func mustConvertHeader(in btHeader) *types.Header { GasUsed: mustConvertBigInt(in.GasUsed, 16), GasLimit: mustConvertBigInt(in.GasLimit, 16), Difficulty: mustConvertBigInt(in.Difficulty, 16), - Time: mustConvertUint(in.Timestamp, 16), + Time: mustConvertBigInt(in.Timestamp, 16), Nonce: types.EncodeNonce(mustConvertUint(in.Nonce, 16)), } return header |