Rakefile in rack-oauth2-server-2.2.0 vs Rakefile in rack-oauth2-server-2.2.1
- old
+ new
@@ -1,9 +1,19 @@
require "rake/testtask"
spec = Gem::Specification.load(Dir["*.gemspec"].first)
+desc "Install dependencies"
+task :setup do
+ puts "Installing gems for testing with Sinatra ..."
+ sh "bundle install"
+ puts "Installing gems for testing with Rails 2.3 ..."
+ sh "env BUNDLE_GEMFILE=Rails2 bundle install"
+ puts "Installing gems for testing with Rails 3.x ..."
+ sh "env BUNDLE_GEMFILE=Rails3 bundle install"
+end
+
desc "Run this in development mode when updating the CoffeeScript file"
task :coffee do
sh "coffee -w -o lib/rack/oauth2/admin/js/ lib/rack/oauth2/admin/js/application.coffee"
end
@@ -44,11 +54,10 @@
task.verbose = true
end
task.ruby_opts << "-I."
end
-RUBIES = %w{1.8.7 1.9.2}
namespace :test do
task :all=>["test:sinatra", "test:rails2", "test:rails3"]
desc "Run all tests against Sinatra"
task :sinatra do
sh "rake test FRAMEWORK=sinatra"
@@ -63,19 +72,10 @@
end
desc "Run all tests against Rails 3.x"
task :rails3 do
sh "env BUNDLE_GEMFILE=Rails3 bundle exec rake test FRAMEWORK=rails"
end
-
- desc "Test in all supported RVMs"
- task :rubies do
- RUBIES.each do |ruby|
- puts "*** #{ruby} ***"
- sh "rvm #{ruby}@rack-oauth2-server rake test:all"
- puts
- end
- end
end
task :default=>"test:all"
begin
require "yard"
@@ -83,8 +83,8 @@
doc.files = FileList["lib/**/*.rb"]
end
rescue LoadError
end
-task :clobber do
+task :clean do
rm_rf %w{doc .yardoc *.gem}
end