On Thu, 29 May 2025 01:47:47 GMT, Harshitha Onkar <hon...@openjdk.org> wrote:

>> CopyAreaOOB.java was failing intermittently on some platforms on CI but 
>> recently it started to fail more frequently on macos-aarch64 when the entire 
>> test suite runs.
>> 
>> Test failure is not reproducible when the test is run individually (multiple 
>> times) on CI.
>> 
>> Rewritten the test and added debug logs that will be helpful to figure out 
>> the issue. 
>> 
>> - Added code to capture screenshot (entire screen as well as the frame) in 
>> case of failure.
>> - Since it tests multiple regions added a StringBuffer to consolidate the 
>> error logs before throwing RuntimeException.
>
> Harshitha Onkar has updated the pull request incrementally with one 
> additional commit since the last revision:
> 
>   minor update

test/jdk/java/awt/Graphics2D/CopyAreaOOB.java line 57:

> 55:         // copy the region such that part of it goes below the bottom of 
> the
> 56:         // destination surface
> 57:         g2d.copyArea(0, 10, 50, h-10, 60, 10);

The new version looks like a different test, previously we copyArea from the 
paint method for the awt frame, then call sync to flush all rendering, then 
check the rendering on screen, and all of that on "each render frame".

Now it will draw everything in paint then sometime later(or even after a few 
repaints) we check the actual rendering(waitForIdle/delay(100))....

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

PR Review Comment: https://git.openjdk.org/jdk/pull/25279#discussion_r2113703881

Reply via email to