Package com.theoryinpractise.clojure
Class ClojureRunTestWithJUnitMojo
java.lang.Object
org.apache.maven.plugin.AbstractMojo
com.theoryinpractise.clojure.AbstractClojureCompilerMojo
com.theoryinpractise.clojure.ClojureRunTestWithJUnitMojo
- All Implemented Interfaces:
org.apache.maven.plugin.ContextEnabled,org.apache.maven.plugin.Mojo
- Direct Known Subclasses:
ClojureRunTestMojo
@Mojo(name="test-with-junit",
defaultPhase=TEST,
requiresDependencyResolution=TEST)
public class ClojureRunTestWithJUnitMojo
extends AbstractClojureCompilerMojo
-
Nested Class Summary
Nested classes/interfaces inherited from class com.theoryinpractise.clojure.AbstractClojureCompilerMojo
AbstractClojureCompilerMojo.SourceDirectory -
Field Summary
FieldsModifier and TypeFieldDescriptionprivate booleanFlag to allow test compiliation to be skipped.private booleanFlag to allow test execution to be skipped.private StringProvide a comma separated list of tests to run, instead of trying to run all of the test.private StringOutput directory for test resultsprivate StringThe main clojure script to runprivate booleanWhether to XML escape non-report output sent to *out*Fields inherited from class com.theoryinpractise.clojure.AbstractClojureCompilerMojo
baseDirectory, baseTestSourceDirectory, charset, classpathElements, compileDeclaredNamespaceOnly, copiedNamespaces, copyDeclaredNamespaceOnly, directLinking, generatedSourceDirectory, namespaces, outputDirectory, project, sourceDirectories, testClasspathElements, testDeclaredNamespaceOnly, testNamespaces, testSourceDirectories, workingDirectoryFields inherited from interface org.apache.maven.plugin.Mojo
ROLE -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidexecute()protected voidgenerateConfig(PrintWriter writer, NamespaceInFile[] ns) private voidgenerateTestScript(PrintWriter writer) protected PropertiesgetProps(NamespaceInFile[] ns) Methods inherited from class com.theoryinpractise.clojure.AbstractClojureCompilerMojo
callClojureWith, callClojureWith, callClojureWith, callClojureWith, copyNamespaceSourceFilesToOutput, createTemporaryDirectory, discoverNamespaces, discoverNamespacesToCopy, escapeFilePath, escapeFilePath, getDefaultJavaHomeExecutable, getRunWithClasspathElements, getSourceDirectories, getWorkingDirectory, isClasspathResource, isExistingTestScriptFileMethods inherited from class org.apache.maven.plugin.AbstractMojo
getLog, getPluginContext, setLog, setPluginContext
-
Field Details
-
skip
@Parameter(required=true, property="maven.test.skip", defaultValue="false") private boolean skipFlag to allow test compiliation to be skipped. -
skipTests
@Parameter(required=true, property="skipTests", defaultValue="false") private boolean skipTestsFlag to allow test execution to be skipped. -
testScript
The main clojure script to run -
testOutputDirectory
@Parameter(defaultValue="${project.build.directory}/test-reports", property="clojure.testOutputDirectory") private String testOutputDirectoryOutput directory for test results -
xmlEscapeOutput
@Parameter(defaultValue="true", property="clojure.xmlEscapeOutput") private boolean xmlEscapeOutputWhether to XML escape non-report output sent to *out* -
test
Provide a comma separated list of tests to run, instead of trying to run all of the test.
-
-
Constructor Details
-
ClojureRunTestWithJUnitMojo
public ClojureRunTestWithJUnitMojo()
-
-
Method Details
-
execute
public void execute() throws org.apache.maven.plugin.MojoExecutionException- Throws:
org.apache.maven.plugin.MojoExecutionException
-
generateConfig
- Throws:
IOException
-
getProps
-
generateTestScript
- Throws:
IOException
-