Skip to content

Commit

Permalink
Run db:test:prepare rake task from spec/dummy in init_test_database t…
Browse files Browse the repository at this point in the history
…ask.
  • Loading branch information
ugisozols authored and parndt committed Aug 29, 2012
1 parent ffaa72d commit adfba25
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions testing/lib/refinery/tasks/testing.rake
Expand Up @@ -22,7 +22,7 @@ namespace :refinery do

Refinery::CmsGenerator.start %w[--quiet --fresh-installation]

Dir.chdir Refinery::Testing::Railtie.target_extension_path
Dir.chdir dummy_app_path
end

# This task is a hook to allow extensions to pass configuration
Expand Down Expand Up @@ -53,8 +53,7 @@ namespace :refinery do
end

task :init_test_database do
load 'rails/tasks/engine.rake'
Rake::Task['app:db:test:prepare'].invoke
system "bundle exec rake -f #{dummy_app_path.join('Rakefile')} db:test:prepare"
end

def dummy_app_path
Expand Down

0 comments on commit adfba25

Please sign in to comment.