diff options
author | Matthew Holt <[email protected]> | 2019-06-20 20:24:46 -0600 |
---|---|---|
committer | Matthew Holt <[email protected]> | 2019-06-20 20:24:46 -0600 |
commit | 6d0350d04ecd7074a65d57f03bd721e75537c13d (patch) | |
tree | ace5815f5938f92cd87ff4bbd396b604bed3084a /modules/caddyhttp/matchers_test.go | |
parent | 15647bdfb757ab7b1d1c77446a0707e49f31deb7 (diff) | |
download | caddy-6d0350d04ecd7074a65d57f03bd721e75537c13d.tar.gz caddy-6d0350d04ecd7074a65d57f03bd721e75537c13d.zip |
caddyhttp: Fix host matching when host has a port
Diffstat (limited to 'modules/caddyhttp/matchers_test.go')
-rw-r--r-- | modules/caddyhttp/matchers_test.go | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/modules/caddyhttp/matchers_test.go b/modules/caddyhttp/matchers_test.go index 08ab15662..597d217c0 100644 --- a/modules/caddyhttp/matchers_test.go +++ b/modules/caddyhttp/matchers_test.go @@ -87,6 +87,11 @@ func TestHostMatcher(t *testing.T) { input: "sub.foo.example.net", expect: false, }, + { + match: MatchHost{"example.com"}, + input: "example.com:5555", + expect: true, + }, } { req := &http.Request{Host: tc.input} actual := tc.match.Match(req) |