RFR: 8328716: [TestBug] Screen capturing utility for failed tests

Andy Goryachev angorya at openjdk.org
Fri Mar 28 18:40:01 UTC 2025


Introduce a facility, in the form of JUnit5 annotation, to allow for capturing a desktop screenshot of a failed test.

The primary intent is to be able to debug an intermittent test case, rather than wholesale addition of the new annotation to all the tests.

A possible improvement could be to output a data URL

`data:image/png;base64,iVBORw0KGgoAAAANSUhEU...`

so it can be rendered in Safari (Chrome truncates the image possibly due to following a url length limit)

-------------

Commit messages:
 - prefix
 - Merge remote-tracking branch 'origin/master' into 8328716.screenshots
 - Merge remote-tracking branch 'origin/master' into 8328716.screenshots
 - Merge branch 'master' into 8328716.screenshots
 - Merge branch 'master' into 8328716.screenshots
 - capture all pixels
 - Merge branch 'master' into 8328716.screenshots
 - 8328716: [TestBug] Screen capturing utility for failed tests

Changes: https://git.openjdk.org/jfx/pull/1746/files
  Webrev: https://webrevs.openjdk.org/?repo=jfx&pr=1746&range=00
  Issue: https://bugs.openjdk.org/browse/JDK-8328716
  Stats: 118 lines in 2 files changed: 117 ins; 0 del; 1 mod
  Patch: https://git.openjdk.org/jfx/pull/1746.diff
  Fetch: git fetch https://git.openjdk.org/jfx.git pull/1746/head:pull/1746

PR: https://git.openjdk.org/jfx/pull/1746


More information about the openjfx-dev mailing list