aboutsummaryrefslogtreecommitdiffstats
path: root/railties/test/application/configuration_test.rb
diff options
context:
space:
mode:
Diffstat (limited to 'railties/test/application/configuration_test.rb')
-rw-r--r--railties/test/application/configuration_test.rb16
1 files changed, 16 insertions, 0 deletions
diff --git a/railties/test/application/configuration_test.rb b/railties/test/application/configuration_test.rb
index 4d9da525d7..ece41f9de8 100644
--- a/railties/test/application/configuration_test.rb
+++ b/railties/test/application/configuration_test.rb
@@ -83,5 +83,21 @@ module ApplicationTests
require "#{app_path}/config/application"
end
end
+
+ test "Frameworks are not preloaded by default" do
+ require "#{app_path}/config/environment"
+
+ assert ActionController.autoload?(:RecordIdentifier)
+ end
+
+ test "frameworks are preloaded with config.preload_frameworks is set" do
+ add_to_config <<-RUBY
+ config.preload_frameworks = true
+ RUBY
+
+ require "#{app_path}/config/environment"
+
+ assert !ActionController.autoload?(:RecordIdentifier)
+ end
end
end