(t *testing.T)
| 776 | } |
| 777 | |
| 778 | func TestEngineHandleContextUseEscapedPathOverride(t *testing.T) { |
| 779 | r := New() |
| 780 | r.UseEscapedPath = true |
| 781 | r.UseRawPath = true |
| 782 | r.UnescapePathValues = false |
| 783 | |
| 784 | r.GET("/v1/:path", func(c *Context) { |
| 785 | assert.Equal(t, "foo%25bar", c.Param("path")) |
| 786 | c.Status(http.StatusOK) |
| 787 | }) |
| 788 | |
| 789 | assert.NotPanics(t, func() { |
| 790 | w := PerformRequest(r, http.MethodGet, "/v1/foo%25bar") |
| 791 | assert.Equal(t, 200, w.Code) |
| 792 | }) |
| 793 | } |
| 794 | |
| 795 | func TestPrepareTrustedCIRDsWith(t *testing.T) { |
| 796 | r := New() |
nothing calls this directly
no test coverage detected