aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--railties/lib/rails.rb3
-rw-r--r--railties/lib/rails/info_controller.rb2
-rw-r--r--railties/lib/rails/info_routes.rb2
-rw-r--r--railties/lib/rails/tasks/misc.rake1
-rw-r--r--railties/test/rails_info_controller_test.rb3
5 files changed, 3 insertions, 8 deletions
diff --git a/railties/lib/rails.rb b/railties/lib/rails.rb
index 3d3151bd8f..9d02da104d 100644
--- a/railties/lib/rails.rb
+++ b/railties/lib/rails.rb
@@ -26,6 +26,9 @@ else
end
module Rails
+ autoload :Info, 'rails/info'
+ autoload :InfoController, 'rails/info_controller'
+
class << self
def application
@@application ||= nil
diff --git a/railties/lib/rails/info_controller.rb b/railties/lib/rails/info_controller.rb
index 18f13dc095..196eeb4a6c 100644
--- a/railties/lib/rails/info_controller.rb
+++ b/railties/lib/rails/info_controller.rb
@@ -1,5 +1,3 @@
-require 'rails/info'
-
class Rails::InfoController < ActionController::Base
def properties
if consider_all_requests_local? || local_request?
diff --git a/railties/lib/rails/info_routes.rb b/railties/lib/rails/info_routes.rb
index 2e4157ea8d..bd58034d8f 100644
--- a/railties/lib/rails/info_routes.rb
+++ b/railties/lib/rails/info_routes.rb
@@ -1,5 +1,3 @@
-require 'rails/info_controller'
-
Rails.application.routes.draw do |map|
match '/rails/info/properties' => "rails/info#properties"
end
diff --git a/railties/lib/rails/tasks/misc.rake b/railties/lib/rails/tasks/misc.rake
index 2309c91d83..0926707a04 100644
--- a/railties/lib/rails/tasks/misc.rake
+++ b/railties/lib/rails/tasks/misc.rake
@@ -15,7 +15,6 @@ end
desc 'Explain the current environment'
task :about do
- require 'rails/info'
puts Rails::Info
end
diff --git a/railties/test/rails_info_controller_test.rb b/railties/test/rails_info_controller_test.rb
index d904d7b461..05ec359f61 100644
--- a/railties/test/rails_info_controller_test.rb
+++ b/railties/test/rails_info_controller_test.rb
@@ -1,9 +1,6 @@
require 'abstract_unit'
require 'action_controller'
-require 'rails/info'
-require 'rails/info_controller'
-
module ActionController
class Base
include ActionController::Testing