aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorusa <usa@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2011-01-28 02:48:46 +0000
committerusa <usa@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2011-01-28 02:48:46 +0000
commitd4f8142d18f068b7bc4b82e84e44518dfda32840 (patch)
treeb9eeaff90fcdfef2644539d68631b9492463ca41
parent4afa5fead876c3b732bb7bba3674231704b9df96 (diff)
downloadruby-d4f8142d18f068b7bc4b82e84e44518dfda32840.tar.gz
* test/ruby/test_process.rb (TestProcess#test_too_long_path{,2}):
should handle Errno::E2BIG, because this test checks crash of ruby, not the error type system. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@30697 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
-rw-r--r--ChangeLog6
-rw-r--r--test/ruby/test_process.rb8
2 files changed, 12 insertions, 2 deletions
diff --git a/ChangeLog b/ChangeLog
index d55aa0e606..ffee964109 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,9 @@
+Fri Jan 28 11:47:00 2011 NAKAMURA Usaku <usa@ruby-lang.org>
+
+ * test/ruby/test_process.rb (TestProcess#test_too_long_path{,2}):
+ should handle Errno::E2BIG, because this test checks crash of ruby,
+ not the error type system.
+
Fri Jan 28 11:23:54 2011 KOSAKI Motohiro <kosaki.motohiro@gmail.com>
* io.c (rb_io_open): Use NUM2MODET() instead NUM2UINT().
diff --git a/test/ruby/test_process.rb b/test/ruby/test_process.rb
index d6a486c5c0..0df1491b68 100644
--- a/test/ruby/test_process.rb
+++ b/test/ruby/test_process.rb
@@ -1234,11 +1234,15 @@ class TestProcess < Test::Unit::TestCase
def test_too_long_path
bug4314 = '[ruby-core:34842]'
- assert_raise(Errno::ENOENT, bug4314) {Process.spawn("a" * 10_000_000)}
+ exs = [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]'
- assert_raise(Errno::ENOENT, bug4315) {Process.spawn('"a"|'*10_000_000)}
+ exs = [Errno::ENOENT]
+ exs << Errno::E2BIG if defined?(Errno::E2BIG)
+ assert_raise(*exs, bug4315) {Process.spawn('"a"|'*10_000_000)}
end
end