From 47d1f5eecf60eb10de8a942dbee10a51c474737d Mon Sep 17 00:00:00 2001 From: Matthew Holt Date: Tue, 23 Jun 2015 22:13:29 -0600 Subject: [PATCH] Removed tests that are not cross-platform compatible --- config/config_test.go | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/config/config_test.go b/config/config_test.go index e0e4db23..a0cb6ec2 100644 --- a/config/config_test.go +++ b/config/config_test.go @@ -12,6 +12,9 @@ func TestReolveAddr(t *testing.T) { // If that happens, maybe we should use actualAddr.IP.IsLoopback() // for the assertion, rather than a direct string comparison. + // NOTE: Tests with {Host: "", Port: ""} and {Host: "localhost", Port: ""} + // will not behave the same cross-platform, so they have bene omitted. + for i, test := range []struct { config server.Config shouldWarnErr bool @@ -24,8 +27,6 @@ func TestReolveAddr(t *testing.T) { {server.Config{Host: "should-not-resolve", Port: "1234"}, true, false, "0.0.0.0", 1234}, {server.Config{Host: "localhost", Port: "http"}, false, false, "127.0.0.1", 80}, {server.Config{Host: "localhost", Port: "https"}, false, false, "127.0.0.1", 443}, - {server.Config{Host: "", Port: ""}, false, true, "", 0}, - {server.Config{Host: "localhost", Port: ""}, false, true, "127.0.0.1", 0}, {server.Config{Host: "", Port: "1234"}, false, false, "", 1234}, {server.Config{Host: "localhost", Port: "abcd"}, false, true, "", 0}, {server.Config{BindHost: "127.0.0.1", Host: "should-not-be-used", Port: "1234"}, false, false, "127.0.0.1", 1234},