Sha256: 6215069c490925f8f5624c469adff174e0ae72ec73ef7d3f2356bbaf660c45d0

Contents?: true

Size: 832 Bytes

Versions: 3

Compression:

Stored size: 832 Bytes

Contents

# encoding: utf-8

begin
  require 'rspec/core/rake_task'

  desc 'Run all specs'
  RSpec::Core::RakeTask.new(:spec) do |task|
    task.pattern = 'spec/{unit,integration}{,/*/**}/*_spec.rb'
  end

  namespace :spec do
    desc 'Run unit specs'
    RSpec::Core::RakeTask.new(:unit) do |task|
      task.pattern = 'spec/unit{,/*/**}/*_spec.rb'
    end

    desc 'Run integration specs'
    RSpec::Core::RakeTask.new(:integration) do |task|
      task.pattern = 'spec/integration{,/*/**}/*_spec.rb'
    end

    desc 'Run performance specs'
    RSpec::Core::RakeTask.new(:perf) do |task|
      task.pattern = 'spec/performance{,/*/**}/*_spec.rb'
    end
  end

rescue LoadError
  %w[spec spec:unit spec:integration].each do |name|
    task name do
      $stderr.puts "In order to run #{name}, do `gem install rspec`"
    end
  end
end

Version data entries

3 entries across 3 versions & 1 rubygems

Version Path
finite_machine-0.12.1 tasks/spec.rake
finite_machine-0.12.0 tasks/spec.rake
finite_machine-0.11.3 tasks/spec.rake