diff options
Diffstat (limited to 'actionpack/test/controller')
-rw-r--r-- | actionpack/test/controller/base_test.rb | 2 | ||||
-rw-r--r-- | actionpack/test/controller/filters_test.rb | 7 | ||||
-rw-r--r-- | actionpack/test/controller/new_base/render_streaming_test.rb | 4 | ||||
-rw-r--r-- | actionpack/test/controller/rescue_test.rb | 5 |
4 files changed, 10 insertions, 8 deletions
diff --git a/actionpack/test/controller/base_test.rb b/actionpack/test/controller/base_test.rb index 2d4083252e..2032aca52e 100644 --- a/actionpack/test/controller/base_test.rb +++ b/actionpack/test/controller/base_test.rb @@ -45,7 +45,7 @@ class DefaultUrlOptionsController < ActionController::Base render :inline => "<%= #{params[:route]} %>" end - def default_url_options(options = nil) + def default_url_options { :host => 'www.override.com', :action => 'new', :locale => 'en' } end end diff --git a/actionpack/test/controller/filters_test.rb b/actionpack/test/controller/filters_test.rb index 65c853f6eb..ef7fbca675 100644 --- a/actionpack/test/controller/filters_test.rb +++ b/actionpack/test/controller/filters_test.rb @@ -510,6 +510,13 @@ class FilterTest < ActionController::TestCase end end + def test_sweeper_should_not_ignore_no_method_error + sweeper = ActionController::Caching::Sweeper.send(:new) + assert_raise NoMethodError do + sweeper.send_not_defined + end + end + def test_sweeper_should_not_block_rendering response = test_process(SweeperTestController) assert_equal 'hello world', response.body diff --git a/actionpack/test/controller/new_base/render_streaming_test.rb b/actionpack/test/controller/new_base/render_streaming_test.rb index 61ea68e3f7..bfca8c5c24 100644 --- a/actionpack/test/controller/new_base/render_streaming_test.rb +++ b/actionpack/test/controller/new_base/render_streaming_test.rb @@ -73,13 +73,13 @@ module RenderStreaming test "rendering with layout exception" do get "/render_streaming/basic/layout_exception" - assert_body "d\r\n<body class=\"\r\n4e\r\n\"><script type=\"text/javascript\">window.location = \"/500.html\"</script></html>\r\n0\r\n\r\n" + assert_body "d\r\n<body class=\"\r\n37\r\n\"><script>window.location = \"/500.html\"</script></html>\r\n0\r\n\r\n" assert_streaming! end test "rendering with template exception" do get "/render_streaming/basic/template_exception" - assert_body "4e\r\n\"><script type=\"text/javascript\">window.location = \"/500.html\"</script></html>\r\n0\r\n\r\n" + assert_body "37\r\n\"><script>window.location = \"/500.html\"</script></html>\r\n0\r\n\r\n" assert_streaming! end diff --git a/actionpack/test/controller/rescue_test.rb b/actionpack/test/controller/rescue_test.rb index 9c51db135b..76c3dfe0d4 100644 --- a/actionpack/test/controller/rescue_test.rb +++ b/actionpack/test/controller/rescue_test.rb @@ -60,11 +60,6 @@ class RescueController < ActionController::Base render :text => exception.message end - # This is a Dispatcher exception and should be in ApplicationController. - rescue_from ActionController::RoutingError do - render :text => 'no way' - end - rescue_from ActionView::TemplateError do render :text => 'action_view templater error' end |