diff options
author | Anthony Fok <foka@debian.org> | 2015-01-16 03:13:03 -0700 |
---|---|---|
committer | Anthony Fok <foka@debian.org> | 2015-01-16 03:16:36 -0700 |
commit | 508788e6949a51b76af15eb4570e4d73e7c7b09b (patch) | |
tree | 82edee41013d5b1badcbabcbb2f40a5bc1b2f4ef /commands/server_test.go | |
parent | 3a9300ddc4f73bd4a3b29d16c0107b6bd1439632 (diff) |
Update TestFixUrl() to expect BaseUrl to have trailing `/`
See #793, #799
Diffstat (limited to 'commands/server_test.go')
-rw-r--r-- | commands/server_test.go | 18 |
1 files changed, 9 insertions, 9 deletions
diff --git a/commands/server_test.go b/commands/server_test.go index d53a15b78..1e1343d44 100644 --- a/commands/server_test.go +++ b/commands/server_test.go @@ -16,15 +16,15 @@ func TestFixUrl(t *testing.T) { Result string } tests := []data{ - {"Basic http localhost", "", "http://foo.com", true, 1313, "http://localhost:1313"}, - {"Basic https production, http localhost", "", "https://foo.com", true, 1313, "http://localhost:1313"}, - {"Basic subdir", "", "http://foo.com/bar", true, 1313, "http://localhost:1313/bar"}, - {"Basic production", "http://foo.com", "http://foo.com", false, 80, "http://foo.com"}, - {"Production subdir", "http://foo.com/bar", "http://foo.com/bar", false, 80, "http://foo.com/bar"}, - {"No http", "", "foo.com", true, 1313, "http://localhost:1313"}, - {"Override configured port", "", "foo.com:2020", true, 1313, "http://localhost:1313"}, - {"No http production", "foo.com", "foo.com", false, 80, "http://foo.com"}, - {"No http production with port", "foo.com", "foo.com", true, 2020, "http://foo.com:2020"}, + {"Basic http localhost", "", "http://foo.com", true, 1313, "http://localhost:1313/"}, + {"Basic https production, http localhost", "", "https://foo.com", true, 1313, "http://localhost:1313/"}, + {"Basic subdir", "", "http://foo.com/bar", true, 1313, "http://localhost:1313/bar/"}, + {"Basic production", "http://foo.com", "http://foo.com", false, 80, "http://foo.com/"}, + {"Production subdir", "http://foo.com/bar", "http://foo.com/bar", false, 80, "http://foo.com/bar/"}, + {"No http", "", "foo.com", true, 1313, "http://localhost:1313/"}, + {"Override configured port", "", "foo.com:2020", true, 1313, "http://localhost:1313/"}, + {"No http production", "foo.com", "foo.com", false, 80, "http://foo.com/"}, + {"No http production with port", "foo.com", "foo.com", true, 2020, "http://foo.com:2020/"}, } for i, test := range tests { |