diff options
Diffstat (limited to 'mrbgems/mruby-array-ext/test/array.rb')
| -rw-r--r-- | mrbgems/mruby-array-ext/test/array.rb | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/mrbgems/mruby-array-ext/test/array.rb b/mrbgems/mruby-array-ext/test/array.rb index ed1edb5c2..8c6a7bd54 100644 --- a/mrbgems/mruby-array-ext/test/array.rb +++ b/mrbgems/mruby-array-ext/test/array.rb @@ -139,5 +139,10 @@ assert("Array#reverse_each") do b << i end assert_equal [ "d", "c", "b", "a" ], b - assert_equal [ "d", "c", "b", "a" ], a.reverse_each.to_a + + if Object.const_defined?(:Enumerator) + assert_equal [ "d", "c", "b", "a" ], a.reverse_each.to_a + else + true + end end |
