Rakefile in memento-0.3.0 vs Rakefile in memento-0.3.1
- old
+ new
@@ -1,8 +1,20 @@
require 'rubygems'
require 'rake'
+require "rspec/core/rake_task"
+RSpec::Core::RakeTask.new(:spec) do |spec|
+ spec.pattern = 'spec/**/*_spec.rb'
+end
+
+RSpec::Core::RakeTask.new(:rcov) do |spec|
+ spec.pattern = 'spec/**/*_spec.rb'
+ spec.rcov = true
+end
+
+task :default => :spec
+
begin
require 'jeweler'
Jeweler::Tasks.new do |gem|
gem.name = "memento"
gem.summary = %Q{Undo for Rails/ActiveRecord - covers destroy, update and create}
@@ -14,20 +26,6 @@
end
Jeweler::GemcutterTasks.new
rescue LoadError
puts "Jeweler not available. Install it with: sudo gem install technicalpickles-jeweler -s http://gems.github.com"
end
-
-require 'spec/rake/spectask'
-Spec::Rake::SpecTask.new(:spec) do |spec|
- spec.libs << 'lib' << 'spec'
- spec.spec_files = FileList['spec/**/*_spec.rb']
-end
-
-Spec::Rake::SpecTask.new(:rcov) do |spec|
- spec.libs << 'lib' << 'spec'
- spec.pattern = 'spec/**/*_spec.rb'
- spec.rcov = true
-end
-
-task :default => :spec