diff options
author | Péter Szilágyi <peterke@gmail.com> | 2019-04-08 21:16:05 +0800 |
---|---|---|
committer | GitHub <noreply@github.com> | 2019-04-08 21:16:05 +0800 |
commit | 4e13a09c5033b4cf073db6aeaaa7d159dcf07f30 (patch) | |
tree | 0f64daac335200ce6fd45d6ee9f62dabc0fb1887 /tests/block_test_util.go | |
parent | c942700427557e3ff6de3aaf6b916e2f056c1ec2 (diff) | |
parent | 009d2fe2d650b1a92e28f0decbf5f7fa628779e9 (diff) | |
download | go-tangerine-1.8.24.tar go-tangerine-1.8.24.tar.gz go-tangerine-1.8.24.tar.bz2 go-tangerine-1.8.24.tar.lz go-tangerine-1.8.24.tar.xz go-tangerine-1.8.24.tar.zst go-tangerine-1.8.24.zip |
Merge pull request #19370 from karalabe/geth-1.8.24v1.8.24
Backport PR for the v1.8.24 maintenance release
Diffstat (limited to 'tests/block_test_util.go')
-rw-r--r-- | tests/block_test_util.go | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/tests/block_test_util.go b/tests/block_test_util.go index 9fa69bf4e..3a1644497 100644 --- a/tests/block_test_util.go +++ b/tests/block_test_util.go @@ -82,7 +82,7 @@ type btHeader struct { Difficulty *big.Int GasLimit uint64 GasUsed uint64 - Timestamp *big.Int + Timestamp uint64 } type btHeaderMarshaling struct { @@ -91,7 +91,7 @@ type btHeaderMarshaling struct { Difficulty *math.HexOrDecimal256 GasLimit math.HexOrDecimal64 GasUsed math.HexOrDecimal64 - Timestamp *math.HexOrDecimal256 + Timestamp math.HexOrDecimal64 } func (t *BlockTest) Run() error { @@ -146,7 +146,7 @@ func (t *BlockTest) genesis(config *params.ChainConfig) *core.Genesis { return &core.Genesis{ Config: config, Nonce: t.json.Genesis.Nonce.Uint64(), - Timestamp: t.json.Genesis.Timestamp.Uint64(), + Timestamp: t.json.Genesis.Timestamp, ParentHash: t.json.Genesis.ParentHash, ExtraData: t.json.Genesis.ExtraData, GasLimit: t.json.Genesis.GasLimit, @@ -248,7 +248,7 @@ func validateHeader(h *btHeader, h2 *types.Header) error { if h.GasUsed != h2.GasUsed { return fmt.Errorf("GasUsed: want: %d have: %d", h.GasUsed, h2.GasUsed) } - if h.Timestamp.Cmp(h2.Time) != 0 { + if h.Timestamp != h2.Time { return fmt.Errorf("Timestamp: want: %v have: %v", h.Timestamp, h2.Time) } return nil |