You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The following test (from test/jruby/test_backquote.rb) is used to confirm that doing chdir to a uri/url address does not break process launching. The test passes, but only because we attempt to "cd" in the subprocess shell before executing the code, and that just silently fails.
Here's the test:
deftest_backquote_special_commands_and_cwd_inside_classloader# not sure why it fails with java-1.6 - assume it is rare feature# and works for java-1.7+ifFile.exists?("/bin/echo")and not ENV_JAVA['java.version'].start_with?("1.6.")begincwd=Dir.pwdDir.chdir('uri:classloader:/')output=`/bin/echo hello`assert_equal("hello\n",output)ensureDir.chdir(cwd)endendend
This results in stderr output:
sh: line 0: cd: uri:classloader:/: No such file or directory
This also raises questions about correct behavior here:
Should the subprocess launch fail if it can't cd to our chosen cwd?
Should it succeed at all if we chdir to a uri/url directory? This test implies it should.
Should subprocess launching ignore uri/url-like cwd?
cc @mkristian and @kares since they may have some insight on what we should do here.
The following test (from test/jruby/test_backquote.rb) is used to confirm that doing chdir to a uri/url address does not break process launching. The test passes, but only because we attempt to "cd" in the subprocess shell before executing the code, and that just silently fails.
Here's the test:
This results in stderr output:
This also raises questions about correct behavior here:
cc @mkristian and @kares since they may have some insight on what we should do here.
This test has been disabled in e86ad04.
The text was updated successfully, but these errors were encountered: