Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

Add tests to cache_template_loading when an engine loaded Action View

before the application

This test is a regression test to
b068e20 that changed the load order of
Action View initializers.
  • Loading branch information...
commit ff08d31e2e7d3f8d79d0d987d698d753a01ebc47 1 parent 53fc2f8
@rafaelfranca rafaelfranca authored
Showing with 14 additions and 0 deletions.
  1. +14 −0 railties/test/application/configuration_test.rb
View
14 railties/test/application/configuration_test.rb
@@ -527,6 +527,20 @@ def index
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
Please sign in to comment.
Something went wrong with that request. Please try again.