fix linter issues

This commit is contained in:
Ian Norden 2019-12-09 15:07:40 -06:00
parent 2395e70a61
commit 6e05b78bd0
3 changed files with 10 additions and 4 deletions

View File

@ -2408,6 +2408,9 @@ func TestProcessingStateDiffs(t *testing.T) {
moreBlocks := makeBlockChain(blocks[len(blocks)-1], 1, engine, db, canonicalSeed)
_, err = blockchain.InsertChain(moreBlocks)
if err != nil {
t.Error(err)
}
//a root hash can be dereferenced when it's state diff and it's child's state diff have been processed
//(i.e. it has a count of 2 in stateDiffsProcessed)

View File

@ -166,6 +166,9 @@ func testHTTPAPI(t *testing.T) {
streamBlock: true,
}
payload, err := mockService.StateDiffAt(block1.Number().Uint64())
if err != nil {
t.Error(err)
}
expectedBlockRlp, _ := rlp.EncodeToBytes(block1)
if !bytes.Equal(payload.BlockRlp, expectedBlockRlp) {
t.Errorf("payload does not have expected block\r\actual block rlp: %v\r\nexpected block rlp: %v", payload.BlockRlp, expectedBlockRlp)