public <T> String checkPropertyValidity(PropertyType<T> propertyType, T propertyValue) { return _checkPropertyValidity(phase, propertyType, propertyValue); }
@Test public void testResourceError() throws Exception { MockApplication<?> app = application("plugin.controller.resource.throwable.error").init(); // MockClient client = app.client(); MockViewBridge render = client.render(); MockRequestBridge request = client.invoke(render.assertStringResponse()); request.assertFailure(UnknownError.class); } }
List<Scoped> attributes = request.getAttributesHistory(); assertEquals(1, attributes.size()); Identifiable car = (Identifiable)attributes.iterator().next().get(); attributes = request.getAttributesHistory(); assertEquals(1, attributes.size()); car = (Identifiable)attributes.iterator().next().get(); attributes = request.getAttributesHistory(); assertEquals(1, attributes.size()); car = (Identifiable)attributes.iterator().next().get();
@Test public void testResourceRuntime() throws Exception { MockApplication<?> app = application("plugin.controller.resource.throwable.runtime").init(); // MockClient client = app.client(); MockViewBridge render = client.render(); MockRequestBridge request = client.invoke(render.assertStringResponse()); request.assertFailure(ConcurrentModificationException.class); }
List<Scoped> attributes = request.getAttributesHistory(); assertEquals(1, attributes.size()); Identifiable car = (Identifiable)attributes.iterator().next().get(); attributes = request.getAttributesHistory(); assertEquals(1, attributes.size()); car = (Identifiable)attributes.iterator().next().get(); attributes = request.getAttributesHistory(); assertEquals(1, attributes.size()); car = (Identifiable)attributes.iterator().next().get();
@Test public void testActionChecked() throws Exception { MockApplication<?> app = application("plugin.controller.action.throwable.checked").init(); // MockClient client = app.client(); MockViewBridge render = client.render(); MockRequestBridge request = client.invoke(render.assertStringResponse()); request.assertFailure(AuthenticationException.class); }
public <T> String checkPropertyValidity(PropertyType<T> propertyType, T propertyValue) { return _checkPropertyValidity(phase, propertyType, propertyValue); }
@Test public void testResourceChecked() throws Exception { MockApplication<?> app = application("plugin.controller.resource.throwable.checked").init(); // MockClient client = app.client(); MockViewBridge render = client.render(); MockRequestBridge request = client.invoke(render.assertStringResponse()); request.assertFailure(AuthenticationException.class); }
for (PropertyType<?> property : properties) { Object value = properties.getValue(property); String valid = _checkPropertyValidity(handler.getPhase(), property, value); if (valid != null) { throw new IllegalArgumentException(valid);
@Test public void testActionRuntime() throws Exception { MockApplication<?> app = application("plugin.controller.action.throwable.runtime").init(); // MockClient client = app.client(); MockViewBridge render = client.render(); MockRequestBridge request = client.invoke(render.assertStringResponse()); request.assertFailure(ConcurrentModificationException.class); }
for (PropertyType<?> property : properties) { Object value = properties.getValue(property); String valid = _checkPropertyValidity(handler.getPhase(), property, value); if (valid != null) { throw new IllegalArgumentException(valid);
@Test public void testActionError() throws Exception { MockApplication<?> app = application("plugin.controller.action.throwable.error").init(); // MockClient client = app.client(); MockViewBridge render = client.render(); MockRequestBridge request = client.invoke(render.assertStringResponse()); request.assertFailure(UnknownError.class); }
@Test public void testResourceChecked() throws Exception { MockApplication<?> app = application("plugin.controller.resource.throwable.checked").init(); // MockClient client = app.client(); MockViewBridge render = client.render(); MockRequestBridge request = client.invoke(render.assertStringResponse()); request.assertFailure(AuthenticationException.class); }
@Test public void testActionChecked() throws Exception { MockApplication<?> app = application("plugin.controller.action.throwable.checked").init(); // MockClient client = app.client(); MockViewBridge render = client.render(); MockRequestBridge request = client.invoke(render.assertStringResponse()); request.assertFailure(AuthenticationException.class); }
@Test public void testActionRuntime() throws Exception { MockApplication<?> app = application("plugin.controller.action.throwable.runtime").init(); // MockClient client = app.client(); MockViewBridge render = client.render(); MockRequestBridge request = client.invoke(render.assertStringResponse()); request.assertFailure(ConcurrentModificationException.class); }
@Test public void testResourceError() throws Exception { MockApplication<?> app = application("plugin.controller.resource.throwable.error").init(); // MockClient client = app.client(); MockViewBridge render = client.render(); MockRequestBridge request = client.invoke(render.assertStringResponse()); request.assertFailure(UnknownError.class); } }
@Test public void testActionError() throws Exception { MockApplication<?> app = application("plugin.controller.action.throwable.error").init(); // MockClient client = app.client(); MockViewBridge render = client.render(); MockRequestBridge request = client.invoke(render.assertStringResponse()); request.assertFailure(UnknownError.class); }
@Test public void testResourceRuntime() throws Exception { MockApplication<?> app = application("plugin.controller.resource.throwable.runtime").init(); // MockClient client = app.client(); MockViewBridge render = client.render(); MockRequestBridge request = client.invoke(render.assertStringResponse()); request.assertFailure(ConcurrentModificationException.class); }