RFR: 8316056: Open source several Swing JTree tests
Alexey Ivanov
aivanov at openjdk.org
Mon Sep 18 14:24:46 UTC 2023
On Thu, 14 Sep 2023 21:40:55 GMT, Damon Nguyen <dnguyen at openjdk.org> wrote:
> These are the tests being converted:
>
> javax/swing/JTree/4210432/bug4210432.java
> javax/swing/JTree/4213868/bug4213868.java
> javax/swing/JTree/4224491/bug4224491.java
> javax/swing/JTree/4237370/bug4237370.java
> javax/swing/JTree/4662505/bug4662505.java
test/jdk/javax/swing/JTree/bug4213868.java line 50:
> 48:
> 49: public static void main(String[] args) throws InterruptedException,
> 50: InvocationTargetException {
Suggestion:
public static void main(String[] args) throws Exception {
test/jdk/javax/swing/JTree/bug4213868.java line 54:
> 52: JTree parent = createTree();
> 53: AccessibleContext c = parent.getAccessibleContext()
> 54: .getAccessibleChild(0).getAccessibleContext();
Suggestion:
AccessibleContext c = parent.getAccessibleContext()
.getAccessibleChild(0)
.getAccessibleContext();
test/jdk/javax/swing/JTree/bug4213868.java line 56:
> 54: .getAccessibleChild(0).getAccessibleContext();
> 55: if (c.getAccessibleChild(1).getAccessibleContext()
> 56: .getAccessibleIndexInParent() != 1) {
Suggestion:
if (c.getAccessibleChild(1)
.getAccessibleContext()
.getAccessibleIndexInParent() != 1) {
However, it doesn't look as good as the above.
test/jdk/javax/swing/JTree/bug4224491.java line 43:
> 41:
> 42: public static void main(String[] args) throws InterruptedException,
> 43: InvocationTargetException {
Suggestion:
public static void main(String[] args) throws Exception {
test/jdk/javax/swing/JTree/bug4237370.java line 56:
> 54: }
> 55:
> 56: public void treeExpanded (TreeExpansionEvent e) {
Suggestion:
public void treeExpanded(TreeExpansionEvent e) {
-------------
PR Review Comment: https://git.openjdk.org/jdk/pull/15756#discussion_r1328796256
PR Review Comment: https://git.openjdk.org/jdk/pull/15756#discussion_r1328792464
PR Review Comment: https://git.openjdk.org/jdk/pull/15756#discussion_r1328794420
PR Review Comment: https://git.openjdk.org/jdk/pull/15756#discussion_r1328796778
PR Review Comment: https://git.openjdk.org/jdk/pull/15756#discussion_r1328801475
More information about the client-libs-dev
mailing list