Skip to content

Commit

Permalink
Add JRuby to "rake multiruby"
Browse files Browse the repository at this point in the history
  • Loading branch information
brynary committed Jun 15, 2009
1 parent 953d35b commit b4ae28c
Showing 1 changed file with 16 additions and 7 deletions.
23 changes: 16 additions & 7 deletions Rakefile
Expand Up @@ -90,32 +90,43 @@ desc "Run everything against multiruby"
task :multiruby do
result = system "multiruby -S rake spec"
raise "Multiruby tests failed" unless result
result = system "jruby -S rake spec"
raise "JRuby tests failed" unless result

Dir.chdir "spec/integration/rails" do
result = system "multiruby -S rake test_unit:rails"
raise "Rails integration tests failed" unless result

result = system "jruby -S rake test_unit:rails"
raise "Rails integration tests failed" unless result
end

Dir.chdir "spec/integration/merb" do
result = system "multiruby -S rake spec"
raise "Merb integration tests failed" unless result

result = system "jruby -S rake spec"
raise "Rails integration tests failed" unless result
end

Dir.chdir "spec/integration/sinatra" do
result = system "multiruby -S rake test"
raise "Sinatra integration tests failed" unless result

result = system "jruby -S rake test"
raise "Sinatra integration tests failed" unless result
end

Dir.chdir "spec/integration/rack" do
result = system "multiruby -S rake test"
raise "Rack integration tests failed" unless result

result = system "jruby -S rake test"
raise "Rack integration tests failed" unless result
end
end

desc "Run specs using jruby"
task "spec:jruby" do
result = system "jruby -S rake spec"
raise "JRuby tests failed" unless result
puts
puts "Multiruby OK!"
end

desc "Run each spec in isolation to test for dependency issues"
Expand Down Expand Up @@ -183,8 +194,6 @@ end

task :default => :spec

task :precommit => ["spec", "spec:jruby", "spec:integration"]

desc 'Removes trailing whitespace'
task :whitespace do
sh %{find . -name '*.rb' -exec sed -i '' 's/ *$//g' {} \\;}
Expand Down

0 comments on commit b4ae28c

Please sign in to comment.