diff options
author | Carlhuda <carlhuda@engineyard.com> | 2010-03-04 12:12:04 -0800 |
---|---|---|
committer | Carlhuda <carlhuda@engineyard.com> | 2010-03-04 12:12:04 -0800 |
commit | 9795bf0e74612aa542404460220720c14fac1038 (patch) | |
tree | 1453fe51b6003ed28e9d459609e4b94f54674992 /railties/test | |
parent | 17769696279810c6c24a10b0d47f9b712205f0ce (diff) | |
download | rails-9795bf0e74612aa542404460220720c14fac1038.tar.gz rails-9795bf0e74612aa542404460220720c14fac1038.tar.bz2 rails-9795bf0e74612aa542404460220720c14fac1038.zip |
Fix Sam Ruby's tests and deprecation warnings
Diffstat (limited to 'railties/test')
6 files changed, 9 insertions, 9 deletions
diff --git a/railties/test/application/configuration_test.rb b/railties/test/application/configuration_test.rb index acf752a448..25389c86f7 100644 --- a/railties/test/application/configuration_test.rb +++ b/railties/test/application/configuration_test.rb @@ -177,7 +177,7 @@ module ApplicationTests require "action_controller/railtie" class MyApp < Rails::Application - config.action_controller.session = { :key => "_myapp_session", :secret => "3b7cd727ee24e8444053437c36cc66c4" } + config.action_dispatch.session = { :key => "_myapp_session", :secret => "3b7cd727ee24e8444053437c36cc66c4" } end MyApp.initialize! @@ -204,7 +204,7 @@ module ApplicationTests require "action_controller/railtie" class MyApp < Rails::Application - config.action_controller.session = { :key => "_myapp_session", :secret => "3b7cd727ee24e8444053437c36cc66c4" } + config.action_dispatch.session = { :key => "_myapp_session", :secret => "3b7cd727ee24e8444053437c36cc66c4" } config.action_dispatch.x_sendfile_header = 'X-Lighttpd-Send-File' end diff --git a/railties/test/application/initializers/frameworks_test.rb b/railties/test/application/initializers/frameworks_test.rb index 91f31df2e7..d74de3d666 100644 --- a/railties/test/application/initializers/frameworks_test.rb +++ b/railties/test/application/initializers/frameworks_test.rb @@ -65,7 +65,7 @@ module ApplicationTests test "database middleware doesn't initialize when session store is not active_record" do add_to_config <<-RUBY config.root = "#{app_path}" - config.action_controller.session_store = :cookie_store + config.action_dispatch.session_store = :cookie_store RUBY require "#{app_path}/config/environment" @@ -73,7 +73,7 @@ module ApplicationTests end test "database middleware initializes when session store is active record" do - add_to_config "config.action_controller.session_store = :active_record_store" + add_to_config "config.action_dispatch.session_store = :active_record_store" require "#{app_path}/config/environment" diff --git a/railties/test/application/middleware_stack_defaults_test.rb b/railties/test/application/middleware_stack_defaults_test.rb index 94151a90da..9086ddcfe7 100644 --- a/railties/test/application/middleware_stack_defaults_test.rb +++ b/railties/test/application/middleware_stack_defaults_test.rb @@ -10,7 +10,7 @@ class MiddlewareStackDefaultsTest < Test::Unit::TestCase Object.const_set(:MyApplication, Class.new(Rails::Application)) MyApplication.class_eval do - config.action_controller.session = { :key => "_myapp_session", :secret => "OMG A SEKRET" * 10 } + config.action_dispatch.session = { :key => "_myapp_session", :secret => "OMG A SEKRET" * 10 } end end diff --git a/railties/test/application/paths_test.rb b/railties/test/application/paths_test.rb index ac0aa27c64..89f74eb60b 100644 --- a/railties/test/application/paths_test.rb +++ b/railties/test/application/paths_test.rb @@ -11,8 +11,8 @@ module ApplicationTests app_file "config/environments/development.rb", "" add_to_config <<-RUBY config.root = "#{app_path}" - config.after_initialize do - ActionController::Base.session_store = nil + config.after_initialize do |app| + app.config.action_dispatch.session_store = nil end RUBY use_frameworks [:action_controller, :action_view, :action_mailer, :active_record] diff --git a/railties/test/application/url_generation_test.rb b/railties/test/application/url_generation_test.rb index a0d9ff7a3a..f8e9a39969 100644 --- a/railties/test/application/url_generation_test.rb +++ b/railties/test/application/url_generation_test.rb @@ -14,7 +14,7 @@ module ApplicationTests require "action_controller/railtie" class MyApp < Rails::Application - config.action_controller.session = { :key => "_myapp_session", :secret => "3b7cd727ee24e8444053437c36cc66c4" } + config.action_dispatch.session = { :key => "_myapp_session", :secret => "3b7cd727ee24e8444053437c36cc66c4" } end MyApp.initialize! diff --git a/railties/test/isolation/abstract_unit.rb b/railties/test/isolation/abstract_unit.rb index 364dbd8e55..2b0d5a8ba0 100644 --- a/railties/test/isolation/abstract_unit.rb +++ b/railties/test/isolation/abstract_unit.rb @@ -100,7 +100,7 @@ module TestHelpers end end - add_to_config 'config.action_controller.session = { :key => "_myapp_session", :secret => "bac838a849c1d5c4de2e6a50af826079" }' + add_to_config 'config.action_dispatch.session = { :key => "_myapp_session", :secret => "bac838a849c1d5c4de2e6a50af826079" }' end class Bukkit |