Uploaded image for project: 'JDK'
  1. JDK
  2. JDK-8306852

java/awt/Graphics/GetGraphicsTest.java fails after JDK-8306067

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Duplicate
    • Icon: P3 P3
    • None
    • 21
    • client-libs
    • generic
    • generic

      The following test failed in the JDK21 CI:

      java/awt/Graphics/GetGraphicsTest.java

      Here's a snippet from the linux-aarch64 log file:

      #section:main
      ----------messages:(7/269)----------
      command: main GetGraphicsTest
      reason: User specified action: run main GetGraphicsTest
      started: Tue Apr 25 11:54:12 UTC 2023
      Mode: othervm
      Additional options from @modules: --add-modules java.desktop
      finished: Tue Apr 25 11:54:12 UTC 2023
      elapsed time (seconds): 0.455
      ----------configuration:(3/40)----------
      Boot Layer
        add modules: java.desktop

      ----------System.out:(0/0)----------
      ----------System.err:(24/1267)----------
      java.awt.HeadlessException:
      No X11 DISPLAY variable was set,
      or no headful library support was found,
      but this program performed an operation which requires it,

      at java.desktop/java.awt.GraphicsEnvironment.checkHeadless(GraphicsEnvironment.java:166)
      at java.desktop/java.awt.Window.<init>(Window.java:553)
      at java.desktop/java.awt.Frame.<init>(Frame.java:428)
      at java.desktop/java.awt.Frame.<init>(Frame.java:393)
      at GetGraphicsTest.<init>(GetGraphicsTest.java:35)
      at GetGraphicsTest.main(GetGraphicsTest.java:47)
      at java.base/jdk.internal.reflect.DirectMethodHandleAccessor.invoke(DirectMethodHandleAccessor.java:103)
      at java.base/java.lang.reflect.Method.invoke(Method.java:578)
      at com.sun.javatest.regtest.agent.MainWrapper$MainTask.run(MainWrapper.java:138)
      at java.base/java.lang.Thread.run(Thread.java:1592)

      JavaTest Message: Test threw exception: java.awt.HeadlessException:
      No X11 DISPLAY variable was set,
      or no headful library support was found,
      but this program performed an operation which requires it,

      JavaTest Message: shutting down test

      STATUS:Failed.`main' threw exception: java.awt.HeadlessException: No X11 DISPLAY variable was set, or no headful library support was found, but this program performed an operation which requires it,
      ----------rerun:(37/5400)*----------

      The macosx-x64 log is even more on point:

      #section:main
      ----------messages:(7/269)----------
      command: main GetGraphicsTest
      reason: User specified action: run main GetGraphicsTest
      started: Tue Apr 25 12:04:57 GMT 2023
      Mode: othervm
      Additional options from @modules: --add-modules java.desktop
      finished: Tue Apr 25 12:04:58 GMT 2023
      elapsed time (seconds): 0.278
      ----------configuration:(3/40)----------
      Boot Layer
        add modules: java.desktop

      ----------System.out:(0/0)----------
      ----------System.err:(20/1202)----------
      java.awt.HeadlessException:
      The application is not running in a desktop session,
      but this program performed an operation which requires it.
      at java.desktop/java.awt.GraphicsEnvironment.checkHeadless(GraphicsEnvironment.java:166)
      at java.desktop/java.awt.Window.<init>(Window.java:553)
      at java.desktop/java.awt.Frame.<init>(Frame.java:428)
      at java.desktop/java.awt.Frame.<init>(Frame.java:393)
      at GetGraphicsTest.<init>(GetGraphicsTest.java:35)
      at GetGraphicsTest.main(GetGraphicsTest.java:47)
      at java.base/jdk.internal.reflect.DirectMethodHandleAccessor.invoke(DirectMethodHandleAccessor.java:103)
      at java.base/java.lang.reflect.Method.invoke(Method.java:578)
      at com.sun.javatest.regtest.agent.MainWrapper$MainTask.run(MainWrapper.java:138)
      at java.base/java.lang.Thread.run(Thread.java:1592)

      JavaTest Message: Test threw exception: java.awt.HeadlessException:
      The application is not running in a desktop session,
      but this program performed an operation which requires it.
      JavaTest Message: shutting down test

      STATUS:Failed.`main' threw exception: java.awt.HeadlessException: The application is not running in a desktop session, but this program performed an operation which requires it.
      ----------rerun:(36/5647)*----------

            Unassigned Unassigned
            dcubed Daniel Daugherty
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated:
              Resolved: