Skip to content

Commit

Permalink
fixed docker test to use new default port
Browse files Browse the repository at this point in the history
  • Loading branch information
bradrydzewski committed Sep 24, 2014
1 parent cc87e7a commit 7fed5f5
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions shared/build/docker/client_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ import (
)

func TestHostFromEnv(t *testing.T) {
os.Setenv("DOCKER_HOST", "tcp://1.1.1.1:4243")
os.Setenv("DOCKER_HOST", "tcp://1.1.1.1:2375")
defer os.Setenv("DOCKER_HOST", "")

client := New()
Expand All @@ -16,18 +16,18 @@ func TestHostFromEnv(t *testing.T) {
t.Fail()
}

if client.addr != "1.1.1.1:4243" {
if client.addr != "1.1.1.1:2375" {
t.Fail()
}
}

func TestInvalidHostFromEnv(t *testing.T) {
os.Setenv("DOCKER_HOST", "tcp:1.1.1.1:4243") // missing tcp:// prefix
os.Setenv("DOCKER_HOST", "tcp:1.1.1.1:2375") // missing tcp:// prefix
defer os.Setenv("DOCKER_HOST", "")

client := New()

if client.addr == "1.1.1.1:4243" {
if client.addr == "1.1.1.1:2375" {
t.Fail()
}
}
Expand Down Expand Up @@ -61,7 +61,7 @@ func TestDefaultTcpHost(t *testing.T) {
t.Fail()
}

if client.addr != "0.0.0.0:4243" {
if client.addr != "0.0.0.0:2375" {
t.Fail()
}
}

0 comments on commit 7fed5f5

Please sign in to comment.