Esempio n. 1
0
 public Compiler assertCompile() {
   try {
     strategy.compile();
     classLoader = new URLClassLoader(new URL[] {strategy.classOutput.getURL()}, baseClassLoader);
     return strategy.compiler;
   } catch (Exception e) {
     throw AbstractTestCase.failure(e);
   }
 }
Esempio n. 2
0
 public List<CompilationError> failCompile() {
   try {
     strategy.compile();
     throw AbstractTestCase.failure("Was expecting compilation to fail");
   } catch (CompilationException e) {
     return e.getErrors();
   } catch (Exception e) {
     throw AbstractTestCase.failure(e);
   }
 }
Esempio n. 3
0
 public CompilerAssert<I, O> addClassPath(ReadFileSystem<?> classPath) {
   strategy.addClassPath(classPath);
   return this;
 }
Esempio n. 4
0
 public CompilerAssert<I, O> with(Provider<? extends Processor> processorFactory) {
   strategy.processorFactory = processorFactory;
   return this;
 }