diff --git a/test/ruby/test_array.rb b/test/ruby/test_array.rb index 4667f4cff7..0d88f26dc0 100644 --- a/test/ruby/test_array.rb +++ b/test/ruby/test_array.rb @@ -691,6 +691,8 @@ class TestArray < Test::Unit::TestCase assert_equal(@cls[], @cls[].flatten) assert_equal(@cls[], @cls[@cls[@cls[@cls[],@cls[]],@cls[@cls[]],@cls[]],@cls[@cls[@cls[]]]].flatten) + + assert_raise(TypeError, "[ruby-dev:31197]") { [[]].flatten("") } end def test_flatten!