Skip to content

Commit

Permalink
Add test for colon in final path segment not meant as verb
Browse files Browse the repository at this point in the history
See grpc-ecosystem#224

Signed-off-by: James Hamlin <james@goforward.com>
  • Loading branch information
jfhamlin committed Jul 24, 2018
1 parent 209d7ce commit afabf9b
Showing 1 changed file with 16 additions and 0 deletions.
16 changes: 16 additions & 0 deletions runtime/mux_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -176,6 +176,22 @@ func TestMuxServeHTTP(t *testing.T) {
respStatus: http.StatusOK,
respContent: "POST /foo:bar",
},
{
patterns: []stubPattern{
{
method: "POST",
ops: []int{int(utilities.OpLitPush), 0},
pool: []string{"foo"},
},
},
reqMethod: "POST",
reqPath: "/foo:bar",
headers: map[string]string{
"Content-Type": "application/json",
},
respStatus: http.StatusOK,
respContent: "POST /foo:bar",
},
} {
mux := runtime.NewServeMux()
for _, p := range spec.patterns {
Expand Down

0 comments on commit afabf9b

Please sign in to comment.