(t *testing.T)
| 169 | } |
| 170 | |
| 171 | func TestControllerHandleWithDynamicPathPrefix(t *testing.T) { |
| 172 | app := iris.New() |
| 173 | New(app.Party("/api/data/{model:string}/{action:string}")).Handle(new(testControllerHandleWithDynamicPathPrefix)) |
| 174 | e := httptest.New(t, app) |
| 175 | e.GET("/api/data/mymodel/myaction/myid").Expect().Status(httptest.StatusOK). |
| 176 | Body().IsEqual("mymodelmyactionmyid") |
| 177 | } |
| 178 | |
| 179 | type testControllerGetBy struct{} |
| 180 |