Handle Array#* raising ArgumentError in test
Treat ArgumentError as NoMemoryError, so it will resize the array and try again. Fixes [Bug #12500]
This commit is contained in:
parent
ce79887da0
commit
bd22bb259c
Notes:
git
2023-08-23 23:46:39 +00:00
@ -1799,7 +1799,11 @@ class TestProcess < Test::Unit::TestCase
|
||||
loop do
|
||||
Process.spawn(cmds.join(sep), opts)
|
||||
min = [cmds.size, min].max
|
||||
cmds *= 100
|
||||
begin
|
||||
cmds *= 100
|
||||
rescue ArgumentError
|
||||
raise NoMemoryError
|
||||
end
|
||||
end
|
||||
rescue NoMemoryError
|
||||
size = cmds.size
|
||||
|
Loading…
x
Reference in New Issue
Block a user