aboutsummaryrefslogtreecommitdiffstats
path: root/p2p/discover/udp_test.go
diff options
context:
space:
mode:
authorFelix Lange <fjl@twurst.com>2015-02-13 18:38:34 +0800
committerFelix Lange <fjl@twurst.com>2015-02-13 18:39:32 +0800
commit170eb3ac684231dc2ddebc34e7006e0f2b5fc0c1 (patch)
tree01ccbe10fb2bfec738b3a3584f7999a01f9fbdd5 /p2p/discover/udp_test.go
parent82f0bd9009d8d577c86e800e9673a1972117113d (diff)
downloaddexon-170eb3ac684231dc2ddebc34e7006e0f2b5fc0c1.tar
dexon-170eb3ac684231dc2ddebc34e7006e0f2b5fc0c1.tar.gz
dexon-170eb3ac684231dc2ddebc34e7006e0f2b5fc0c1.tar.bz2
dexon-170eb3ac684231dc2ddebc34e7006e0f2b5fc0c1.tar.lz
dexon-170eb3ac684231dc2ddebc34e7006e0f2b5fc0c1.tar.xz
dexon-170eb3ac684231dc2ddebc34e7006e0f2b5fc0c1.tar.zst
dexon-170eb3ac684231dc2ddebc34e7006e0f2b5fc0c1.zip
p2p/discover: map listening port using configured mechanism
Diffstat (limited to 'p2p/discover/udp_test.go')
-rw-r--r--p2p/discover/udp_test.go14
1 files changed, 7 insertions, 7 deletions
diff --git a/p2p/discover/udp_test.go b/p2p/discover/udp_test.go
index 740d0a5d9..0a8ff6358 100644
--- a/p2p/discover/udp_test.go
+++ b/p2p/discover/udp_test.go
@@ -18,8 +18,8 @@ func init() {
func TestUDP_ping(t *testing.T) {
t.Parallel()
- n1, _ := ListenUDP(newkey(), "127.0.0.1:0")
- n2, _ := ListenUDP(newkey(), "127.0.0.1:0")
+ n1, _ := ListenUDP(newkey(), "127.0.0.1:0", nil)
+ n2, _ := ListenUDP(newkey(), "127.0.0.1:0", nil)
defer n1.Close()
defer n2.Close()
@@ -48,8 +48,8 @@ func find(tab *Table, id NodeID) *Node {
func TestUDP_findnode(t *testing.T) {
t.Parallel()
- n1, _ := ListenUDP(newkey(), "127.0.0.1:0")
- n2, _ := ListenUDP(newkey(), "127.0.0.1:0")
+ n1, _ := ListenUDP(newkey(), "127.0.0.1:0", nil)
+ n2, _ := ListenUDP(newkey(), "127.0.0.1:0", nil)
defer n1.Close()
defer n2.Close()
@@ -98,7 +98,7 @@ func TestUDP_replytimeout(t *testing.T) {
}
defer fd.Close()
- n1, _ := ListenUDP(newkey(), "127.0.0.1:0")
+ n1, _ := ListenUDP(newkey(), "127.0.0.1:0", nil)
defer n1.Close()
n2 := n1.bumpOrAdd(randomID(n1.self.ID, 10), fd.LocalAddr().(*net.UDPAddr))
@@ -116,8 +116,8 @@ func TestUDP_replytimeout(t *testing.T) {
func TestUDP_findnodeMultiReply(t *testing.T) {
t.Parallel()
- n1, _ := ListenUDP(newkey(), "127.0.0.1:0")
- n2, _ := ListenUDP(newkey(), "127.0.0.1:0")
+ n1, _ := ListenUDP(newkey(), "127.0.0.1:0", nil)
+ n2, _ := ListenUDP(newkey(), "127.0.0.1:0", nil)
udp2 := n2.net.(*udp)
defer n1.Close()
defer n2.Close()