RakeStep

open class RakeStep : BuildStep

A Rake build step.

Example. Adds a simple Rake build step with default Ruby interpreter settings, launching parameters and test reporting.

buildType {
// Other Build Type settings ...
steps {
// Other Build Steps ...
        rake {
name = "My Rake step"
rakefile = file {
path = "build/Rakefile"
}
tasks = "mytask:test mytask:test2"
}
}
}

Example. Adds a Rake build step with Rakefile script content and custom Rake parameters, custom Ruby interpreter settings, custom launching parameters and test reporting.

buildType {
// Other Build Type settings ...
steps {
// Other Build Steps ...
        rake {
name = "My Rake step"
workingDir = "project/"
rakefile = content {
content = """
// Rakefile content
// goes here ...
""".trimIndent()
}
tasks = "mytask:test mytask:test2"
rakeAdditionalParameters = "--trace"
rubyInterpreterMode = rvm {
rvmInterpreter = "jruby-1.4.0"
}
execBundle = false
trackInvokeExecuteStages = true
interpreterAdditionalParameters = "-J-Xmx512m"
enableTestUnit = false
enableTestSpec = true
enableShoulda = true
rspecSpecOptions = "user options"
cucumberOptions = "user options"
}
}
}

See also

Constructors

Link copied to clipboard
constructor(init: RakeStep.() -> Unit)
constructor()

Types

Link copied to clipboard

Properties

Link copied to clipboard

Optional collection of build step execution conditions

Link copied to clipboard

Rake will be invoked with a "CUCUMBER_OPTS={internal options} {user options}".

Link copied to clipboard

Whether to attach Cucumber framework results to Tests tab of the Build Results page.

Link copied to clipboard

Specifies whether the step is enabled, true by default

Link copied to clipboard

Whether to attach RSpec framework results to Tests tab of the Build Results page.

Link copied to clipboard

Whether to attach Shoulda framework results to Tests tab of the Build Results page.

Link copied to clipboard

Whether to attach Test-Spec framework results to Tests tab of the Build Results page.

Link copied to clipboard

Whether to attach Test::Unit framework results to Tests tab of the Build Results page.

Link copied to clipboard

If your project uses the Bundler requirements manager and your Rakefile doesn't load the bundler setup script, this option will allow you to launch rake tasks using the bundle exec command emulation. If you want to execute bundle install command, you need to do it in the Command Line step before the Rake step. Also, remember to set up the Ruby environment configurator build feature to automatically pass Ruby interpreter to the command line runner.

Link copied to clipboard
Link copied to clipboard
var id: String?

Optional id of the step. Usually the id is not required, however if a build configuration inherits from a template and wants to override a build step defined there, then both steps should have the same id.

Link copied to clipboard

Additional parameters for interpreter, useful for JRuby interpreters. E.g. '-J-Xmx512m'

Link copied to clipboard

Build step name

Link copied to clipboard
Link copied to clipboard

Specified parameters will be added to rake command line.

Link copied to clipboard
Link copied to clipboard

Rake will be invoked with a "SPEC_OPTS={internal options} {user options}".

Link copied to clipboard

Space-separated tasks names if you don't want to use the default task. For example, test:functionals or mytask:test mytask:test2.

Link copied to clipboard

Whether to enable showing Invoke stage data in the build log.

Link copied to clipboard

Build step type

Link copied to clipboard

Build working directory for ant script, specify it if it is different from the checkout directory.

Functions

Link copied to clipboard
fun booleanParameter(customName: String? = null, trueValue: String? = "true", falseValue: String? = "false"): DelegateProvider<Boolean?>
Link copied to clipboard
fun clear()
Link copied to clipboard

Deletes all configured build step conditions

Link copied to clipboard
fun <T : CompoundParam<T>> compoundParameter(customName: String? = null): DelegateProvider<T>
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
fun <T : Parametrized> copyParamsTo(target: T): T

Copies parameters of this object to the specified target

Link copied to clipboard
open fun create(): BuildStep

Creates an instance of this build step via reflection using a no argument constructor, used during copying. Throws an error if this class doesn't have a default constructor. Subclasses can override it to create an instance without using a default constructor.

Link copied to clipboard

Use Ruby interpreter settings defined in the Ruby environment configurator build feature settings or the interpreter will be searched in the PATH.

Link copied to clipboard
fun doubleParameter(customName: String? = null): DelegateProvider<Double>
Link copied to clipboard
fun <E : Enum<E>> enumParameter(customName: String? = null, mapping: Map<E, String?>? = null): DelegateProvider<E>
Link copied to clipboard
Link copied to clipboard
fun findRawParam(paramName: String): Parameter?
Link copied to clipboard
fun hasParam(paramName: String): Boolean
Link copied to clipboard
fun intParameter(customName: String? = null): DelegateProvider<Int>
Link copied to clipboard
fun param(name: String, value: String)

Adds parameter with specified name and value

Link copied to clipboard
Link copied to clipboard
fun removeRawParam(paramName: String)
Link copied to clipboard
Link copied to clipboard
open fun stringParameter(customName: String? = null): DelegateProvider<String>
Link copied to clipboard
open override fun toString(): String
Link copied to clipboard
open override fun validate(consumer: ErrorConsumer)

Validates this object and reports found errors to the provided consumer