Class RSpecMojo

  • All Implemented Interfaces:
    org.apache.maven.plugin.ContextEnabled, org.apache.maven.plugin.Mojo

    @Mojo(name="test",
          defaultPhase=TEST,
          requiresDependencyResolution=TEST)
    public class RSpecMojo
    extends de.saumya.mojo.tests.AbstractTestMojo
    executes the jruby command.
    • Field Summary

      Fields 
      Modifier and Type Field Description
      protected boolean skipSpecs
      skip rspecs
      protected java.lang.String specSourceDirectory
      The directory containing the RSpec source files
      • Fields inherited from class de.saumya.mojo.tests.AbstractTestMojo

        modes, skip, skipTests, summaryReport, testReportDirectory, versions
      • Fields 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, unzip
      • Fields 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, rubySourceDirectory
      • Fields inherited from interface org.apache.maven.plugin.Mojo

        ROLE
    • Constructor Summary

      Constructors 
      Constructor Description
      RSpecMojo()  
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      void execute()  
      protected de.saumya.mojo.tests.TestScriptFactory newTestScriptFactory()  
      protected de.saumya.mojo.tests.JRubyRun.Result runIt​(de.saumya.mojo.ruby.script.ScriptFactory factory, de.saumya.mojo.jruby.JRubyVersion.Mode mode, de.saumya.mojo.jruby.JRubyVersion version, de.saumya.mojo.tests.TestScriptFactory scriptFactory)  
      • Methods inherited from class de.saumya.mojo.tests.AbstractTestMojo

        executeWithGems, runIt
      • Methods inherited from class de.saumya.mojo.gem.AbstractGemMojo

        addResource, executeJRuby, gemHome, getRemoteRepos, newScriptFactory
      • Methods inherited from class de.saumya.mojo.jruby.AbstractJRubyMojo

        getDefaultJRubyVersion, getJrubyVersion, getProjectClasspath, launchDirectory, resolveJRubyArtifact, resolveJRubyCompleteArtifact, resolveJRubyStdlibArtifact
      • Methods inherited from class org.apache.maven.plugin.AbstractMojo

        getLog, getPluginContext, setLog, setPluginContext
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Field Detail

      • specSourceDirectory

        @Parameter(property="rpsec.dir",
                   defaultValue="spec")
        protected java.lang.String specSourceDirectory
        The directory containing the RSpec source files
      • skipSpecs

        @Parameter(property="skipSpecs",
                   defaultValue="false")
        protected boolean skipSpecs
        skip rspecs
    • Constructor Detail

      • RSpecMojo

        public RSpecMojo()
    • Method Detail

      • execute

        public void execute()
                     throws org.apache.maven.plugin.MojoExecutionException,
                            org.apache.maven.plugin.MojoFailureException
        Specified by:
        execute in interface org.apache.maven.plugin.Mojo
        Overrides:
        execute in class de.saumya.mojo.gem.AbstractGemMojo
        Throws:
        org.apache.maven.plugin.MojoExecutionException
        org.apache.maven.plugin.MojoFailureException
      • runIt

        protected de.saumya.mojo.tests.JRubyRun.Result runIt​(de.saumya.mojo.ruby.script.ScriptFactory factory,
                                                             de.saumya.mojo.jruby.JRubyVersion.Mode mode,
                                                             de.saumya.mojo.jruby.JRubyVersion version,
                                                             de.saumya.mojo.tests.TestScriptFactory scriptFactory)
                                                      throws java.io.IOException,
                                                             de.saumya.mojo.ruby.script.ScriptException,
                                                             org.apache.maven.plugin.MojoExecutionException
        Specified by:
        runIt in class de.saumya.mojo.tests.AbstractTestMojo
        Throws:
        java.io.IOException
        de.saumya.mojo.ruby.script.ScriptException
        org.apache.maven.plugin.MojoExecutionException
      • newTestScriptFactory

        protected de.saumya.mojo.tests.TestScriptFactory newTestScriptFactory()
        Specified by:
        newTestScriptFactory in class de.saumya.mojo.tests.AbstractTestMojo