From 6199181b092e98bffe52452b12ce28e32cddd523 Mon Sep 17 00:00:00 2001 From: naruse Date: Fri, 9 Sep 2011 02:26:31 +0000 Subject: [PATCH] Catch NoMemoryError. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@33234 b2dd03c8-39d4-4d8f-98ff-823fe69b080e --- test/ruby/test_process.rb | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/test/ruby/test_process.rb b/test/ruby/test_process.rb index c68b6008fe..6630cf048b 100644 --- a/test/ruby/test_process.rb +++ b/test/ruby/test_process.rb @@ -1237,14 +1237,14 @@ class TestProcess < Test::Unit::TestCase def test_too_long_path bug4314 = '[ruby-core:34842]' - exs = [Errno::ENOENT] + exs = [NoMemoryError, Errno::ENOENT] exs << Errno::E2BIG if defined?(Errno::E2BIG) assert_raise(*exs, bug4314) {Process.spawn("a" * 10_000_000)} end def test_too_long_path2 bug4315 = '[ruby-core:34833]' - exs = [Errno::ENOENT] + exs = [NoMemoryError, Errno::ENOENT] exs << Errno::E2BIG if defined?(Errno::E2BIG) assert_raise(*exs, bug4315) {Process.spawn('"a"|'*10_000_000)} end