use of org.apache.sling.scripting.sightly.compiler.CompilationResult in project sling by apache.
the class SightlyCompilerTest method testErrorReporting1.
@Test
public void testErrorReporting1() {
String script = "/error-1.html";
CompilationResult result = compile(script);
List<CompilerMessage> errors = result.getErrors();
assertTrue("Expected compilation errors.", errors.size() == 1);
CompilerMessage error = errors.get(0);
assertEquals("Error is not reported at the expected line.", 18, error.getLine());
}
Aggregations