RFR: 8328716: [TestBug] Screen capturing utility for failed tests
Andy Goryachev
angorya at openjdk.org
Mon Mar 31 15:06:55 UTC 2025
On Fri, 28 Mar 2025 21:07:21 GMT, Kevin Rushforth <kcr at openjdk.org> wrote:
>> 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)
>
> tests/system/src/test/java/test/util/ScreenCaptureTestWatcher.java line 64:
>
>> 62: * <p>
>> 63: * WARNING: using this utility may significantly increase the size of your logs!
>> 64: * Make sure there is plenty of free disk space.
>
> Given my earlier comment about this needing to be qualified by a system property, this comment should also go in `build.gradle` where the property is defined.
see the earlier comment about the intermittent tests
-------------
PR Review Comment: https://git.openjdk.org/jfx/pull/1746#discussion_r2021228036
More information about the openjfx-dev
mailing list