Sha256: a7297ef7c6943d4e082a10167bcef6e580950eae36c5cebe26b07c33d43bc199

Contents?: true

Size: 1.14 KB

Versions: 5

Compression:

Stored size: 1.14 KB

Contents

require 'rake/testtask'
require "bundler/gem_tasks"
load 'tasks/jenkins.rake'

Rake::TestTask.new('test:ruby') do |t|
  t.libs << 'lib' << 'test'
  t.test_files = FileList['test/**/*_test.rb'] - FileList['test/tmp/**/*_test.rb']
  t.verbose = true
end

Rake::TestTask.new('test:unit') do |t|
  t.libs << 'lib' << 'test'
  t.test_files = FileList['test/kafo/**/*_test.rb']
  t.verbose = true
end

Rake::TestTask.new('test:acceptance') do |t|
  t.libs << 'lib' << 'test'
  t.test_files = FileList['test/acceptance/*_test.rb']
  t.verbose = true
end

namespace 'test' do
  desc 'Run Puppet module tests'
  task :puppet_modules do
    Dir['modules/*'].each do |mod|
      Dir.chdir(mod) do
        `rake release_checks`
      end
    end
  end
end

require 'rubocop/rake_task'
RuboCop::RakeTask.new(:rubocop) do |task|
  # These make the rubocop experience maybe slightly less terrible
  task.options = ['--display-cop-names', '--display-style-guide', '--extra-details']
  # Use Rubocop's Github Actions formatter if possible
  task.formatters << 'github' if ENV['GITHUB_ACTIONS'] == 'true'
end

CLEAN.include 'test/tmp'

task :test => ['test:ruby', 'test:puppet_modules']

Version data entries

5 entries across 5 versions & 1 rubygems

Version Path
kafo-7.6.0 Rakefile
kafo-7.5.1 Rakefile
kafo-7.5.0 Rakefile
kafo-7.4.0 Rakefile
kafo-7.3.0 Rakefile