aboutsummaryrefslogtreecommitdiffstats
path: root/swarm/pss/notify/notify_test.go
diff options
context:
space:
mode:
authorJanos Guljas <janos@resenje.org>2018-09-25 22:57:31 +0800
committerJanos Guljas <janos@resenje.org>2018-09-25 22:57:31 +0800
commit24349144b6c0642755569268bab56b9033743212 (patch)
tree9d9d2b6659fd8a56512dfc807aafe4b733165ae1 /swarm/pss/notify/notify_test.go
parent7d56602391e155e2ce9ba7c261300a1804ab9972 (diff)
parentd3441ebb563439bac0837d70591f92e2c6080303 (diff)
downloaddexon-24349144b6c0642755569268bab56b9033743212.tar
dexon-24349144b6c0642755569268bab56b9033743212.tar.gz
dexon-24349144b6c0642755569268bab56b9033743212.tar.bz2
dexon-24349144b6c0642755569268bab56b9033743212.tar.lz
dexon-24349144b6c0642755569268bab56b9033743212.tar.xz
dexon-24349144b6c0642755569268bab56b9033743212.tar.zst
dexon-24349144b6c0642755569268bab56b9033743212.zip
Merge branch 'master' into max-stream-peer-servers
Diffstat (limited to 'swarm/pss/notify/notify_test.go')
-rw-r--r--swarm/pss/notify/notify_test.go11
1 files changed, 5 insertions, 6 deletions
diff --git a/swarm/pss/notify/notify_test.go b/swarm/pss/notify/notify_test.go
index 3c655f215..675b41ada 100644
--- a/swarm/pss/notify/notify_test.go
+++ b/swarm/pss/notify/notify_test.go
@@ -13,7 +13,7 @@ import (
"github.com/ethereum/go-ethereum/crypto"
"github.com/ethereum/go-ethereum/log"
"github.com/ethereum/go-ethereum/node"
- "github.com/ethereum/go-ethereum/p2p/discover"
+ "github.com/ethereum/go-ethereum/p2p/enode"
"github.com/ethereum/go-ethereum/p2p/simulations"
"github.com/ethereum/go-ethereum/p2p/simulations/adapters"
"github.com/ethereum/go-ethereum/swarm/network"
@@ -203,12 +203,11 @@ func TestStart(t *testing.T) {
func newServices(allowRaw bool) adapters.Services {
stateStore := state.NewInmemoryStore()
- kademlias := make(map[discover.NodeID]*network.Kademlia)
- kademlia := func(id discover.NodeID) *network.Kademlia {
+ kademlias := make(map[enode.ID]*network.Kademlia)
+ kademlia := func(id enode.ID) *network.Kademlia {
if k, ok := kademlias[id]; ok {
return k
}
- addr := network.NewAddrFromNodeID(id)
params := network.NewKadParams()
params.MinProxBinSize = 2
params.MaxBinSize = 3
@@ -216,7 +215,7 @@ func newServices(allowRaw bool) adapters.Services {
params.MaxRetries = 1000
params.RetryExponent = 2
params.RetryInterval = 1000000
- kademlias[id] = network.NewKademlia(addr.Over(), params)
+ kademlias[id] = network.NewKademlia(id[:], params)
return kademlias[id]
}
return adapters.Services{
@@ -238,7 +237,7 @@ func newServices(allowRaw bool) adapters.Services {
return ps, nil
},
"bzz": func(ctx *adapters.ServiceContext) (node.Service, error) {
- addr := network.NewAddrFromNodeID(ctx.Config.ID)
+ addr := network.NewAddr(ctx.Config.Node())
hp := network.NewHiveParams()
hp.Discovery = false
config := &network.BzzConfig{