mirror of
https://github.com/ruby/ruby.git
synced 2022-11-09 12:17:21 -05:00
Prevent accidental use of assert_raises
This commit is contained in:
parent
d2166c09b0
commit
f159bbd17d
2 changed files with 4 additions and 4 deletions
|
@ -3,6 +3,10 @@
|
|||
module Test
|
||||
module Unit
|
||||
module Assertions
|
||||
def assert_raises(*exp, &b)
|
||||
raise NoMethodError, "use assert_raise", caller
|
||||
end
|
||||
|
||||
def _assertions= n # :nodoc:
|
||||
@_assertions = n
|
||||
end
|
||||
|
|
|
@ -563,10 +563,6 @@ module Test
|
|||
assert yield, *msgs
|
||||
end
|
||||
|
||||
def assert_raises(*exp, &b)
|
||||
raise NoMethodError, "use assert_raise", caller
|
||||
end
|
||||
|
||||
# :call-seq:
|
||||
# assert_nothing_thrown( failure_message = nil, &block )
|
||||
#
|
||||
|
|
Loading…
Reference in a new issue