diff options
author | Dan Bode <dan@puppetlabs.com> | 2011-11-14 22:24:01 -0800 |
---|---|---|
committer | Dan Bode <dan@puppetlabs.com> | 2011-11-16 08:45:47 -0800 |
commit | f52e93ceb161222022c0cf3b67c745521a54dd45 (patch) | |
tree | 66df7da8471d4a3c57283c48a9d5a9a3fdfabc4c /Rakefile | |
parent | baae368767b386cbc3e9b2d3fba7c4ea47db081a (diff) |
(#10846) add spec tests for ntp class
This commit adds some unit tests for the
ntp class.
Also adds a rakefile for running the spec tests
Diffstat (limited to 'Rakefile')
-rw-r--r-- | Rakefile | 22 |
1 files changed, 22 insertions, 0 deletions
diff --git a/Rakefile b/Rakefile new file mode 100644 index 0000000..cac9471 --- /dev/null +++ b/Rakefile @@ -0,0 +1,22 @@ +require 'rake' +require 'rspec/core/rake_task' + +task :default do + sh %{rake -T} +end + +# Aliases for spec. The (s) versions are used by rvm specs/tests. +task :test => [:spec] +task :tests => [:spec] +task :specs => [:spec] + +desc 'Run all RSpec tests' +RSpec::Core::RakeTask.new(:spec) do |t| + t.rspec_opts = ['--color'] +end + +desc 'Generate code coverage' +RSpec::Core::RakeTask.new(:coverage) do |t| + t.rcov = true + t.rcov_opts = ['--exclude', 'spec'] +end |