diff options
Diffstat (limited to 'railties/lib')
-rw-r--r-- | railties/lib/rails/engine.rb | 4 | ||||
-rw-r--r-- | railties/lib/rails/test_help.rb | 6 |
2 files changed, 6 insertions, 4 deletions
diff --git a/railties/lib/rails/engine.rb b/railties/lib/rails/engine.rb index 83cee28fa3..db75836b8a 100644 --- a/railties/lib/rails/engine.rb +++ b/railties/lib/rails/engine.rb @@ -405,7 +405,7 @@ module Rails end end - # Finds engine with given path + # Finds engine with given path. def find(path) expanded_path = File.expand_path path Rails::Engine.subclasses.each do |klass| @@ -559,7 +559,7 @@ module Rails # and the load_once paths. # # This needs to be an initializer, since it needs to run once - # per engine and get the engine as a block parameter + # per engine and get the engine as a block parameter. initializer :set_autoload_paths, before: :bootstrap_hook do ActiveSupport::Dependencies.autoload_paths.unshift(*_all_autoload_paths) ActiveSupport::Dependencies.autoload_once_paths.unshift(*_all_autoload_once_paths) diff --git a/railties/lib/rails/test_help.rb b/railties/lib/rails/test_help.rb index 5cf44e6331..a83e39faee 100644 --- a/railties/lib/rails/test_help.rb +++ b/railties/lib/rails/test_help.rb @@ -27,13 +27,15 @@ if defined?(ActiveRecord::Base) end class ActionController::TestCase - setup do + def before_setup @routes = Rails.application.routes + super end end class ActionDispatch::IntegrationTest - setup do + def before_setup @routes = Rails.application.routes + super end end |