[ https://issues.apache.org/jira/browse/SUREFIRE-1593?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16680062#comment-16680062 ]
ASF GitHub Bot commented on SUREFIRE-1593: ------------------------------------------ Tibor17 commented on a change in pull request #198: [SUREFIRE-1593] Correcting relativization logic to produce valid URIs on Windows URL: https://github.com/apache/maven-surefire/pull/198#discussion_r231991410 ########## File path: maven-surefire-common/src/main/java/org/apache/maven/plugin/surefire/booterclient/JarManifestForkConfiguration.java ########## @@ -150,10 +150,9 @@ private static String toClasspathElementUri( @Nonnull Path parent, { try { - return new URI( null, - parent.relativize( classPathElement.toPath() ).toString(). - replace( File.separatorChar, '/' ), - null ).toASCIIString(); + Path relativePath = parent.relativize( classPathElement.toPath() ); Review comment: @jglick There is one IT test `Surefire855AllowFailsafeUseArtifactFileIT` which asserts Class-Path in manifest and surefire.properties, but it's hard to develop such test running on any platform and with any number of disks. Even in our case, using ASF Jenkins CI, we have workspace on `F:\` but the TEMP is on `C:\`. ---------------------------------------------------------------- This is an automated message from the Apache Git Service. To respond to the message, please log on GitHub and use the URL above to go to the specific comment. For queries about this service, please contact Infrastructure at: us...@infra.apache.org > 3.0.0-M1 produces invalid code sources on Windows > ------------------------------------------------- > > Key: SUREFIRE-1593 > URL: https://issues.apache.org/jira/browse/SUREFIRE-1593 > Project: Maven Surefire > Issue Type: Bug > Components: classloading, process forking > Affects Versions: 3.0.0-M1 > Reporter: Jesse Glick > Priority: Major > > The fix for SUREFIRE-1588 did not work correctly on Windows. (When > active—i.e., when the drive letters of the system temporary directory, per > SUREFIRE-1400, and the project basedir were the same.) It would produce > relative URIs containing {{%5C}} where {{/}} was intended. -- This message was sent by Atlassian JIRA (v7.6.3#76005)