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.
This commit is contained in:
Rafael Mendonça França 2013-12-05 16:25:30 -02:00
parent 53fc2f89f6
commit ff08d31e2e

@ -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