diff options
-rw-r--r-- | railties/lib/rails/generators/app_base.rb | 1 | ||||
-rw-r--r-- | railties/test/generators/app_generator_test.rb | 5 |
2 files changed, 6 insertions, 0 deletions
diff --git a/railties/lib/rails/generators/app_base.rb b/railties/lib/rails/generators/app_base.rb index 3fbde0d989..e3d22e81fb 100644 --- a/railties/lib/rails/generators/app_base.rb +++ b/railties/lib/rails/generators/app_base.rb @@ -193,6 +193,7 @@ module Rails end def assets_gemfile_entry + return if options[:skip_sprockets] <<-GEMFILE.strip_heredoc # Gems used only for assets and not required # in production environments by default. diff --git a/railties/test/generators/app_generator_test.rb b/railties/test/generators/app_generator_test.rb index baa80419a6..0e2990affd 100644 --- a/railties/test/generators/app_generator_test.rb +++ b/railties/test/generators/app_generator_test.rb @@ -206,6 +206,11 @@ class AppGeneratorTest < Rails::Generators::TestCase assert_match(/#\s+require\s+["']sprockets\/railtie["']/, content) assert_no_match(/config\.assets\.enabled = true/, content) end + assert_file "Gemfile" do |content| + assert_no_match(/sass-rails/, content) + assert_no_match(/coffee-rails/, content) + assert_no_match(/uglifier/, content) + end assert_file "test/performance/browsing_test.rb" end |