chore(router): match method added to routergroup for multiple HTTP methods supporting (#3464)

This commit is contained in:
Alireza (Pure)
2023-02-06 11:16:42 +03:30
committed by GitHub
parent c5fd06361b
commit e02ae6ae61
2 changed files with 11 additions and 0 deletions

View File

@ -186,6 +186,7 @@ func testRoutesInterface(t *testing.T, r IRoutes) {
assert.Equal(t, r, r.PUT("/", handler))
assert.Equal(t, r, r.OPTIONS("/", handler))
assert.Equal(t, r, r.HEAD("/", handler))
assert.Equal(t, r, r.Match([]string{http.MethodPut, http.MethodPatch}, "/match", handler))
assert.Equal(t, r, r.StaticFile("/file", "."))
assert.Equal(t, r, r.StaticFileFS("/static2", ".", Dir(".", false)))