(t *testing.T)
| 772 | } |
| 773 | |
| 774 | func TestEngineHandleMethodNotAllowedCornerCase(t *testing.T) { |
| 775 | r := New() |
| 776 | r.HandleMethodNotAllowed = true |
| 777 | |
| 778 | base := r.Group("base") |
| 779 | base.GET("/metrics", handlerTest1) |
| 780 | |
| 781 | v1 := base.Group("v1") |
| 782 | |
| 783 | v1.GET("/:id/devices", handlerTest1) |
| 784 | v1.GET("/user/:id/groups", handlerTest1) |
| 785 | |
| 786 | v1.GET("/orgs/:id", handlerTest1) |
| 787 | v1.DELETE("/orgs/:id", handlerTest1) |
| 788 | |
| 789 | w := PerformRequest(r, http.MethodGet, "/base/v1/user/groups") |
| 790 | assert.Equal(t, http.StatusNotFound, w.Code) |
| 791 | } |
nothing calls this directly
no test coverage detected