Skip to content

Commit

Permalink
fix a couple linter issues
Browse files Browse the repository at this point in the history
  • Loading branch information
gballet committed Feb 2, 2022
1 parent f89d0bc commit c94b925
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions core/state_processor_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -383,7 +383,7 @@ func TestProcessStateless(t *testing.T) {
defer blockchain.Stop()
txCost1 := params.WitnessBranchWriteCost*2 + params.WitnessBranchReadCost*2 + params.WitnessChunkWriteCost*3 + params.WitnessChunkReadCost*12 + params.TxGas
txCost2 := params.WitnessBranchWriteCost + params.WitnessBranchReadCost*2 + params.WitnessChunkWriteCost*2 + params.WitnessChunkReadCost*10 + params.TxGas
blockGasUsedExpected := txCost1 * 2 + txCost2
blockGasUsedExpected := txCost1*2 + txCost2
chain, _ := GenerateVerkleChain(gspec.Config, genesis, ethash.NewFaker(), db, 2, func(i int, gen *BlockGen) {
// TODO need to check that the tx cost provided is the exact amount used (no remaining left-over)
tx, _ := types.SignTx(types.NewTransaction(uint64(i)*3, common.Address{1, 2, 3}, big.NewInt(999), txCost1, big.NewInt(875000000), nil), signer, testKey)
Expand All @@ -409,7 +409,7 @@ func TestProcessStateless(t *testing.T) {
for i := 0; i < 2; i++ {
b := blockchain.GetBlockByNumber(uint64(i) + 1)
if b == nil {
t.Fatalf("expected block %d to be present in chain", i + 1)
t.Fatalf("expected block %d to be present in chain", i+1)
}
if b.GasUsed() != blockGasUsedExpected {
t.Fatalf("expected block txs to use %d, got %d\n", blockGasUsedExpected, b.GasUsed())
Expand Down

0 comments on commit c94b925

Please sign in to comment.