aboutsummaryrefslogtreecommitdiffstats
path: root/core/genesis_test.go
diff options
context:
space:
mode:
authorPéter Szilágyi <peterke@gmail.com>2017-04-05 06:16:29 +0800
committerFelix Lange <fjl@users.noreply.github.com>2017-04-05 06:16:29 +0800
commit09777952ee476ff80d4b6e63b5041ff5ca0e441b (patch)
treee85320f88f548201e3476b3e7095e96fd071617b /core/genesis_test.go
parente50a5b77712d891ff409aa942a5cbc24e721b332 (diff)
downloaddexon-09777952ee476ff80d4b6e63b5041ff5ca0e441b.tar
dexon-09777952ee476ff80d4b6e63b5041ff5ca0e441b.tar.gz
dexon-09777952ee476ff80d4b6e63b5041ff5ca0e441b.tar.bz2
dexon-09777952ee476ff80d4b6e63b5041ff5ca0e441b.tar.lz
dexon-09777952ee476ff80d4b6e63b5041ff5ca0e441b.tar.xz
dexon-09777952ee476ff80d4b6e63b5041ff5ca0e441b.tar.zst
dexon-09777952ee476ff80d4b6e63b5041ff5ca0e441b.zip
core, consensus: pluggable consensus engines (#3817)
This commit adds pluggable consensus engines to go-ethereum. In short, it introduces a generic consensus interface, and refactors the entire codebase to use this interface.
Diffstat (limited to 'core/genesis_test.go')
-rw-r--r--core/genesis_test.go4
1 files changed, 2 insertions, 2 deletions
diff --git a/core/genesis_test.go b/core/genesis_test.go
index b73dd776f..4312a80b8 100644
--- a/core/genesis_test.go
+++ b/core/genesis_test.go
@@ -23,11 +23,11 @@ import (
"github.com/davecgh/go-spew/spew"
"github.com/ethereum/go-ethereum/common"
+ "github.com/ethereum/go-ethereum/consensus/ethash"
"github.com/ethereum/go-ethereum/core/vm"
"github.com/ethereum/go-ethereum/ethdb"
"github.com/ethereum/go-ethereum/event"
"github.com/ethereum/go-ethereum/params"
- "github.com/ethereum/go-ethereum/pow"
)
func TestDefaultGenesisBlock(t *testing.T) {
@@ -119,7 +119,7 @@ func TestSetupGenesis(t *testing.T) {
// Commit the 'old' genesis block with Homestead transition at #2.
// Advance to block #4, past the homestead transition block of customg.
genesis := oldcustomg.MustCommit(db)
- bc, _ := NewBlockChain(db, oldcustomg.Config, pow.FakePow{}, new(event.TypeMux), vm.Config{})
+ bc, _ := NewBlockChain(db, oldcustomg.Config, ethash.NewFullFaker(), new(event.TypeMux), vm.Config{})
bc.SetValidator(bproc{})
bc.InsertChain(makeBlockChainWithDiff(genesis, []int{2, 3, 4, 5}, 0))
bc.CurrentBlock()