Skip to content

Commit

Permalink
Trying to get the test suite running... -_-
Browse files Browse the repository at this point in the history
  • Loading branch information
jdurand committed Apr 17, 2015
1 parent 57da320 commit 9d387b7
Showing 1 changed file with 17 additions and 16 deletions.
33 changes: 17 additions & 16 deletions Rakefile
Expand Up @@ -34,28 +34,29 @@ namespace :spec do
%w(active_record_32 active_record_40 active_record_41 active_record_42 will_paginate data_mapper).each do |gemfile|
desc "Run Tests against #{gemfile}"
task "#{gemfile}" do
Dir.chdir("test_apps/#{gemfile}")
puts "Testing in #{`pwd`}"
sh "bundle install --quiet"
sh "bundle update --quiet"
Dir.chdir("test_apps/#{gemfile}") do
puts "Testing in #{`pwd`}"
sh "bundle install --quiet"
sh "bundle update --quiet"

# Drop migrations and recreate
sh "rm -rf db/migrate/*"
# Drop migrations and recreate
sh "rm -rf db/migrate/*"

if gemfile != "data_mapper"
sh "bundle exec rake railties:install:migrations > /dev/null"
end
if gemfile != "data_mapper"
sh "bundle exec rake railties:install:migrations > /dev/null"
end

if gemfile == "active_record_32"
sh "bundle exec rake db:drop db:create db:migrate --quiet > /dev/null"
end
if gemfile == "active_record_32"
sh "bundle exec rake db:drop db:create db:migrate --quiet > /dev/null"
end

sh "RAILS_ENV=test bundle exec rake db:drop db:create db:migrate --quiet > /dev/null"
sh "RAILS_ENV=test bundle exec rake db:drop db:create db:migrate --quiet > /dev/null"

update_files
update_files

# Run tests
sh "bundle exec rake"
# Run tests
sh "bundle exec rake"
end
end
end

Expand Down

0 comments on commit 9d387b7

Please sign in to comment.