* lib/test/unit/assertions.rb: use #__send__ instead of #send.
* lib/test/unit/testcase.rb: ditto. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@4995 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
parent
65f4f950fb
commit
b31aeea632
@ -1,3 +1,9 @@
|
|||||||
|
Thu Nov 21 00:43:00 2003 Nathaniel Talbott <ntalbott@ruby-lang.org>
|
||||||
|
|
||||||
|
* lib/test/unit/assertions.rb: use #__send__ instead of #send.
|
||||||
|
|
||||||
|
* lib/test/unit/testcase.rb: ditto.
|
||||||
|
|
||||||
Thu Nov 20 19:19:22 2003 WATANABE Hirofumi <eban@ruby-lang.org>
|
Thu Nov 20 19:19:22 2003 WATANABE Hirofumi <eban@ruby-lang.org>
|
||||||
|
|
||||||
* configure.in: don't find the Cygwin's pthread library on MinGW.
|
* configure.in: don't find the Cygwin's pthread library on MinGW.
|
||||||
|
@ -156,8 +156,8 @@ EOT
|
|||||||
end
|
end
|
||||||
|
|
||||||
# Compares the two objects based on the passed
|
# Compares the two objects based on the passed
|
||||||
# operator. Passes if object1.send(operator, object2) is
|
# operator. Passes if object1.__send__(operator, object2)
|
||||||
# true.
|
# is true.
|
||||||
public
|
public
|
||||||
def assert_operator(object1, operator, object2, message="")
|
def assert_operator(object1, operator, object2, message="")
|
||||||
_wrap_assertion do
|
_wrap_assertion do
|
||||||
@ -168,7 +168,7 @@ EOT
|
|||||||
?
|
?
|
||||||
<?>.
|
<?>.
|
||||||
EOT
|
EOT
|
||||||
assert_block(full_message) { object1.send(operator, object2) }
|
assert_block(full_message) { object1.__send__(operator, object2) }
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
@ -236,7 +236,7 @@ EOT
|
|||||||
end
|
end
|
||||||
|
|
||||||
UncaughtThrow = {NameError => /^uncaught throw \`(.+)\'$/,
|
UncaughtThrow = {NameError => /^uncaught throw \`(.+)\'$/,
|
||||||
ThreadError => /^uncaught throw \`(.+)\' in thread /}
|
ThreadError => /^uncaught throw \`(.+)\' in thread /} #`
|
||||||
|
|
||||||
# Passes if block throws symbol.
|
# Passes if block throws symbol.
|
||||||
public
|
public
|
||||||
|
@ -67,7 +67,7 @@ module Test
|
|||||||
@_result = result
|
@_result = result
|
||||||
begin
|
begin
|
||||||
setup
|
setup
|
||||||
send(@method_name)
|
__send__(@method_name)
|
||||||
rescue AssertionFailedError => e
|
rescue AssertionFailedError => e
|
||||||
add_failure(e.message, e.backtrace)
|
add_failure(e.message, e.backtrace)
|
||||||
rescue StandardError, ScriptError
|
rescue StandardError, ScriptError
|
||||||
|
Loading…
x
Reference in New Issue
Block a user