From 47f5134d1d45538b95dfc45913a83bab594d3ca5 Mon Sep 17 00:00:00 2001 From: Sonic Date: Sun, 14 Oct 2018 22:39:11 +0800 Subject: dex: add method to get NumChains, NotarySet, DKGSet easily --- dex/peer_test.go | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'dex/peer_test.go') 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)}, -- cgit v1.2.3