diff options
author | Sean Griffin <sean@seantheprogrammer.com> | 2016-11-17 14:49:07 -0500 |
---|---|---|
committer | Sean Griffin <sean@seantheprogrammer.com> | 2016-11-17 14:50:41 -0500 |
commit | f48bb1b4ad86bad71ae9c3e5dd3db6b4cb80e4d1 (patch) | |
tree | 0dfc8bf23e4c22bc66c9a1042a7f5775983e2cb9 /activesupport/test | |
parent | 8d015dff821875faab3429badbc378dc4c80b90c (diff) | |
download | rails-f48bb1b4ad86bad71ae9c3e5dd3db6b4cb80e4d1.tar.gz rails-f48bb1b4ad86bad71ae9c3e5dd3db6b4cb80e4d1.tar.bz2 rails-f48bb1b4ad86bad71ae9c3e5dd3db6b4cb80e4d1.zip |
Call fallback exception handlers with the right exception
The issue presented in #26246 showed a deeper underlying problem. When
we fell back to the exception handler for an exceptions cause, we were
calling that handler with the outer raised exception. This breaks the
calling code's expectations, especially if the exception has methods on
it behond those from `StandardError`.
Diffstat (limited to 'activesupport/test')
-rw-r--r-- | activesupport/test/rescuable_test.rb | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/activesupport/test/rescuable_test.rb b/activesupport/test/rescuable_test.rb index 7e5c3d1a8f..f7eb047d44 100644 --- a/activesupport/test/rescuable_test.rb +++ b/activesupport/test/rescuable_test.rb @@ -137,6 +137,6 @@ class RescuableTest < ActiveSupport::TestCase def test_rescue_falls_back_to_exception_cause @stargate.dispatch :fall_back_to_cause - assert_equal "unhandled RuntimeError with a handleable cause", @stargate.result + assert_equal "dex", @stargate.result end end |