aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAlex Brainman <alex.brainman@gmail.com>2011-11-17 11:20:42 +1100
committerAlex Brainman <alex.brainman@gmail.com>2011-11-17 11:20:42 +1100
commit3ec82f6e0960ffd082a6b63b3c784e8901bd3c4d (patch)
tree58714b7d591dcde1bc588b8226a136b9c998ee75
parenta479a455489bc3600c004367f16c4d452705d2c9 (diff)
downloadgo-3ec82f6e0960ffd082a6b63b3c784e8901bd3c4d.tar.gz
go-3ec82f6e0960ffd082a6b63b3c784e8901bd3c4d.zip
exp/ssh: change test listen address, also exit test if fails
R=golang-dev, rsc CC=dave, golang-dev https://golang.org/cl/5364061
-rw-r--r--src/pkg/exp/ssh/client_auth_test.go8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/pkg/exp/ssh/client_auth_test.go b/src/pkg/exp/ssh/client_auth_test.go
index cfd6a39d70..6467f57835 100644
--- a/src/pkg/exp/ssh/client_auth_test.go
+++ b/src/pkg/exp/ssh/client_auth_test.go
@@ -161,7 +161,7 @@ func TestClientAuthPassword(t *testing.T) {
}
serverConfig.PubKeyCallback = nil
- l, err := Listen("tcp", "0.0.0.0:0", serverConfig)
+ l, err := Listen("tcp", "127.0.0.1:0", serverConfig)
if err != nil {
t.Fatalf("unable to listen: %s", err)
}
@@ -189,7 +189,7 @@ func TestClientAuthPassword(t *testing.T) {
c, err := Dial("tcp", l.Addr().String(), config)
if err != nil {
- t.Errorf("unable to dial remote side: %s", err)
+ t.Fatalf("unable to dial remote side: %s", err)
}
defer c.Close()
<-done
@@ -211,7 +211,7 @@ func TestClientAuthPasswordAndPublickey(t *testing.T) {
return user == "testuser" && algo == algoname && bytes.Equal(pubkey, expected)
}
- l, err := Listen("tcp", "0.0.0.0:0", serverConfig)
+ l, err := Listen("tcp", "127.0.0.1:0", serverConfig)
if err != nil {
t.Fatalf("unable to listen: %s", err)
}
@@ -241,7 +241,7 @@ func TestClientAuthPasswordAndPublickey(t *testing.T) {
c, err := Dial("tcp", l.Addr().String(), config)
if err != nil {
- t.Errorf("unable to dial remote side: %s", err)
+ t.Fatalf("unable to dial remote side: %s", err)
}
defer c.Close()
<-done