MCPcopy
hub / github.com/labstack/echo / TestToContext_PathValues

Function TestToContext_PathValues

echotest/context_test.go:66–78  ·  view source on GitHub ↗
(t *testing.T)

Source from the content-addressed store, hash-verified

64}
65
66func TestToContext_PathValues(t *testing.T) {
67 testConf := ContextConfig{
68 PathValues: echo.PathValues{{
69 Name: "key",
70 Value: "value",
71 }},
72 }
73 c := testConf.ToContext(t)
74
75 key := c.Param("key")
76
77 assert.Equal(t, "value", key)
78}
79
80func TestToContext_RouteInfo(t *testing.T) {
81 testConf := ContextConfig{

Callers

nothing calls this directly

Calls 2

ToContextMethod · 0.95
ParamMethod · 0.80

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…