Sha256: d4ed6634c7c9aded8d0effa820e91be4cf81455b9d1b12de4edf50c5ea735dcb

Contents?: true

Size: 1.23 KB

Versions: 3

Compression:

Stored size: 1.23 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

  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']
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

3 entries across 3 versions & 1 rubygems

Version Path
reek-1.2.12 tasks/test.rake
reek-1.2.11 tasks/test.rake
reek-1.2.10 tasks/test.rake