File.expand_path with relative directories
------------------------------------------
Key: JRUBY-2160
URL: http://jira.codehaus.org/browse/JRUBY-2160
Project: JRuby
Issue Type: Bug
Components: Core Classes/Modules
Affects Versions: JRuby 1.1RC2
Reporter: Charles
Priority: Minor
In trying to run the ruby-ole unit tests on jruby, I ran into a problem with
File.expand_path. Should be a simple fix:
% jruby -e 'p File.expand_path("/dir1/../")'
""
All other ruby implementations return root, which is correct, rather than the
empty string - if you try to construct a filename from that path, it will be
relative rather than absolute.
Not sure if this is covered by the existing spec in rubinius.
% ruby -e 'p File.expand_path("/dir1/../")'
"/"
% ruby1.9 -e 'p File.expand_path("/dir1/../")'
"/"
% ../../git/rubinius/shotgun/rubinius -e 'p File.expand_path("/dir1/../")'
"/"
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
---------------------------------------------------------------------
To unsubscribe from this list, please visit:
http://xircles.codehaus.org/manage_email