Skip to content
Henrik edited this page Aug 21, 2014 · 1 revision

Run tests written with the MSpec test framework.

desc "Run all of the solution's specs"
mspec :test => [:build] do |cmd|
  cmd.command = "path/to/mspec"
  cmd.assemblies = FileList["wildcard/path/to/assemblies"]
  cmd.results_path = {:html => "path/to/results"}
end

Required Parameters

Command

The location of the mspec console runner.

command = "path/to/mspec"

Assemblies

You must provide at least one assembly for mspec to run, but this property accepts an array or a Rake FileList

assemblies = FileList["wildcard/path/to/assemblies"]

Optional Parameters

Results Path

The path to the formatted test run report, supports: :xml & :html

results_path = {:html => "path/to/results"}

Guidance

Other mspec command-line runner switches can be provided via the parameters general property

parameters = ["--teamcity"]
Clone this wiki locally