On Wed, 4 Sep 2024 03:34:34 GMT, Alisen Chung <ach...@openjdk.org> wrote:
> Cleaning up tests building ExtendedRobot that shouldn't be. Changes requested by aivanov (Reviewer). test/jdk/javax/swing/JInternalFrame/6725409/bug6725409.java line 1: > 1: /* `frame` should be disposed of on EDT. `TestTitlePane` can be static. test/jdk/javax/swing/JInternalFrame/6725409/bug6725409.java line 44: > 42: private TestTitlePane testTitlePane; > 43: private boolean passed; > 44: private static Robot robot = createRobot(); Suggestion: private static final Robot robot = createRobot(); test/jdk/javax/swing/JInternalFrame/6725409/bug6725409.java line 153: > 151: Robot robot = new Robot(); > 152: return robot; > 153: }catch(Exception ex) { Suggestion: } catch(Exception ex) { And pass the caught exception as the `cause` parameter to `Error` — `ex.printStackTrace()` becomes redundant. ------------- PR Review: https://git.openjdk.org/jdk/pull/20846#pullrequestreview-2317810835 PR Review Comment: https://git.openjdk.org/jdk/pull/20846#discussion_r1768331370 PR Review Comment: https://git.openjdk.org/jdk/pull/20846#discussion_r1768329617 PR Review Comment: https://git.openjdk.org/jdk/pull/20846#discussion_r1768328968