diff options
author | nobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2014-11-15 07:28:08 +0000 |
---|---|---|
committer | nobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2014-11-15 07:28:08 +0000 |
commit | 558b9191c0c76d9807f339dae289a62ad7ed4ae8 (patch) | |
tree | fbed87b0b070cf04dccb7789607c496d758ec96a /test/lib/test/unit/assertions.rb | |
parent | abd5ba5af2b98d5cfdd947f855669f6e8cc61615 (diff) |
vm_eval.c: UncaughtThrowError
* vm_eval.c (rb_throw_obj): throw UncaughtThrowError instead of
ArgumentError. [Feature #10480]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@48433 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'test/lib/test/unit/assertions.rb')
-rw-r--r-- | test/lib/test/unit/assertions.rb | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/test/lib/test/unit/assertions.rb b/test/lib/test/unit/assertions.rb index 4ba13a81e0..727c54c9d5 100644 --- a/test/lib/test/unit/assertions.rb +++ b/test/lib/test/unit/assertions.rb @@ -223,8 +223,8 @@ module Test ret = catch(tag) do begin yield(tag) - rescue ArgumentError => e - raise unless thrown = e.message[/\Auncaught throw (.+)\z/m, 1] + rescue UncaughtThrowError => e + thrown = e.tag end msg = message(msg) { "Expected #{mu_pp(tag)} to have been thrown"\ |