diff --git a/test/ruby/test_io.rb b/test/ruby/test_io.rb index ad9e4fa08f..bd92634785 100644 --- a/test/ruby/test_io.rb +++ b/test/ruby/test_io.rb @@ -3005,8 +3005,12 @@ End # we don't know if other platforms have a real posix_fadvise() with_pipe do |r,w| # Linux 2.6.15 and earlier returned EINVAL instead of ESPIPE - assert_raise(Errno::ESPIPE, Errno::EINVAL) { r.advise(:willneed) } - assert_raise(Errno::ESPIPE, Errno::EINVAL) { w.advise(:willneed) } + assert_raise(Errno::ESPIPE, Errno::EINVAL) { + r.advise(:willneed) or skip "fadvice(2) is not implemented" + } + assert_raise(Errno::ESPIPE, Errno::EINVAL) { + w.advise(:willneed) or skip "fadvice(2) is not implemented" + } end end if /linux/ =~ RUBY_PLATFORM