diff options
author | Guillermo Iguaran <guilleiguaran@gmail.com> | 2018-04-19 22:04:39 -0500 |
---|---|---|
committer | GitHub <noreply@github.com> | 2018-04-19 22:04:39 -0500 |
commit | dc8a66aa47318b3a6aaf4014b9f118c51edb67e8 (patch) | |
tree | 0c4b6a815407cb1a8c6c1134cdb49a65d55e4d54 | |
parent | 4dc5476fbeabba2adcbaa9c24d61172fbf022bea (diff) | |
parent | 2bf11187eef95192a12077124f9a4f10305945aa (diff) | |
download | rails-dc8a66aa47318b3a6aaf4014b9f118c51edb67e8.tar.gz rails-dc8a66aa47318b3a6aaf4014b9f118c51edb67e8.tar.bz2 rails-dc8a66aa47318b3a6aaf4014b9f118c51edb67e8.zip |
Merge pull request #32649 from rails/universal-ruby-version
Create a .ruby-version compatible with MRI/JRuby by default
-rw-r--r-- | railties/lib/rails/generators/rails/app/templates/ruby-version.tt | 2 | ||||
-rw-r--r-- | railties/test/generators/app_generator_test.rb | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/railties/lib/rails/generators/rails/app/templates/ruby-version.tt b/railties/lib/rails/generators/rails/app/templates/ruby-version.tt index c444f33b0f..19f0d7f202 100644 --- a/railties/lib/rails/generators/rails/app/templates/ruby-version.tt +++ b/railties/lib/rails/generators/rails/app/templates/ruby-version.tt @@ -1 +1 @@ -<%= RUBY_VERSION -%> +<%= "#{RUBY_ENGINE}-#{RUBY_ENGINE_VERSION}" -%> diff --git a/railties/test/generators/app_generator_test.rb b/railties/test/generators/app_generator_test.rb index c3809a912b..970f0639be 100644 --- a/railties/test/generators/app_generator_test.rb +++ b/railties/test/generators/app_generator_test.rb @@ -851,7 +851,7 @@ class AppGeneratorTest < Rails::Generators::TestCase assert_match(/ruby '#{RUBY_VERSION}'/, content) end assert_file ".ruby-version" do |content| - assert_match(/#{RUBY_VERSION}/, content) + assert_match(/#{RUBY_ENGINE}-#{RUBY_ENGINE_VERSION}/, content) end end |