diff options
author | Guillermo Iguaran <guilleiguaran@gmail.com> | 2012-09-30 00:55:06 -0500 |
---|---|---|
committer | Guillermo Iguaran <guilleiguaran@gmail.com> | 2012-10-01 21:51:39 -0500 |
commit | f4a6f1d3f0d7ec2eb7a779a74f587cb953992ea8 (patch) | |
tree | 076ea0ba3c2fcd6a5944890ddca0ba7886ab886f /railties | |
parent | cbd26a803b78f7309d101fc112e40254f60262a5 (diff) | |
download | rails-f4a6f1d3f0d7ec2eb7a779a74f587cb953992ea8.tar.gz rails-f4a6f1d3f0d7ec2eb7a779a74f587cb953992ea8.tar.bz2 rails-f4a6f1d3f0d7ec2eb7a779a74f587cb953992ea8.zip |
Add rack-cache to default Gemfile
Diffstat (limited to 'railties')
-rw-r--r-- | railties/lib/rails/generators/rails/app/templates/Gemfile | 4 | ||||
-rw-r--r-- | railties/test/generators/app_generator_test.rb | 5 |
2 files changed, 9 insertions, 0 deletions
diff --git a/railties/lib/rails/generators/rails/app/templates/Gemfile b/railties/lib/rails/generators/rails/app/templates/Gemfile index 55a6b3f4f2..69027f2903 100644 --- a/railties/lib/rails/generators/rails/app/templates/Gemfile +++ b/railties/lib/rails/generators/rails/app/templates/Gemfile @@ -9,6 +9,10 @@ source 'https://rubygems.org' <%= assets_gemfile_entry %> <%= javascript_gemfile_entry %> +# Puts a simple HTTP cache in front of your app. +# For large-scale production use, consider using a caching reverse proxy like nginx, varnish, or squid. +gem 'rack-cache', '~> 1.2' + # To use ActiveModel has_secure_password # gem 'bcrypt-ruby', '~> 3.0.0' diff --git a/railties/test/generators/app_generator_test.rb b/railties/test/generators/app_generator_test.rb index 856a0e163b..7a646626c6 100644 --- a/railties/test/generators/app_generator_test.rb +++ b/railties/test/generators/app_generator_test.rb @@ -300,6 +300,11 @@ class AppGeneratorTest < Rails::Generators::TestCase assert_file "Gemfile", /# gem 'debugger'/ end + def test_inclusion_of_rack_cache + run_generator + assert_file "Gemfile", /gem 'rack-cache'/ + end + def test_template_from_dir_pwd FileUtils.cd(Rails.root) assert_match(/It works from file!/, run_generator([destination_root, "-m", "lib/template.rb"])) |