(t *testing.T)
| 717 | } |
| 718 | |
| 719 | func TestRouteServeErrorWithWriteHeader(t *testing.T) { |
| 720 | route := New() |
| 721 | route.Use(func(c *Context) { |
| 722 | c.Status(http.StatusMisdirectedRequest) |
| 723 | c.Next() |
| 724 | }) |
| 725 | |
| 726 | w := PerformRequest(route, http.MethodGet, "/NotFound") |
| 727 | assert.Equal(t, http.StatusMisdirectedRequest, w.Code) |
| 728 | assert.Equal(t, 0, w.Body.Len()) |
| 729 | } |
| 730 | |
| 731 | func TestRouteContextHoldsFullPath(t *testing.T) { |
| 732 | router := New() |
nothing calls this directly
no test coverage detected