aboutsummaryrefslogtreecommitdiffstats
path: root/railties/test/console_app_test.rb
diff options
context:
space:
mode:
authorPratik Naik <pratiknaik@gmail.com>2009-10-10 17:15:11 +0100
committerPratik Naik <pratiknaik@gmail.com>2009-10-10 17:15:11 +0100
commit66ee2654ff243f03595a402fa15e1eea1b5b45be (patch)
tree3f1055e03082f0c767719e8cba5155e4207779e0 /railties/test/console_app_test.rb
parentdd2779e1b83b4d867d47dd286ec0c919f5df12a9 (diff)
parentb9ce8216fa849a47ad0b0f99fa510e226a23c12e (diff)
downloadrails-66ee2654ff243f03595a402fa15e1eea1b5b45be.tar.gz
rails-66ee2654ff243f03595a402fa15e1eea1b5b45be.tar.bz2
rails-66ee2654ff243f03595a402fa15e1eea1b5b45be.zip
Merge commit 'mainstream/master'
Diffstat (limited to 'railties/test/console_app_test.rb')
-rw-r--r--railties/test/console_app_test.rb43
1 files changed, 0 insertions, 43 deletions
diff --git a/railties/test/console_app_test.rb b/railties/test/console_app_test.rb
deleted file mode 100644
index 1437e6d885..0000000000
--- a/railties/test/console_app_test.rb
+++ /dev/null
@@ -1,43 +0,0 @@
-require 'abstract_unit'
-
-require 'action_controller' # console_app uses 'action_controller/integration'
-
-require 'rails/dispatcher'
-require 'rails/console_app'
-
-module Rails
- def self.application
- ActionController::Routing::Routes
- end
-end
-
-# console_app sets Test::Unit.run to work around the at_exit hook in test/unit, which kills IRB
-if Test::Unit.respond_to?(:run=)
- Test::Unit.run = false
-
- class ConsoleAppTest < Test::Unit::TestCase
- def test_app_method_should_return_integration_session
- assert_nothing_thrown do
- console_session = app
- assert_not_nil console_session
- assert_instance_of ActionController::Integration::Session,
- console_session
- end
- end
-
- def test_reload_should_fire_preparation_callbacks
- a = b = c = nil
-
- ActionDispatch::Callbacks.to_prepare { a = b = c = 1 }
- ActionDispatch::Callbacks.to_prepare { b = c = 2 }
- ActionDispatch::Callbacks.to_prepare { c = 3 }
- ActionController::Routing::Routes.expects(:reload)
-
- reload!
-
- assert_equal 1, a
- assert_equal 2, b
- assert_equal 3, c
- end
- end
-end