RFR: 8023263: [TESTBUG] Test closed/java/awt/Focus/InactiveWindowTest/InactiveFocusRace fails due to not enough time to initialize graphic components [v2]
Prasanta Sadhukhan
psadhukhan at openjdk.org
Thu Sep 11 05:15:49 UTC 2025
On Thu, 11 Sep 2025 02:41:34 GMT, Sergey Bylokhov <serb at openjdk.org> wrote:
>> Test does
>> - renders inactiveFrame
>> - renders activeFrame
>> - wait for active frame to be active
>> - press on second button in inactive frame
>> - wait for second button should be focus owner
>> - Check Button2 should be the focus owner
>>
>> I think the current test is also doing the same even now..
>
>>All the semaphore logic is still the same after that
>
> My point is that this logic is wrong. It should first check that the first window has become visible, then the second window, and only after that start the test execution. In this case, no additional changes would be necessary, or am I missing something?
ok..updated..
Guess CountDownLatch would have been more apt but continues with existing semaphore logic..
-------------
PR Review Comment: https://git.openjdk.org/jdk/pull/27156#discussion_r2338597834
More information about the client-libs-dev
mailing list