foodcritic-rackspace-rules 1.0.1 → 1.0.2

Sign up to get free protection for your applications and to get access to all the features.
@@ -1,7 +1,7 @@
1
1
  module Foodcritic
2
2
  module Rackspace
3
3
  module Rules
4
- VERSION = "1.0.1"
4
+ VERSION = "1.0.2"
5
5
  end
6
6
  end
7
7
  end
@@ -68,4 +68,23 @@ rule 'RACK002', 'Recipe contains a single include_recipe' do
68
68
  end # cookbook
69
69
  end # rule
70
70
 
71
+ rule 'RACK003', 'Cookbook is missing a standard file' do
72
+ tags %w(style rackspace)
71
73
 
74
+ expected_files = %w(README.md metadata.rb LICENSE Gemfile Berksfile Rakefile Thorfile Guardfile .kitchen.yml .rubocop.yml )
75
+
76
+ cookbook do |path|
77
+ matches = []
78
+ expected_files.each do |f|
79
+ next unless !File.exist?("#{path}/#{f}")
80
+
81
+ matches << {
82
+ :filename => "#{f}",
83
+ :matched => 'missing',
84
+ :line => 0,
85
+ :column => 0
86
+ }
87
+ end
88
+ matches
89
+ end # cookbook
90
+ end # rule
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: foodcritic-rackspace-rules
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.0.1
4
+ version: 1.0.2
5
5
  prerelease:
6
6
  platform: ruby
7
7
  authors: