test_array.rb: try to avoid NoMemoryError on AppVeyor

We somehow hit NoMemoryError twice on that place.
https://ci.appveyor.com/project/ruby/ruby/builds/20224556/job/hlgt963e0cgjbj3c
https://ci.appveyor.com/project/ruby/ruby/builds/20250696/job/gm559bu2jbd6youm

Let me try firing GC here.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@65690 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
k0kubun 2018-11-13 01:35:09 +00:00
Родитель 2a70978df8
Коммит 601f4b6f67
1 изменённых файлов: 1 добавлений и 0 удалений

Просмотреть файл

@ -2943,6 +2943,7 @@ class TestArray < Test::Unit::TestCase
Bug11235 = '[ruby-dev:49043] [Bug #11235]'
def test_push_over_ary_max
GC.start # avoid NoMemoryError on the next line
assert_separately(['-', ARY_MAX.to_s, Bug11235], "#{<<~"begin;"}\n#{<<~'end;'}", timeout: 30)
begin;
a = Array.new(ARGV[0].to_i)