MCPcopy Create free account
hub / github.com/BryanMwangi/pine / TestRouter_TrailingSlash

Function TestRouter_TrailingSlash

router_test.go:205–213  ·  view source on GitHub ↗
(t *testing.T)

Source from the content-addressed store, hash-verified

203}
204
205func TestRouter_TrailingSlash(t *testing.T) {
206 r := newTestRouter()
207 insertRoute(r, "GET", "/path")
208
209 _, _, found := r.Search("GET", "/path")
210 if !found {
211 t.Error("expected /path to match")
212 }
213}
214
215func TestRouter_ManyRoutes(t *testing.T) {
216 r := newTestRouter()

Callers

nothing calls this directly

Calls 4

newTestRouterFunction · 0.85
insertRouteFunction · 0.85
SearchMethod · 0.80
ErrorMethod · 0.80

Tested by

no test coverage detected