Skip to content

Commit

Permalink
[ruby/io-console] Filter Ruby engine name rather than just /ruby/
Browse files Browse the repository at this point in the history
This breaks tests using this path on JRuby because the `jruby`
executable turns into `jjruby` after the sub.

ruby/io-console@e5951aa34c
  • Loading branch information
headius authored and nobu committed Jan 17, 2020
1 parent 4e1a767 commit 569f56e
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion test/io/console/test_io_console.rb
Expand Up @@ -462,7 +462,7 @@ def test_sync
noctty = [EnvUtil.rubybin, "-e", "Process.daemon(true)"]
when !(rubyw = RbConfig::CONFIG["RUBYW_INSTALL_NAME"]).empty?
dir, base = File.split(EnvUtil.rubybin)
noctty = [File.join(dir, base.sub(/ruby/, rubyw))]
noctty = [File.join(dir, base.sub(RUBY_ENGINE, rubyw))]
end

if noctty
Expand Down

0 comments on commit 569f56e

Please sign in to comment.