Closed
Description
So as a follow up to #77, I'm running Go 1.5.1 which claims to have been the cause of that issue: #77 (comment) and I am still seeing issues with uriEncoded paths.
Example:
// router build
router = mux.NewRouter()
router.HandleFunc("/status", status).Methods("GET")
apiRouter := mux.NewRouter()
apiRouter.HandleFunc("/foo", getFooList).Methods("GET")
apiRouter.HandleFunc("/foo/{bar}", getFoo).Methods("GET")
router.PathPrefix("/foo").Handler(apiRouter)
url := httptest.NewServer(router).URL
url1 := strings.Join([]string{url, "/foo/bar%2ftest"}, "")
// url2 := strings.Join([]string{url, "/foo/bar.test}", "")
req, _ := http.NewRequest("GET", url1, nil)
client := &http.Client{}
req, err := client.Do(req)
fmt.Printf("Req: %+v \n Err: %+v \n", req, err)
If I use url1
I get a 404, if I use url2
I get a 200. Thoughts? I am using Ember-Data to generate API calls so short of performing a huge hack on both ends which doesn't seem reasonable.