Package de.saumya.mojo.tests
Class AbstractTestMojo
java.lang.Object
org.apache.maven.plugin.AbstractMojo
de.saumya.mojo.jruby.AbstractJRubyMojo
de.saumya.mojo.gem.AbstractGemMojo
de.saumya.mojo.tests.AbstractTestMojo
- All Implemented Interfaces:
org.apache.maven.plugin.ContextEnabled,org.apache.maven.plugin.Mojo
- Direct Known Subclasses:
MinispecMojo,MinitestMojo,RSpecMojo,RUnitMojo
maven wrapper around some test command.
-
Field Summary
FieldsModifier and TypeFieldDescriptionprotected Stringrun tests with list of ruby modes 1.8, 1.9, 2.0, 2.2protected booleanskip all testsprotected booleanskip all testsprotected FileThe name of the summary (xml-)report which can be used by TeamCity and Co.protected Fileprotected Stringrun tests with a several versions of jrubyFields inherited from class de.saumya.mojo.gem.AbstractGemMojo
binDirectory, gemHome, gemHomes, gemPath, gemsConfig, gemsInstaller, gemUseSystem, includeGemsInResources, includeLibDirectoryInResources, includeOpenSSL, includeProvidedRubygemsInResources, includeRubygemsInResources, includeRubygemsInTestResources, installRDoc, installRI, manager, plugin, supportNative, unzipFields inherited from class de.saumya.mojo.jruby.AbstractJRubyMojo
addProjectClasspath, args, classRealm, DEFAULT_JRUBY_VERSION, eclipseRefresh, eclipseWatches, env, factory, JRUBY_COMPLETE, JRUBY_CORE, JRUBY_STDLIB, jrubyFork, jrubyJvmArgs, jrubySwitches, jrubyVerbose, libDirectory, localRepository, logger, project, repositorySystem, rubySourceDirectoryFields inherited from interface org.apache.maven.plugin.Mojo
ROLE -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprivate JRubyVersion.Mode[]calculateModes(JRubyVersion.Mode defaultMode) private JRubyVersion[]protected voidprotected abstract TestScriptFactoryprotected abstract JRubyRun.ResultrunIt(ScriptFactory factory, JRubyVersion.Mode mode, JRubyVersion version, TestScriptFactory testScriptFactory) protected voidrunIt(JRubyRun run, TestScriptFactory testScriptFactory) Methods inherited from class de.saumya.mojo.gem.AbstractGemMojo
addResource, execute, executeJRuby, gemHome, getRemoteRepos, newScriptFactoryMethods inherited from class de.saumya.mojo.jruby.AbstractJRubyMojo
getDefaultJRubyVersion, getJrubyVersion, getProjectClasspath, launchDirectory, resolveJRubyArtifact, resolveJRubyCompleteArtifact, resolveJRubyStdlibArtifactMethods inherited from class org.apache.maven.plugin.AbstractMojo
getLog, getPluginContext, setLog, setPluginContext
-
Field Details
-
testReportDirectory
@Parameter(defaultValue="${project.build.directory}/surefire-reports") protected File testReportDirectory -
skipTests
@Parameter(property="skipTests", defaultValue="false") protected boolean skipTestsskip all tests -
skip
@Parameter(property="maven.test.skip", defaultValue="false") protected boolean skipskip all tests -
modes
run tests with list of ruby modes 1.8, 1.9, 2.0, 2.2 -
versions
run tests with a several versions of jruby -
summaryReport
The name of the summary (xml-)report which can be used by TeamCity and Co.
-
-
Constructor Details
-
AbstractTestMojo
public AbstractTestMojo()
-
-
Method Details
-
calculateModes
-
calculateVersions
-
executeWithGems
protected void executeWithGems() throws org.apache.maven.plugin.MojoExecutionException, IOException, ScriptException, GemException- Specified by:
executeWithGemsin classAbstractGemMojo- Throws:
org.apache.maven.plugin.MojoExecutionExceptionIOExceptionScriptExceptionGemException
-
runIt
protected void runIt(JRubyRun run, TestScriptFactory testScriptFactory) throws org.apache.maven.plugin.MojoExecutionException, IOException, ScriptException - Throws:
org.apache.maven.plugin.MojoExecutionExceptionIOExceptionScriptException
-
newTestScriptFactory
-
runIt
protected abstract JRubyRun.Result runIt(ScriptFactory factory, JRubyVersion.Mode mode, JRubyVersion version, TestScriptFactory testScriptFactory) throws IOException, ScriptException, org.apache.maven.plugin.MojoExecutionException - Throws:
IOExceptionScriptExceptionorg.apache.maven.plugin.MojoExecutionException
-