aboutsummaryrefslogtreecommitdiffstats
path: root/railties
diff options
context:
space:
mode:
authorRafael Mendonça França <rafaelmfranca@gmail.com>2013-12-05 16:25:30 -0200
committerRafael Mendonça França <rafaelmfranca@gmail.com>2013-12-05 16:25:30 -0200
commitff08d31e2e7d3f8d79d0d987d698d753a01ebc47 (patch)
treeb3e810c6a8a3f81ec791b1ad8f062abb9de0d45e /railties
parent53fc2f89f6b06384ac4bb9c52ff2f74f8161a413 (diff)
downloadrails-ff08d31e2e7d3f8d79d0d987d698d753a01ebc47.tar.gz
rails-ff08d31e2e7d3f8d79d0d987d698d753a01ebc47.tar.bz2
rails-ff08d31e2e7d3f8d79d0d987d698d753a01ebc47.zip
Add tests to cache_template_loading when an engine loaded Action View
before the application This test is a regression test to b068e20b35797aa6deaa377a48c990759734f515 that changed the load order of Action View initializers.
Diffstat (limited to 'railties')
-rw-r--r--railties/test/application/configuration_test.rb14
1 files changed, 14 insertions, 0 deletions
diff --git a/railties/test/application/configuration_test.rb b/railties/test/application/configuration_test.rb
index 722c940d8e..a8443dcb88 100644
--- a/railties/test/application/configuration_test.rb
+++ b/railties/test/application/configuration_test.rb
@@ -527,6 +527,20 @@ module ApplicationTests
assert ActionView::Resolver.caching?
end
+ test "config.action_view.cache_template_loading with cache_classes in an environment" do
+ build_app(initializers: true)
+ add_to_env_config "development", "config.cache_classes = false"
+
+ # These requires are to emulate an engine loading Action View before the application
+ require 'action_view'
+ require 'action_view/railtie'
+ require 'action_view/base'
+
+ require "#{app_path}/config/environment"
+
+ assert_equal false, ActionView::Resolver.caching?
+ end
+
test "config.action_dispatch.show_exceptions is sent in env" do
make_basic_app do |app|
app.config.action_dispatch.show_exceptions = true