зеркало из https://github.com/github/ruby.git
[ruby/open3] Only use JITSupport on CRuby
Fixes #2 https://github.com/ruby/open3/commit/6b7ede69e8
This commit is contained in:
Родитель
d150b8d06f
Коммит
34ebd13923
|
@ -2,7 +2,10 @@
|
||||||
|
|
||||||
require 'test/unit'
|
require 'test/unit'
|
||||||
require 'open3'
|
require 'open3'
|
||||||
require_relative 'lib/jit_support'
|
|
||||||
|
if RUBY_ENGINE == 'ruby'
|
||||||
|
require_relative 'lib/jit_support'
|
||||||
|
end
|
||||||
|
|
||||||
class TestOpen3 < Test::Unit::TestCase
|
class TestOpen3 < Test::Unit::TestCase
|
||||||
RUBY = EnvUtil.rubybin
|
RUBY = EnvUtil.rubybin
|
||||||
|
@ -127,7 +130,11 @@ class TestOpen3 < Test::Unit::TestCase
|
||||||
i.close
|
i.close
|
||||||
STDERR.reopen(old)
|
STDERR.reopen(old)
|
||||||
assert_equal("zo", o.read)
|
assert_equal("zo", o.read)
|
||||||
assert_equal("ze", JITSupport.remove_mjit_logs(r.read))
|
if defined?(JITSupport)
|
||||||
|
assert_equal("ze", JITSupport.remove_mjit_logs(r.read))
|
||||||
|
else
|
||||||
|
assert_equal("ze", r.read)
|
||||||
|
end
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Загрузка…
Ссылка в новой задаче