* Add test for Enumerable#none? [fix GH-950] Patch by @yui-knk
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@51083 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
parent
a672fd8be3
commit
8430f93b8f
@ -1,3 +1,7 @@
|
|||||||
|
Wed Jul 1 10:54:56 2015 SHIBATA Hiroshi <hsbt@ruby-lang.org>
|
||||||
|
|
||||||
|
* Add test for Enumerable#none? [fix GH-950] Patch by @yui-knk
|
||||||
|
|
||||||
Wed Jul 1 09:30:36 2015 Nobuyoshi Nakada <nobu@ruby-lang.org>
|
Wed Jul 1 09:30:36 2015 Nobuyoshi Nakada <nobu@ruby-lang.org>
|
||||||
|
|
||||||
* struct.c (struct_set_members): hide internal back_members
|
* struct.c (struct_set_members): hide internal back_members
|
||||||
|
1
enum.c
1
enum.c
@ -1401,6 +1401,7 @@ DEFINE_ENUMFUNCS(none)
|
|||||||
* [].none? #=> true
|
* [].none? #=> true
|
||||||
* [nil].none? #=> true
|
* [nil].none? #=> true
|
||||||
* [nil, false].none? #=> true
|
* [nil, false].none? #=> true
|
||||||
|
* [nil, false, true].none? #=> false
|
||||||
*/
|
*/
|
||||||
static VALUE
|
static VALUE
|
||||||
enum_none(VALUE obj)
|
enum_none(VALUE obj)
|
||||||
|
@ -265,6 +265,7 @@ class TestEnumerable < Test::Unit::TestCase
|
|||||||
assert([].none?)
|
assert([].none?)
|
||||||
assert([nil].none?)
|
assert([nil].none?)
|
||||||
assert([nil,false].none?)
|
assert([nil,false].none?)
|
||||||
|
assert(![nil,false,true].none?)
|
||||||
end
|
end
|
||||||
|
|
||||||
def test_min
|
def test_min
|
||||||
|
Loading…
x
Reference in New Issue
Block a user