summaryrefslogtreecommitdiff
path: root/files/puppet/modules/pixelated/Rakefile
diff options
context:
space:
mode:
authorvarac <varacanero@zeromail.org>2016-09-06 13:59:05 +0200
committervarac <varacanero@zeromail.org>2016-09-06 13:59:05 +0200
commit5fbd43d5a948ac7773955a26c1d0cb0db42252d9 (patch)
treed1f9b2d6b2ad015fec1f53256887b39838748d5f /files/puppet/modules/pixelated/Rakefile
parentcb6740619fe003b4a1956a413844a1a2bfa4b9de (diff)
git subrepo clone https://github.com/pixelated/puppet-pixelated.git files/puppet/modules/pixelated
subrepo: subdir: "files/puppet/modules/pixelated" merged: "6086b94" upstream: origin: "https://github.com/pixelated/puppet-pixelated.git" branch: "master" commit: "6086b94" git-subrepo: version: "0.3.0" origin: "https://github.com/ingydotnet/git-subrepo.git" commit: "1e79595"
Diffstat (limited to 'files/puppet/modules/pixelated/Rakefile')
-rw-r--r--files/puppet/modules/pixelated/Rakefile20
1 files changed, 20 insertions, 0 deletions
diff --git a/files/puppet/modules/pixelated/Rakefile b/files/puppet/modules/pixelated/Rakefile
new file mode 100644
index 0000000..7fb499f
--- /dev/null
+++ b/files/puppet/modules/pixelated/Rakefile
@@ -0,0 +1,20 @@
+require 'puppetlabs_spec_helper/rake_tasks'
+require 'puppet-lint/tasks/puppet-lint'
+PuppetLint.configuration.send('disable_80chars')
+PuppetLint.configuration.send('disable_fileserver')
+PuppetLint.configuration.ignore_paths = ["spec/**/*.pp", "pkg/**/*.pp"]
+
+desc "Validate manifests, templates, and ruby files"
+task :validate do
+ Dir['manifests/**/*.pp'].each do |manifest|
+ sh "puppet parser validate --noop #{manifest}"
+ end
+ Dir['spec/**/*.rb','lib/**/*.rb'].each do |ruby_file|
+ sh "ruby -c #{ruby_file}" unless ruby_file =~ /spec\/fixtures/
+ end
+ Dir['templates/**/*.erb'].each do |template|
+ sh "erb -P -x -T '-' #{template} | ruby -c"
+ end
+end
+
+task :test => [:lint, :syntax , :validate, :spec]