mirror of
https://github.com/ruby/ruby.git
synced 2022-11-09 12:17:21 -05:00
Use omit instead of skip without the default gems tests
This commit is contained in:
parent
6d3ee418c2
commit
f95039af75
7 changed files with 31 additions and 31 deletions
|
@ -122,7 +122,7 @@ module DTrace
|
|||
def trap_probe d_program, ruby_program
|
||||
if Hash === d_program
|
||||
d_program = d_program[IMPL] or
|
||||
skip "#{d_program} not implemented for #{IMPL}"
|
||||
omit "#{d_program} not implemented for #{IMPL}"
|
||||
elsif String === d_program && IMPL == :stap
|
||||
d_program = dtrace2systemtap(d_program)
|
||||
end
|
||||
|
|
|
@ -6,14 +6,14 @@ class TestFiberEnumerator < Test::Unit::TestCase
|
|||
MESSAGE = "Hello World"
|
||||
|
||||
def test_read_characters
|
||||
skip "UNIXSocket is not defined!" unless defined?(UNIXSocket)
|
||||
omit "UNIXSocket is not defined!" unless defined?(UNIXSocket)
|
||||
|
||||
i, o = UNIXSocket.pair
|
||||
|
||||
unless i.nonblock? && o.nonblock?
|
||||
i.close
|
||||
o.close
|
||||
skip "I/O is not non-blocking!"
|
||||
omit "I/O is not non-blocking!"
|
||||
end
|
||||
|
||||
message = String.new
|
||||
|
|
|
@ -6,14 +6,14 @@ class TestFiberIO < Test::Unit::TestCase
|
|||
MESSAGE = "Hello World"
|
||||
|
||||
def test_read
|
||||
skip "UNIXSocket is not defined!" unless defined?(UNIXSocket)
|
||||
omit "UNIXSocket is not defined!" unless defined?(UNIXSocket)
|
||||
|
||||
i, o = UNIXSocket.pair
|
||||
|
||||
unless i.nonblock? && o.nonblock?
|
||||
i.close
|
||||
o.close
|
||||
skip "I/O is not non-blocking!"
|
||||
omit "I/O is not non-blocking!"
|
||||
end
|
||||
|
||||
message = nil
|
||||
|
@ -41,7 +41,7 @@ class TestFiberIO < Test::Unit::TestCase
|
|||
end
|
||||
|
||||
def test_heavy_read
|
||||
skip unless defined?(UNIXSocket)
|
||||
omit unless defined?(UNIXSocket)
|
||||
|
||||
16.times.map do
|
||||
Thread.new do
|
||||
|
@ -64,14 +64,14 @@ class TestFiberIO < Test::Unit::TestCase
|
|||
end
|
||||
|
||||
def test_epipe_on_read
|
||||
skip "UNIXSocket is not defined!" unless defined?(UNIXSocket)
|
||||
omit "UNIXSocket is not defined!" unless defined?(UNIXSocket)
|
||||
|
||||
i, o = UNIXSocket.pair
|
||||
|
||||
unless i.nonblock? && o.nonblock?
|
||||
i.close
|
||||
o.close
|
||||
skip "I/O is not non-blocking!"
|
||||
omit "I/O is not non-blocking!"
|
||||
end
|
||||
|
||||
error = nil
|
||||
|
@ -142,7 +142,7 @@ class TestFiberIO < Test::Unit::TestCase
|
|||
end
|
||||
|
||||
def test_read_write_blocking
|
||||
skip "UNIXSocket is not defined!" unless defined?(UNIXSocket)
|
||||
omit "UNIXSocket is not defined!" unless defined?(UNIXSocket)
|
||||
|
||||
i, o = UNIXSocket.pair
|
||||
i.nonblock = false
|
||||
|
|
|
@ -8,7 +8,7 @@ class TestFiberIOBuffer < Test::Unit::TestCase
|
|||
MESSAGE = "Hello World"
|
||||
|
||||
def test_read_write_blocking
|
||||
skip "UNIXSocket is not defined!" unless defined?(UNIXSocket)
|
||||
omit "UNIXSocket is not defined!" unless defined?(UNIXSocket)
|
||||
|
||||
i, o = UNIXSocket.pair
|
||||
i.nonblock = false
|
||||
|
@ -42,7 +42,7 @@ class TestFiberIOBuffer < Test::Unit::TestCase
|
|||
end
|
||||
|
||||
def test_timeout_after
|
||||
skip "UNIXSocket is not defined!" unless defined?(UNIXSocket)
|
||||
omit "UNIXSocket is not defined!" unless defined?(UNIXSocket)
|
||||
|
||||
i, o = UNIXSocket.pair
|
||||
i.nonblock = false
|
||||
|
@ -76,7 +76,7 @@ class TestFiberIOBuffer < Test::Unit::TestCase
|
|||
end
|
||||
|
||||
def test_read_nonblock
|
||||
skip "UNIXSocket is not defined!" unless defined?(UNIXSocket)
|
||||
omit "UNIXSocket is not defined!" unless defined?(UNIXSocket)
|
||||
|
||||
i, o = UNIXSocket.pair
|
||||
|
||||
|
@ -101,7 +101,7 @@ class TestFiberIOBuffer < Test::Unit::TestCase
|
|||
end
|
||||
|
||||
def test_write_nonblock
|
||||
skip "UNIXSocket is not defined!" unless defined?(UNIXSocket)
|
||||
omit "UNIXSocket is not defined!" unless defined?(UNIXSocket)
|
||||
|
||||
i, o = UNIXSocket.pair
|
||||
|
||||
|
|
|
@ -4,7 +4,7 @@ require "fiber"
|
|||
|
||||
class TestFiberCurrentRactor < Test::Unit::TestCase
|
||||
def setup
|
||||
skip unless defined? Ractor
|
||||
omit unless defined? Ractor
|
||||
end
|
||||
|
||||
def test_ractor_shareable
|
||||
|
|
|
@ -140,7 +140,7 @@ class TestGc < Test::Unit::TestCase
|
|||
end
|
||||
|
||||
def test_stat_heap
|
||||
skip 'stress' if GC.stress
|
||||
omit 'stress' if GC.stress
|
||||
|
||||
stat_heap = {}
|
||||
stat = {}
|
||||
|
@ -187,7 +187,7 @@ class TestGc < Test::Unit::TestCase
|
|||
end
|
||||
|
||||
def test_stat_heap_constraints
|
||||
skip 'stress' if GC.stress
|
||||
omit 'stress' if GC.stress
|
||||
|
||||
stat = GC.stat
|
||||
stat_heap = GC.stat_heap
|
||||
|
|
|
@ -14,7 +14,7 @@ class TestPTY < Test::Unit::TestCase
|
|||
def test_spawn_without_block
|
||||
r, w, pid = PTY.spawn(RUBY, '-e', 'puts "a"')
|
||||
rescue RuntimeError
|
||||
skip $!
|
||||
omit $!
|
||||
else
|
||||
assert_equal("a\r\n", r.gets)
|
||||
ensure
|
||||
|
@ -34,7 +34,7 @@ class TestPTY < Test::Unit::TestCase
|
|||
end
|
||||
}
|
||||
rescue RuntimeError
|
||||
skip $!
|
||||
omit $!
|
||||
end
|
||||
|
||||
def test_commandline
|
||||
|
@ -49,7 +49,7 @@ class TestPTY < Test::Unit::TestCase
|
|||
end
|
||||
}
|
||||
rescue RuntimeError
|
||||
skip $!
|
||||
omit $!
|
||||
end
|
||||
|
||||
def test_argv0
|
||||
|
@ -63,13 +63,13 @@ class TestPTY < Test::Unit::TestCase
|
|||
end
|
||||
}
|
||||
rescue RuntimeError
|
||||
skip $!
|
||||
omit $!
|
||||
end
|
||||
|
||||
def test_open_without_block
|
||||
ret = PTY.open
|
||||
rescue RuntimeError
|
||||
skip $!
|
||||
omit $!
|
||||
else
|
||||
assert_kind_of(Array, ret)
|
||||
assert_equal(2, ret.length)
|
||||
|
@ -100,7 +100,7 @@ class TestPTY < Test::Unit::TestCase
|
|||
x
|
||||
}
|
||||
rescue RuntimeError
|
||||
skip $!
|
||||
omit $!
|
||||
else
|
||||
assert(r[0].closed?)
|
||||
assert(r[1].closed?)
|
||||
|
@ -115,7 +115,7 @@ class TestPTY < Test::Unit::TestCase
|
|||
assert(master.closed?)
|
||||
}
|
||||
rescue RuntimeError
|
||||
skip $!
|
||||
omit $!
|
||||
else
|
||||
assert_nothing_raised {
|
||||
PTY.open {|master, slave|
|
||||
|
@ -133,7 +133,7 @@ class TestPTY < Test::Unit::TestCase
|
|||
assert_equal("bar", slave.gets.chomp)
|
||||
}
|
||||
rescue RuntimeError
|
||||
skip $!
|
||||
omit $!
|
||||
end
|
||||
|
||||
def test_stat_slave
|
||||
|
@ -143,7 +143,7 @@ class TestPTY < Test::Unit::TestCase
|
|||
assert_equal(0600, s.mode & 0777)
|
||||
}
|
||||
rescue RuntimeError
|
||||
skip $!
|
||||
omit $!
|
||||
end
|
||||
|
||||
def test_close_master
|
||||
|
@ -152,7 +152,7 @@ class TestPTY < Test::Unit::TestCase
|
|||
assert_raise(EOFError) { slave.readpartial(10) }
|
||||
}
|
||||
rescue RuntimeError
|
||||
skip $!
|
||||
omit $!
|
||||
end
|
||||
|
||||
def test_close_slave
|
||||
|
@ -165,7 +165,7 @@ class TestPTY < Test::Unit::TestCase
|
|||
) { master.readpartial(10) }
|
||||
}
|
||||
rescue RuntimeError
|
||||
skip $!
|
||||
omit $!
|
||||
end
|
||||
|
||||
def test_getpty_nonexistent
|
||||
|
@ -175,7 +175,7 @@ class TestPTY < Test::Unit::TestCase
|
|||
begin
|
||||
PTY.getpty(File.join(tmpdir, "no-such-command"))
|
||||
rescue RuntimeError
|
||||
skip $!
|
||||
omit $!
|
||||
end
|
||||
}
|
||||
end
|
||||
|
@ -194,7 +194,7 @@ class TestPTY < Test::Unit::TestCase
|
|||
end until st2 = PTY.check(pid)
|
||||
end
|
||||
rescue RuntimeError
|
||||
skip $!
|
||||
omit $!
|
||||
else
|
||||
assert_nil(st1)
|
||||
assert_equal(pid, st2.pid)
|
||||
|
@ -212,7 +212,7 @@ class TestPTY < Test::Unit::TestCase
|
|||
st2 = assert_raise(PTY::ChildExited, bug2642) {PTY.check(pid, true)}.status
|
||||
end
|
||||
rescue RuntimeError
|
||||
skip $!
|
||||
omit $!
|
||||
else
|
||||
assert_nil(st1)
|
||||
assert_equal(pid, st2.pid)
|
||||
|
@ -234,6 +234,6 @@ class TestPTY < Test::Unit::TestCase
|
|||
end
|
||||
}
|
||||
rescue RuntimeError
|
||||
skip $!
|
||||
omit $!
|
||||
end
|
||||
end if defined? PTY
|
||||
|
|
Loading…
Reference in a new issue