Skip to content
Browse files

Added therubyrhino to default Gemfile under JRuby

  • Loading branch information...
1 parent df300a7 commit 49cd6a0ff7a3f5b0e85707961c952bdc3b0a178f @guilleiguaran guilleiguaran committed Nov 14, 2011
Showing with 8 additions and 0 deletions.
  1. +1 −0 railties/lib/rails/generators/app_base.rb
  2. +7 −0 railties/test/generators/app_generator_test.rb
View
1 railties/lib/rails/generators/app_base.rb
@@ -199,6 +199,7 @@ def assets_gemfile_entry
group :assets do
gem 'sass-rails', :git => 'git://github.com/rails/sass-rails.git'
gem 'coffee-rails', :git => 'git://github.com/rails/coffee-rails.git'
+ #{"gem 'therubyrhino'\n" if defined?(JRUBY_VERSION)}
gem 'uglifier', '>= 1.0.3'
end
GEMFILE
View
7 railties/test/generators/app_generator_test.rb
@@ -208,6 +208,13 @@ def test_generator_if_skip_sprockets_is_given
assert_file "test/performance/browsing_test.rb"
end
+ def test_inclusion_of_therubyrhino_under_jruby
+ if defined?(JRUBY_VERSION)
@splattael
splattael added a note Nov 14, 2011

This produces an empty test for non-jruby, right?
Maybe one should test the absence of therubyrhino when using non-jruby.

@josevalim
Ruby on Rails member
josevalim added a note Nov 14, 2011

Good call.

@guilleiguaran
Ruby on Rails member

Thanks, I will send another pull request to complete it tomorrow

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
+ run_generator([destination_root])
+ assert_file "Gemfile", /gem\s+["']therubyrhino["']$/
+ end
+ end
+
def test_creation_of_a_test_directory
run_generator
assert_file 'test'

0 comments on commit 49cd6a0

Please sign in to comment.
Something went wrong with that request. Please try again.