use of com.tvd12.ezyhttp.server.core.manager.RequestHandlerManager in project ezyhttp by youngmonkeys.
the class RequestHandlersImplementerTest method implementOneAllowOverrideURI.
@Test
public void implementOneAllowOverrideURI() {
// given
RequestHandlersImplementer sut = new RequestHandlersImplementer();
Controller controller = new Controller();
RequestHandlerManager manager = new RequestHandlerManager();
manager.setAllowOverrideURI(true);
// when
manager.addHandlers(sut.implement(Collections.singletonList(controller)));
// then
RequestURI uri = new RequestURI(HttpMethod.GET, "/get", false);
Asserts.assertThat(manager.getHandlerListByURI().get(uri).size()).isEqualsTo(2);
}
Aggregations