fixed test

This commit is contained in:
zsfelfoldi 2015-11-18 19:14:59 +01:00
parent 4ab4452b9f
commit ab8ae84f08

View file

@ -21,6 +21,7 @@ import (
"time"
"github.com/ethereum/go-ethereum/common"
"github.com/ethereum/go-ethereum/core/access"
"github.com/ethereum/go-ethereum/core/state"
"github.com/ethereum/go-ethereum/core/vm"
"github.com/ethereum/go-ethereum/crypto"
@ -96,7 +97,7 @@ func Execute(code, input []byte, cfg *Config) ([]byte, *state.StateDB, error) {
var (
db, _ = ethdb.NewMemDatabase()
statedb, _ = state.New(common.Hash{}, db)
statedb, _ = state.New(common.Hash{}, access.NewDbChainAccess(db))
vmenv = NewEnv(cfg, statedb)
sender = statedb.CreateAccount(cfg.Origin)
receiver = statedb.CreateAccount(common.StringToAddress("contract"))