Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix #5129: Use system-dependent path separator #5130

Merged
merged 1 commit into from
Oct 2, 2018
Merged

Fix #5129: Use system-dependent path separator #5130

merged 1 commit into from
Oct 2, 2018

Conversation

melekhove
Copy link
Contributor

No description provided.

Copy link
Member

@dottybot dottybot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hello, and thank you for opening this PR! 🎉

All contributors have signed the CLA, thank you! ❤️

Have an awesome day! ☀️

@@ -12,10 +12,10 @@ final case class TestFlags(
TestFlags(defaultClassPath, runClassPath, options diff flags)

def withClasspath(classPath: String): TestFlags =
TestFlags(s"$defaultClassPath:$classPath", runClassPath, options)
TestFlags(s"$defaultClassPath${sys.props("path.separator")}$classPath", runClassPath, options)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Isn't java.io.File.pathSeparator working?

@@ -54,7 +54,7 @@ trait ParallelTesting extends RunnerOrchestration { self =>
def outDir: JFile
def flags: TestFlags

def runClassPath: String = outDir.getAbsolutePath + ":" + flags.runClassPath
def runClassPath: String = outDir.getAbsolutePath + java.io.File.pathSeparator + flags.runClassPath
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

File is already imported as JFile, please use that.


def withRunClasspath(classPath: String): TestFlags =
TestFlags(defaultClassPath, s"$runClassPath:$classPath", options)
TestFlags(defaultClassPath, s"$runClassPath${java.io.File.pathSeparator}$classPath", options)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I’d prefer if you import File here too (maybe as JFile for consistency).

@Blaisorblade
Copy link
Contributor

And the commit message should be updated (you’re not using a system property); and please say “fix #5129” rather than “fix issue #5129”.

Copy link
Contributor

@Blaisorblade Blaisorblade left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Requesting changes detailed above.

@melekhove melekhove changed the title Fix issue #5129: Use system property for classpath separator Fix #5129: Use system-dependent path-separator Sep 22, 2018
@melekhove melekhove changed the title Fix #5129: Use system-dependent path-separator Fix #5129: Use system-dependent path separator Sep 24, 2018
Copy link
Member

@sjrd sjrd left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks a lot!

It's not completely enough for testCompilation to run successfully on my machine (log) but at least now it does most of it right (as opposed to everything wrong before).

@melekhove
Copy link
Contributor Author

BTW java.nio.file.NoSuchFileException: ...i4947c\Aux.tasty in the log is the result of the #5148

@melekhove
Copy link
Contributor Author

See also #5155 and #5157

@melekhove
Copy link
Contributor Author

And the commit message should be updated (you’re not using a system property); and please say “fix #5129” rather than “fix issue #5129”.
I've made all required changes

@OlivierBlanvillain
Copy link
Contributor

@melekhove Merging, thanks!

@OlivierBlanvillain OlivierBlanvillain merged commit 8cc445b into scala:master Oct 2, 2018
@melekhove melekhove deleted the issue/5129 branch October 3, 2018 04:51
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants