fs test: Resolve localhost, some platforms are funny about it

This commit is contained in:
Matt Joiner 2015-02-26 16:11:33 +11:00
parent f588522b66
commit fd5c0798e3
1 changed files with 4 additions and 1 deletions

View File

@ -222,7 +222,10 @@ func TestDownloadOnDemand(t *testing.T) {
panic(err)
}
return torrent.Peer{
IP: net.IPv6loopback,
IP: func() net.IP {
ret, _ := net.ResolveIPAddr("ip", "localhost")
return ret.IP
}(),
Port: int(portInt64),
}
}()})