Permalink
Browse files

Merge pull request #27 from oneacross/master

Fix Rakefile to use the new rspec API
  • Loading branch information...
NateBarnes committed Apr 25, 2012
2 parents 32ac2de + 3facc06 commit 26877449253b9f258db541e42283bf82b62ae7e8
Showing with 6 additions and 9 deletions.
  1. +6 −9 Rakefile
View
@@ -60,22 +60,19 @@ Rake::RDocTask.new do |rdoc|
end
-if defined?(Spec)
+if defined?(RSpec)
desc 'Test the govkit plugin.'
- Spec::Rake::SpecTask.new('spec') do |t|
- t.spec_files = FileList['spec/**/*_spec.rb']
- t.spec_opts = ["-c"]
+ RSpec::Core::RakeTask.new('spec') do |t|
+ t.rspec_opts = ["-c"]
end
desc 'Test the govkit plugin with specdoc formatting and colors'
- Spec::Rake::SpecTask.new('specdoc') do |t|
- t.spec_files = FileList['spec/**/*_spec.rb']
- t.spec_opts = ["--format specdoc", "-c"]
+ RSpec::Core::RakeTask.new('specdoc') do |t|
+ t.rspec_opts = ["--format specdoc", "-c"]
end
desc "Run all examples with RCov"
- Spec::Rake::SpecTask.new('examples_with_rcov') do |t|
- t.spec_files = FileList['spec/**/*_spec.rb']
+ RSpec::Core::RakeTask.new('examples_with_rcov') do |t|
t.rcov = true
t.rcov_opts = ['--exclude', 'spec,Library']
end

0 comments on commit 2687744

Please sign in to comment.