{"action":"closed","issue":{"url":"https://api.github.com/repos/jruby/jruby/issues/4612","repository_url":"https://api.github.com/repos/jruby/jruby","labels_url":"https://api.github.com/repos/jruby/jruby/issues/4612/labels{/name}","comments_url":"https://api.github.com/repos/jruby/jruby/issues/4612/comments","events_url":"https://api.github.com/repos/jruby/jruby/issues/4612/events","html_url":"https://github.com/jruby/jruby/issues/4612","id":229536034,"number":4612,"title":"REGRESSION - File.realpath fails on classpath paths","user":{"login":"trejkaz","id":43236,"avatar_url":"https://avatars1.githubusercontent.com/u/43236?v=3","gravatar_id":"","url":"https://api.github.com/users/trejkaz","html_url":"https://github.com/trejkaz","followers_url":"https://api.github.com/users/trejkaz/followers","following_url":"https://api.github.com/users/trejkaz/following{/other_user}","gists_url":"https://api.github.com/users/trejkaz/gists{/gist_id}","starred_url":"https://api.github.com/users/trejkaz/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/trejkaz/subscriptions","organizations_url":"https://api.github.com/users/trejkaz/orgs","repos_url":"https://api.github.com/users/trejkaz/repos","events_url":"https://api.github.com/users/trejkaz/events{/privacy}","received_events_url":"https://api.github.com/users/trejkaz/received_events","type":"User","site_admin":false},"labels":[{"id":302705246,"url":"https://api.github.com/repos/jruby/jruby/labels/regression","name":"regression","color":"e11d21","default":false}],"state":"closed","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":2,"created_at":"2017-05-18T02:14:10Z","updated_at":"2017-05-30T03:35:40Z","closed_at":"2017-05-30T03:35:40Z","body":"### Environment\r\n\r\nJRuby 9.1.9.0\r\n*Windows only*\r\n\r\n### Test Case\r\n\r\n    @Test\r\n    public void testResolveClasspath() throws Exception\r\n    {\r\n        ScriptEngine engine = createEngine();\r\n\r\n        String path = \"classpath:/path/to/this/TestRubyFile.class\";\r\n        String result = (String) engine.eval(\"File.realpath('\" + path + \"')\");\r\n        assertThat(result, is(equalTo(path)));\r\n    }\r\n\r\n    protected ScriptEngine createEngine()\r\n    {\r\n        return new JRubyEngineFactory().getScriptEngine();\r\n    }\r\n\r\n### Expected Behavior\r\n\r\nTest should pass, like it did on JRuby 9.0.5.0.\r\n\r\n### Actual Behavior\r\n\r\nTest now fails:\r\n\r\n    Caused by: org.jruby.exceptions.RaiseException: (Errno::ENOENT) classpath:BY\\path\\to\\this\\TestRubyFile.class\r\n\tat org.jruby.RubyFile.realpath(org/jruby/RubyFile.java:864)\r\n\tat RUBY.<main>(<script>:1)\r\n\r\nI'm not sure where it pulled the \"BY\\\" from, but the slashes are in the wrong direction too.\r\n"}}
{"actor":{"display_login":"trejkaz"}}