summaryrefslogtreecommitdiffstats
path: root/vendor/golang.org/x/net/ipv6/unicastsockopt_test.go
diff options
context:
space:
mode:
authorChristopher Speller <crspeller@gmail.com>2017-02-02 09:32:00 -0500
committerHarrison Healey <harrisonmhealey@gmail.com>2017-02-02 09:32:00 -0500
commit701d1ab638b23c24877fc41824add66232446676 (patch)
treeec120c88d38ac9d38d9eabdd3270b52bb6ac9d96 /vendor/golang.org/x/net/ipv6/unicastsockopt_test.go
parentca3211bc04f6dea34e8168217182637d1419f998 (diff)
downloadchat-701d1ab638b23c24877fc41824add66232446676.tar.gz
chat-701d1ab638b23c24877fc41824add66232446676.tar.bz2
chat-701d1ab638b23c24877fc41824add66232446676.zip
Updating server dependancies (#5249)
Diffstat (limited to 'vendor/golang.org/x/net/ipv6/unicastsockopt_test.go')
-rw-r--r--vendor/golang.org/x/net/ipv6/unicastsockopt_test.go15
1 files changed, 12 insertions, 3 deletions
diff --git a/vendor/golang.org/x/net/ipv6/unicastsockopt_test.go b/vendor/golang.org/x/net/ipv6/unicastsockopt_test.go
index 1c52b3d30..e175dccf5 100644
--- a/vendor/golang.org/x/net/ipv6/unicastsockopt_test.go
+++ b/vendor/golang.org/x/net/ipv6/unicastsockopt_test.go
@@ -29,8 +29,15 @@ func TestConnUnicastSocketOptions(t *testing.T) {
}
defer ln.Close()
- done := make(chan bool)
- go acceptor(t, ln, done)
+ errc := make(chan error, 1)
+ go func() {
+ c, err := ln.Accept()
+ if err != nil {
+ errc <- err
+ return
+ }
+ errc <- c.Close()
+ }()
c, err := net.Dial("tcp6", ln.Addr().String())
if err != nil {
@@ -40,7 +47,9 @@ func TestConnUnicastSocketOptions(t *testing.T) {
testUnicastSocketOptions(t, ipv6.NewConn(c))
- <-done
+ if err := <-errc; err != nil {
+ t.Errorf("server: %v", err)
+ }
}
var packetConnUnicastSocketOptionTests = []struct {