JDK-8204588 : Test failures after "Launch Single-File Source-Code Programs"
  • Type: Bug
  • Component: tools
  • Sub-Component: launcher
  • Affected Version: 11
  • Priority: P3
  • Status: Resolved
  • Resolution: Fixed
  • Submitted: 2018-06-08
  • Updated: 2018-06-19
  • Resolved: 2018-06-08
The Version table provides details related to the release that this issue/RFE will be addressed.

Unresolved : Release in which this issue/RFE will be addressed.
Resolved: Release in which this issue/RFE has been resolved.
Fixed : Release in which this issue/RFE has been fixed. The release containing this fix may be available for download as an Early Access Release or a General Availability Release.

To download the current JDK release, click here.
JDK 11
11 b18Fixed
Related Reports
Relates :  
Relates :  
Sub Tasks
JDK-8204589 :  
Description
test/jdk/tools/launcher/SourceMode.java (linux and OS X)
test/langtools/tools/javac/launcher/SourceLauncherTest.java (Win)

See comments for link to test results.
Comments
One of the tests fails because of failure to take the Windows file separator into account. Easy fix. The other test fails because of the (very) long paths to the Java executable when the test is executed on some platforms (such as the Oracle build-and-test infrastructure). When the path is written into the shebang file for a test case, we may exceed the typical silent restriction of 120 characters for the shebang line. This leads to the shell silently truncating the line, and misinterpreting the contents as a result. Depending on where the truncation occurs, this can show up as "file not found" or "unrecognized option" etc. For now, the solution is to skip the test cases when the path to the Java executable is "too long".
08-06-2018