Sha256: 927db361c6fee1defbdfd4cbc74e006dd72b1ee12257294f574014639dea5717

Contents?: true

Size: 1.26 KB

Versions: 8

Compression:

Stored size: 1.26 KB

Contents

require "bundler/gem_tasks"
require "rspec/core/rake_task"

[:unit, :functional].each do |type|
  RSpec::Core::RakeTask.new(type) do |t|
    t.pattern = "spec/#{type}/**/*_spec.rb"
    t.rspec_opts = [].tap do |a|
      a.push("--color")
      a.push("--format progress")
    end.join(" ")
  end
end

begin
  require "chefstyle"
  require "rubocop/rake_task"
  RuboCop::RakeTask.new(:style) do |task|
    task.options += ["--display-cop-names", "--no-color"]
  end
rescue LoadError
  puts "chefstyle gem is not installed"
end

desc "Render product matrix documentation"
task "matrix" do
  require "mixlib/install/product_matrix"

  doc_file = File.join(File.dirname(__FILE__), "PRODUCT_MATRIX.md")
  puts "Updating doc file at: #{doc_file}"

  File.open(doc_file, "w+") do |f|
    f.puts("| Product | Product Key  |")
    f.puts("| ------- | ------------ |")
    PRODUCT_MATRIX.products.sort.each do |p_key|
      product = PRODUCT_MATRIX.lookup(p_key)
      f.puts("| #{product.product_name} | #{p_key} |")
    end
    f.puts("")
    f.puts("Do not modify this file manually. It is automatically rendered via a rake task.")
  end
end

task :console do
  require "irb"
  require "irb/completion"
  require "mixlib/install"
  ARGV.clear
  IRB.start
end

task default: %w{unit functional}

Version data entries

8 entries across 8 versions & 1 rubygems

Version Path
mixlib-install-3.12.30 Rakefile
mixlib-install-3.12.29 Rakefile
mixlib-install-3.12.28 Rakefile
mixlib-install-3.12.27 Rakefile
mixlib-install-3.12.24 Rakefile
mixlib-install-3.12.23 Rakefile
mixlib-install-3.12.20 Rakefile
mixlib-install-3.12.19 Rakefile