### Question:
JjdocExecutorAction implements Action<JavaExecSpec> { @Override public void execute(JavaExecSpec executor) { executor.classpath(classpath); executor.setMain("org.javacc.jjdoc.JJDocMain"); executor.args((Object[]) arguments.toArray()); executor.setIgnoreExitValue(true); } JjdocExecutorAction(Configuration classpath, ProgramArguments arguments); @Override void execute(JavaExecSpec executor);  }### Answer:
@Test public void executorUsesProvidedClasspath() { action.execute(javaExecSpec); verify(javaExecSpec).classpath(providedClasspath); }
@Test public void executorInvokesJjdoc() { action.execute(javaExecSpec); verify(javaExecSpec).setMain("org.javacc.jjdoc.JJDocMain"); }
@Test public void executorUsesProvidedArguments() { action.execute(javaExecSpec); verify(javaExecSpec).args((Object[]) providedArguments.toArray()); }
@Test public void executorDoesNotInterruptExecutionInCaseOfError() { action.execute(javaExecSpec); verify(javaExecSpec).setIgnoreExitValue(true); }