RFR: 8346581: JRadioButton/ButtonGroupFocusTest.java fails in CI on Linux [v2]

Damon Nguyen dnguyen at openjdk.org
Thu Jan 9 19:19:01 UTC 2025


On Thu, 9 Jan 2025 19:10:21 GMT, Alexey Ivanov <aivanov at openjdk.org> wrote:

>> test/jdk/javax/swing/JRadioButton/ButtonGroupFocus/ButtonGroupFocusTest.java line 121:
>> 
>>> 119:                                                + "\n\t" + evt.getNewValue());
>>> 120:                         }
>>> 121:                     });
>> 
>> Suggestion:
>> 
>>                     evt -> System.out.println(evt.getPropertyName()
>>                                                + "\n\t" + evt.getOldValue()
>>                                                + "\n\t" + evt.getNewValue()));
>> 
>> 
>> Nit. Possible lambda replacement here.
>
> My IDE didn't suggest replacing it a lambda. Does it improve readability of the code? Perhaps, it does… by reducing the number of lines.

Not by much if it does. I got into the habit of looking for where it's possible since reducing the line count usually makes it more readable.

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

PR Review Comment: https://git.openjdk.org/jdk/pull/22977#discussion_r1909319106


More information about the client-libs-dev mailing list