Sha256: de3544c04a039eba2c3a376e7cc183f531632f49e1c4ad6dbeb80d444e983d24

Contents?: true

Size: 1.4 KB

Versions: 5

Compression:

Stored size: 1.4 KB

Contents

require 'rubygems'
require 'cucumber'
require 'cucumber/rake/task'
require 'spec'
require 'spec/rake/spectask'

namespace 'test' do
  UNIT_TESTS = FileList['spec/reek/**/*_spec.rb']

  Spec::Rake::SpecTask.new('spec') do |t|
    t.spec_files = UNIT_TESTS
    t.spec_opts = ['--color']
    t.ruby_opts = ['-Ilib']
    t.rcov = false
  end

  desc 'Tests various release attributes of the gem'
  Spec::Rake::SpecTask.new('gem') do |t|
    t.spec_files = FileList['spec/gem/**/*_spec.rb']
    t.rcov = false
  end

  desc 'Tests code quality'
  Spec::Rake::SpecTask.new('quality') do |t|
    t.spec_files = FileList['quality/**/*_spec.rb']
    t.spec_opts = ['--color']
    t.ruby_opts = ['-Ilib']
    t.rcov = false
  end

  desc 'Runs all unit tests under RCov'
  Spec::Rake::SpecTask.new('rcov') do |t|
    t.spec_files = UNIT_TESTS
    t.rcov = true
    t.rcov_dir = 'build/coverage'
  end

  desc 'Checks all supported versions of Ruby'
  task :multiruby do
    sh "multiruby -S rake spec"
  end

  Cucumber::Rake::Task.new(:features) do |t|
    t.cucumber_opts = "features --format progress --color"
  end

  desc 'Runs all unit tests and acceptance tests'
  task 'all' => ['test:spec', 'test:features', 'test:multiruby']

  task 'release' => ['test:gem', 'test:all']
end

task 'clobber_rcov' => 'test:clobber_rcov'

desc 'Synonym for test:spec'
task 'spec' => 'test:spec'

desc 'Synonym for test:all'
task 'test' => 'test:all'

Version data entries

5 entries across 5 versions & 1 rubygems

Version Path
reek-1.2.8 tasks/test.rake
reek-1.2.7.3 tasks/test.rake
reek-1.2.7.2 tasks/test.rake
reek-1.2.7.1 tasks/test.rake
reek-1.2.7 tasks/test.rake