summaryrefslogtreecommitdiff
path: root/test/io
diff options
context:
space:
mode:
Diffstat (limited to 'test/io')
-rw-r--r--test/io/console/test_io_console.rb4
1 files changed, 2 insertions, 2 deletions
diff --git a/test/io/console/test_io_console.rb b/test/io/console/test_io_console.rb
index 2121fcdb63..3d12b1f463 100644
--- a/test/io/console/test_io_console.rb
+++ b/test/io/console/test_io_console.rb
@@ -323,8 +323,6 @@ defined?(PTY) and defined?(IO.console) and TestIO_Console.class_eval do
end
def test_cursor_position
- return if RUBY_ENGINE == 'jruby'
-
run_pty("#{<<~"begin;"}\n#{<<~'end;'}") do |r, w, _|
begin;
con = IO.console
@@ -421,6 +419,8 @@ defined?(PTY) and defined?(IO.console) and TestIO_Console.class_eval do
end
def run_pty(src, n = 1)
+ pend("PTY.spawn cannot control terminal on JRuby") if RUBY_ENGINE == 'jruby'
+
r, w, pid = PTY.spawn(EnvUtil.rubybin, "-I#{TestIO_Console::PATHS.join(File::PATH_SEPARATOR)}", "-rio/console", "-e", src)
rescue RuntimeError
omit $!