public void testInvalidMethodArgs() throws Exception { CompilerAssert<?, ?> compiler = compiler("plugin.template.url.invalid_method_args"); List<CompilationError> errors = compiler.failCompile(); assertEquals("Was expecting 1 error instead of " + errors, 1, errors.size()); CompilationError error = errors.get(0); assertEquals("/plugin/template/url/invalid_method_args/A.java", error.getSource()); }
@Test public void testContextutal() throws Exception { MockApplication<?> app = application(InjectorProvider.WELD, "plugin.template.url.contextual").init(); MockClient client = app.client(); String url = client.render().assertStringResponse(); assertEquals("pass", ((MockViewBridge)client.invoke(url)).assertStringResponse()); } }
public void testOverload() throws Exception { CompilerAssert<?, ?> compiler = compiler("plugin.template.url.overload"); compiler.assertCompile(); }
@Test public void testContextutal() throws Exception { MockApplication<?> app = application(InjectorProvider.WELD, "plugin.template.url.contextual").init(); MockClient client = app.client(); String url = client.render().assertStringResponse(); assertEquals("pass", ((MockViewBridge)client.invoke(url)).assertStringResponse()); } }
public void testOverload() throws Exception { CompilerAssert<?, ?> compiler = compiler("plugin.template.url.overload"); compiler.assertCompile(); }
public void testInvalidMethodName() throws Exception { CompilerAssert<?, ?> compiler = compiler("plugin.template.url.invalid_method_name"); List<CompilationError> errors = compiler.failCompile(); assertEquals("Was expecting 1 error instead of " + errors, 1, errors.size()); CompilationError error = errors.get(0); assertEquals("/plugin/template/url/invalid_method_name/A.java", error.getSource()); }
@Test public void testResolution() throws Exception { CompilerAssert<?, ?> compiler = compiler("plugin.template.url.resolution"); compiler.assertCompile(); }
public void testInvalidMethodName() throws Exception { CompilerAssert<?, ?> compiler = compiler("plugin.template.url.invalid_method_name"); List<CompilationError> errors = compiler.failCompile(); assertEquals("Was expecting 1 error instead of " + errors, 1, errors.size()); CompilationError error = errors.get(0); assertEquals("/plugin/template/url/invalid_method_name/A.java", error.getSource()); }
@Test public void testResolution() throws Exception { CompilerAssert<?, ?> compiler = compiler("plugin.template.url.resolution"); compiler.assertCompile(); }
public void testInvalidMethodArgs() throws Exception { CompilerAssert<?, ?> compiler = compiler("plugin.template.url.invalid_method_args"); List<CompilationError> errors = compiler.failCompile(); assertEquals("Was expecting 1 error instead of " + errors, 1, errors.size()); CompilationError error = errors.get(0); assertEquals("/plugin/template/url/invalid_method_args/A.java", error.getSource()); }