Created
March 27, 2012 18:20
-
-
Save jumph4x/2218672 to your computer and use it in GitHub Desktop.
Depending on a third-party Spree Extension and including relevant migrations while generating a dummy application for testing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
desc "Generates a dummy app for testing" | |
task :test_app do | |
ENV['LIB_NAME'] = 'spree_google_base' | |
puts 'Installing spree-multi-domain migrations [required for testing]' | |
dep_path = `bundle show spree_multi_domain`.chomp | |
migration_path = File.join(dep_path,'db','migrate') | |
dummy_path = File.join(FileUtils.pwd, 'spec', 'dummy', 'db') | |
FileUtils.mkdir_p(dummy_path) | |
FileUtils.cp_r(migration_path, dummy_path) | |
Rake::Task['common:test_app'].invoke | |
end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment