4
class TestNotImplement < Test::Unit::TestCase
5
def test_respond_to_fork
6
assert_includes(Process.methods, :fork)
7
if /linux/ =~ RUBY_PLATFORM
8
assert_equal(true, Process.respond_to?(:fork))
12
def test_respond_to_lchmod
13
assert_includes(File.methods, :lchmod)
14
if /linux/ =~ RUBY_PLATFORM
15
assert_equal(false, File.respond_to?(:lchmod))
17
if /freebsd/ =~ RUBY_PLATFORM
18
assert_equal(true, File.respond_to?(:lchmod))
23
if Process.respond_to?(:fork)
24
assert_nothing_raised {
32
if File.respond_to?(:lchmod)
39
File.lchmod newmode, "#{d}/g"
41
assert_equal(newmode, snew.mode & 0777)
46
def test_method_inspect_fork
47
m = Process.method(:fork)
48
if Process.respond_to?(:fork)
49
assert_not_match(/not-implemented/, m.inspect)
51
assert_match(/not-implemented/, m.inspect)
55
def test_method_inspect_lchmod
56
m = File.method(:lchmod)
57
if File.respond_to?(:lchmod)
58
assert_not_match(/not-implemented/, m.inspect)
60
assert_match(/not-implemented/, m.inspect)