aboutsummaryrefslogtreecommitdiffstats
path: root/actionpack/test/activerecord
diff options
context:
space:
mode:
Diffstat (limited to 'actionpack/test/activerecord')
-rw-r--r--actionpack/test/activerecord/controller_runtime_test.rb22
-rw-r--r--actionpack/test/activerecord/polymorphic_routes_test.rb8
2 files changed, 15 insertions, 15 deletions
diff --git a/actionpack/test/activerecord/controller_runtime_test.rb b/actionpack/test/activerecord/controller_runtime_test.rb
index ed8e324938..331f861d8f 100644
--- a/actionpack/test/activerecord/controller_runtime_test.rb
+++ b/actionpack/test/activerecord/controller_runtime_test.rb
@@ -1,37 +1,37 @@
require 'active_record_unit'
require 'active_record/railties/controller_runtime'
require 'fixtures/project'
-require 'rails/subscriber/test_helper'
-require 'action_controller/railties/subscriber'
+require 'rails/log_subscriber/test_helper'
+require 'action_controller/railties/log_subscriber'
ActionController::Base.send :include, ActiveRecord::Railties::ControllerRuntime
-class ControllerRuntimeSubscriberTest < ActionController::TestCase
- class SubscriberController < ActionController::Base
+class ControllerRuntimeLogSubscriberTest < ActionController::TestCase
+ class LogSubscriberController < ActionController::Base
def show
render :inline => "<%= Project.all %>"
end
end
-
- include Rails::Subscriber::TestHelper
- tests SubscriberController
+
+ include Rails::LogSubscriber::TestHelper
+ tests LogSubscriberController
def setup
- @old_logger = ActionController::Base.logger
- Rails::Subscriber.add(:action_controller, ActionController::Railties::Subscriber.new)
super
+ @old_logger = ActionController::Base.logger
+ Rails::LogSubscriber.add(:action_controller, ActionController::Railties::LogSubscriber.new)
end
def teardown
super
- Rails::Subscriber.subscribers.clear
+ Rails::LogSubscriber.log_subscribers.clear
ActionController::Base.logger = @old_logger
end
def set_logger(logger)
ActionController::Base.logger = logger
end
-
+
def test_log_with_active_record
get :show
wait
diff --git a/actionpack/test/activerecord/polymorphic_routes_test.rb b/actionpack/test/activerecord/polymorphic_routes_test.rb
index ea82758cf5..5643ad5ad6 100644
--- a/actionpack/test/activerecord/polymorphic_routes_test.rb
+++ b/actionpack/test/activerecord/polymorphic_routes_test.rb
@@ -26,7 +26,7 @@ class Series < ActiveRecord::Base
end
class PolymorphicRoutesTest < ActionController::TestCase
- include ActionController::UrlFor
+ include SharedTestRoutes.url_helpers
self.default_url_options[:host] = 'example.com'
def setup
@@ -400,7 +400,7 @@ class PolymorphicRoutesTest < ActionController::TestCase
map.resources :series
end
- ActionController::Routing::Routes.install_helpers(self.class)
+ self.class.send(:include, @router.url_helpers)
yield
end
end
@@ -422,7 +422,7 @@ class PolymorphicRoutesTest < ActionController::TestCase
end
end
- ActionController::Routing::Routes.install_helpers(self.class)
+ self.class.send(:include, @router.url_helpers)
yield
end
end
@@ -441,7 +441,7 @@ class PolymorphicRoutesTest < ActionController::TestCase
end
end
- ActionController::Routing::Routes.install_helpers(self.class)
+ self.class.send(:include, @router.url_helpers)
yield
end
end