Skip to content

Commit

Permalink
Fixing Regexp in the benchmark test (gorilla#234)
Browse files Browse the repository at this point in the history
Signed-off-by: DiSiqueira <[email protected]>
  • Loading branch information
disiqueira authored and kisielk committed Feb 28, 2017
1 parent ad4ce0e commit 599cba5
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion bench_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 24,7 @@ func BenchmarkMux(b *testing.B) {
func BenchmarkMuxAlternativeInRegexp(b *testing.B) {
router := new(Router)
handler := func(w http.ResponseWriter, r *http.Request) {}
router.HandleFunc("/v1/{v1:(a|b)}", handler)
router.HandleFunc("/v1/{v1:(?:a|b)}", handler)

requestA, _ := http.NewRequest("GET", "/v1/a", nil)
requestB, _ := http.NewRequest("GET", "/v1/b", nil)
Expand Down

0 comments on commit 599cba5

Please sign in to comment.