-
Notifications
You must be signed in to change notification settings - Fork 6
/
Rakefile
41 lines (36 loc) · 1.23 KB
/
Rakefile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
require 'puppetlabs_spec_helper/rake_tasks'
require 'rubocop/rake_task'
RuboCop::RakeTask.new(:rubocop) do |task|
# These make the rubocop experience maybe slightly less terrible
task.options = ['-D', '-S', '-E', '-d']
end
PuppetLint.configuration.log_format = '%{path}:%{line} - %{KIND}: %{check}: %{message}'
PuppetLint.configuration.fail_on_warnings = true
PuppetLint.configuration.with_context = true
PuppetLint.configuration.send('relative')
PuppetLint.configuration.send('disable_140chars')
PuppetLint.configuration.send('disable_class_inherits_from_params_class')
PuppetLint.configuration.send('disable_documentation')
# PuppetLint.configuration.send('disable_variable_scope')
PuppetLint.configuration.send('disable_single_quote_string_with_variables')
PuppetLint.configuration.send('disable_puppet_url_without_modules')
exclude_paths = [
'pkg/**/*',
'vendor/**/*',
'.vendor/**/*',
'spec/**/*',
]
PuppetLint.configuration.ignore_paths = exclude_paths
PuppetSyntax.exclude_paths = exclude_paths
desc 'Run acceptance tests'
RSpec::Core::RakeTask.new(:acceptance) do |t|
t.pattern = 'spec/acceptance'
end
desc 'Run metadata_lint, lint, syntax, and spec tests'
task test: [
:metadata_lint,
:lint,
:rubocop,
:syntax,
:spec,
]