diff --git a/Gemfile.rails_version b/Gemfile.rails_version index 1e2eb44f..96a5e15f 100644 --- a/Gemfile.rails_version +++ b/Gemfile.rails_version @@ -7,8 +7,12 @@ if ENV['RAILS_VERSION'] gem 'rails', '~> 3.0.10' when /3.1$/ gem 'rails', '~> 3.1.0' + # A JS runtime is required for Rails 3.1+ + gem 'therubyracer' when /3.2$/ gem 'rails', '~> 3.2.0' + # A JS runtime is required for Rails 3.1+ + gem 'therubyracer' else fail "Unknown Rails version #{ENV['RAILS_VERSION']}" end diff --git a/Rakefile b/Rakefile index 96473d60..6170688d 100644 --- a/Rakefile +++ b/Rakefile @@ -44,9 +44,6 @@ namespace :testbed do chdir('testbed') do gem_file_contents = File.read('Gemfile') gem_file_contents.sub!(/^(gem 'rails'.*)$/, %Q{# \\1\nplugin_root = File.expand_path('../..', __FILE__)\neval(File.read File.join(plugin_root, 'Gemfile.rails_version'))\ngem 'surveyor', :path => plugin_root}) - if ENV['CI_RUBY'] && ENV['RAILS_VERSION'] =~ /3.1$/ - gem_file_contents << %Q(\ngem 'therubyracer') - end File.open('Gemfile', 'w'){|f| f.write(gem_file_contents) } Bundler.with_clean_env do