JDK-8246099 : Intermittent test failures in SandboxAppTest
  • Type: Bug
  • Component: javafx
  • Sub-Component: application-lifecycle
  • Affected Version: 8,openjfx15
  • Priority: P4
  • Status: Resolved
  • Resolution: Fixed
  • Submitted: 2020-05-28
  • Updated: 2020-10-27
  • Resolved: 2020-05-29
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 8 Other
8u271Fixed openjfx11.0.9Fixed
Related Reports
Relates :  
Description
I occasionally see these test failures on Windows:

> Task :systemTests:test

test.sandbox.SandboxAppTest > testFXApp FAILED
    junit.framework.AssertionFailedError: test.sandbox.app.FXApp: Application timeout
        at test.sandbox.SandboxAppTest.runSandboxedApp(SandboxAppTest.java:83)
        at test.sandbox.SandboxAppTest.runSandboxedApp(SandboxAppTest.java:52)
        at test.sandbox.SandboxAppTest.testFXApp(SandboxAppTest.java:105)

Gradle Test Executor 118 finished executing tests.

> Task :systemTests:test

test.sandbox.SandboxAppTest > testFXNonApp FAILED
    junit.framework.AssertionFailedError: test.sandbox.app.FXNonApp: Application timeout
        at test.sandbox.SandboxAppTest.runSandboxedApp(SandboxAppTest.java:83)
        at test.sandbox.SandboxAppTest.runSandboxedApp(SandboxAppTest.java:52)
        at test.sandbox.SandboxAppTest.testFXNonApp(SandboxAppTest.java:110)

Comments
Changeset: 168b7f79 Author: Kevin Rushforth <kcr@openjdk.org> Date: 2020-05-29 18:32:21 +0000 URL: https://git.openjdk.java.net/jfx/commit/168b7f79
29-05-2020

The failure is happening because of a 10 second timeout in the launched application. This doesn't seem to be enough to run the test to completion in all cases. I note that the similar launched apps, such as those launched by MainLauncherTest, ModuleLauncherTest, and JarLauncherTest don't have a timeout (they just rely on the timeout value of the launching test itself). The app timeout was just added to prevent the test suite from hanging if the application were to get stuck, so there is no need for it to be such a small value (nor to have it be less than the test timeout). The proposed solution is to increase the app timeout to 30 seconds (up from 10) and the test timeout to 25 (up from 15).
28-05-2020