aboutsummaryrefslogtreecommitdiffstats
path: root/dex/peer_test.go
diff options
context:
space:
mode:
authorSonic <sonic@cobinhood.com>2018-10-14 22:39:11 +0800
committerWei-Ning Huang <w@dexon.org>2018-12-19 20:54:27 +0800
commitbc4075d5c095ea29f576f546fdeb245a0e00d4ea (patch)
tree4b36b7433d9730638e5ebf2acf22f48650de11e0 /dex/peer_test.go
parent95379029f2e3eb0ffd2c1a6c151100062cb5d5cc (diff)
downloaddexon-bc4075d5c095ea29f576f546fdeb245a0e00d4ea.tar
dexon-bc4075d5c095ea29f576f546fdeb245a0e00d4ea.tar.gz
dexon-bc4075d5c095ea29f576f546fdeb245a0e00d4ea.tar.bz2
dexon-bc4075d5c095ea29f576f546fdeb245a0e00d4ea.tar.lz
dexon-bc4075d5c095ea29f576f546fdeb245a0e00d4ea.tar.xz
dexon-bc4075d5c095ea29f576f546fdeb245a0e00d4ea.tar.zst
dexon-bc4075d5c095ea29f576f546fdeb245a0e00d4ea.zip
dex: add method to get NumChains, NotarySet, DKGSet easily
Diffstat (limited to 'dex/peer_test.go')
-rw-r--r--dex/peer_test.go6
1 files changed, 3 insertions, 3 deletions
diff --git a/dex/peer_test.go b/dex/peer_test.go
index 6e539e078..d0262e201 100644
--- a/dex/peer_test.go
+++ b/dex/peer_test.go
@@ -16,7 +16,7 @@ func TestPeerSetBuildAndForgetNotaryConn(t *testing.T) {
table := newNodeTable()
gov := &testGovernance{
- getChainNumFunc: func(uint64) uint32 {
+ numChainsFunc: func(uint64) uint32 {
return 3
},
}
@@ -37,7 +37,7 @@ func TestPeerSetBuildAndForgetNotaryConn(t *testing.T) {
[]enode.ID{nodeID(0), nodeID(2), nodeID(6)},
}
- gov.getNotarySetFunc = func(cid uint32, round uint64) map[string]struct{} {
+ gov.notarySetFunc = func(cid uint32, round uint64) map[string]struct{} {
m := map[uint64][][]enode.ID{
10: round10,
11: round11,
@@ -317,7 +317,7 @@ func TestPeerSetBuildDKGConn(t *testing.T) {
gov := &testGovernance{}
- gov.getDKGSetFunc = func(round uint64) map[string]struct{} {
+ gov.dkgSetFunc = func(round uint64) map[string]struct{} {
m := map[uint64][]enode.ID{
10: []enode.ID{nodeID(0), nodeID(1), nodeID(2)},
11: []enode.ID{nodeID(1), nodeID(2), nodeID(5)},