mirror of
https://github.com/ruby/ruby.git
synced 2022-11-09 12:17:21 -05:00
* lib/test/unit/assertions.rb: [DOC] better example for assert_send()
Patch by Andrew Grimm [Bug #8975] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@43597 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
parent
1546fb6c00
commit
4370f84653
2 changed files with 7 additions and 2 deletions
|
@ -1,3 +1,8 @@
|
||||||
|
Sat Nov 9 13:59:58 2013 Zachary Scott <e@zzak.io>
|
||||||
|
|
||||||
|
* lib/test/unit/assertions.rb: [DOC] better example for assert_send()
|
||||||
|
Patch by Andrew Grimm [Bug #8975]
|
||||||
|
|
||||||
Sat Nov 9 12:45:00 2013 Charlie Somerville <charliesome@ruby-lang.org>
|
Sat Nov 9 12:45:00 2013 Charlie Somerville <charliesome@ruby-lang.org>
|
||||||
|
|
||||||
* insns.def: unify ic_constant_serial and ic_class_serial into one field
|
* insns.def: unify ic_constant_serial and ic_class_serial into one field
|
||||||
|
|
|
@ -328,8 +328,8 @@ EOT
|
||||||
# * Arguments to the method
|
# * Arguments to the method
|
||||||
#
|
#
|
||||||
# Example:
|
# Example:
|
||||||
# assert_send([[1, 2], :member?, 1]) # -> pass
|
# assert_send(["Hello world", :include?, "Hello"]) # -> pass
|
||||||
# assert_send([[1, 2], :member?, 4]) # -> fail
|
# assert_send(["Hello world", :include?, "Goodbye"]) # -> fail
|
||||||
def assert_send send_ary, m = nil
|
def assert_send send_ary, m = nil
|
||||||
recv, msg, *args = send_ary
|
recv, msg, *args = send_ary
|
||||||
m = message(m) {
|
m = message(m) {
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue