diff options
author | Emilio Tagua <miloops@gmail.com> | 2009-04-29 19:47:21 -0300 |
---|---|---|
committer | Emilio Tagua <miloops@gmail.com> | 2009-04-29 19:47:21 -0300 |
commit | b0bd4f45fa9180793e3c35590c8a887ddfe43553 (patch) | |
tree | d1ab690267c5e4d9d04faca14d4695f163375086 /actionpack/test/controller/render_test.rb | |
parent | 19d2ff83db5232a816dee201800baf3924705b31 (diff) | |
parent | db892ea77563dadb6fbbd242be78ff87321d0bd1 (diff) | |
download | rails-b0bd4f45fa9180793e3c35590c8a887ddfe43553.tar.gz rails-b0bd4f45fa9180793e3c35590c8a887ddfe43553.tar.bz2 rails-b0bd4f45fa9180793e3c35590c8a887ddfe43553.zip |
Merge commit 'rails/master'
Diffstat (limited to 'actionpack/test/controller/render_test.rb')
-rw-r--r-- | actionpack/test/controller/render_test.rb | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/actionpack/test/controller/render_test.rb b/actionpack/test/controller/render_test.rb index bf72730bea..da063710a9 100644 --- a/actionpack/test/controller/render_test.rb +++ b/actionpack/test/controller/render_test.rb @@ -1,5 +1,6 @@ require 'abstract_unit' require 'controller/fake_models' +require 'pathname' module Fun class GamesController < ActionController::Base @@ -772,7 +773,7 @@ class RenderTest < ActionController::TestCase begin get :render_line_offset flunk "the action should have raised an exception" - rescue RuntimeError => exc + rescue StandardError => exc line = exc.backtrace.first assert(line =~ %r{:(\d+):}) assert_equal "1", $1, @@ -1735,7 +1736,7 @@ class RenderingLoggingTest < ActionController::TestCase @controller.logger = MockLogger.new get :layout_test logged = @controller.logger.logged.find_all {|l| l =~ /render/i } - assert_equal "Rendering test/hello_world", logged[0] - assert_equal "Rendering template within layouts/standard", logged[1] + assert logged[0] =~ %r{Rendering.*test/hello_world} + assert logged[1] =~ %r{Rendering template within.*layouts/standard} end end |