OSDN Git Service

adds the Debian 9 (stretch) support.
[metasearch/grid-chef-repo.git] / cookbooks / docker-grid / Rakefile
1 require 'rspec/core/rake_task'
2 require 'rubocop/rake_task'
3 require 'foodcritic'
4 require 'stove/rake_task'
5
6 namespace :style do
7   desc 'Run Ruby style checks'
8   RuboCop::RakeTask.new(:ruby) do |t|
9     t.options = [
10       '--auto-gen-config',  # creates .rubocop_todo.yml
11     ]
12   end
13
14   desc 'Run Chef style checks'
15   FoodCritic::Rake::LintTask.new(:chef) do |t|
16     t.options = {
17       fail_tags: ['any'],
18     }
19   end
20 end
21
22 desc 'Run all style checks'
23 task style: ['style:chef', 'style:ruby']
24
25 desc 'Run ChefSpec examples'
26 RSpec::Core::RakeTask.new(:spec)
27
28 desc 'Publish cookbook'
29 Stove::RakeTask.new(:publish) do |t|
30   t.stove_opts = [
31     '--no-git',
32     '--log-level', 'info',
33   ]
34 end
35
36 task default: ['style', 'spec']