aboutsummaryrefslogtreecommitdiffstats
path: root/core/compaction-chain_test.go
diff options
context:
space:
mode:
authorMission Liao <mission.liao@dexon.org>2018-10-24 17:50:09 +0800
committerGitHub <noreply@github.com>2018-10-24 17:50:09 +0800
commitdbee0586b0a565ae9a31a3c2d967f5c2af76f60d (patch)
treecdfaef7754aedfda8d02c7023364a645e391e59e /core/compaction-chain_test.go
parentf90c15fcfa575e138355a449c49cd784ba54db17 (diff)
downloaddexon-consensus-dbee0586b0a565ae9a31a3c2d967f5c2af76f60d.tar
dexon-consensus-dbee0586b0a565ae9a31a3c2d967f5c2af76f60d.tar.gz
dexon-consensus-dbee0586b0a565ae9a31a3c2d967f5c2af76f60d.tar.bz2
dexon-consensus-dbee0586b0a565ae9a31a3c2d967f5c2af76f60d.tar.lz
dexon-consensus-dbee0586b0a565ae9a31a3c2d967f5c2af76f60d.tar.xz
dexon-consensus-dbee0586b0a565ae9a31a3c2d967f5c2af76f60d.tar.zst
dexon-consensus-dbee0586b0a565ae9a31a3c2d967f5c2af76f60d.zip
test: add test.State (#239)
* separate test utility and interface implementation for test.Governance. * add test.State. * integrate test.State to test.Governance. test.State is mainly used to emulate state propagation on fullnode.
Diffstat (limited to 'core/compaction-chain_test.go')
-rw-r--r--core/compaction-chain_test.go4
1 files changed, 3 insertions, 1 deletions
diff --git a/core/compaction-chain_test.go b/core/compaction-chain_test.go
index e73482f..f4860fb 100644
--- a/core/compaction-chain_test.go
+++ b/core/compaction-chain_test.go
@@ -36,7 +36,9 @@ func (s *CompactionChainTestSuite) SetupTest() {
}
func (s *CompactionChainTestSuite) newCompactionChain() *compactionChain {
- gov, err := test.NewGovernance(4, 100*time.Millisecond)
+ _, pubKeys, err := test.NewKeys(4)
+ s.Require().NoError(err)
+ gov, err := test.NewGovernance(pubKeys, 100*time.Millisecond)
s.Require().NoError(err)
cc := newCompactionChain(gov)
cc.init(&types.Block{})