RFR: 8341376: Open some TextArea awt tests 4

Abhishek Kumar abhiscxk at openjdk.org
Thu Oct 10 09:16:14 UTC 2024


On Thu, 10 Oct 2024 01:17:22 GMT, Alisen Chung <achung at openjdk.org> wrote:

> Fourth set of Textarea awt tests to open for fall 2024 test sprint

test/jdk/java/awt/TextArea/ScrollBarArrowScrollTest.java line 32:

> 30:  * @summary Keeping the left arrow pressedon horiz scrollbar
> 31:  *          does not scroll the text in TextArea, XToolkit
> 32:  * @library /open/test/jdk/java/awt/regtesthelpers

Please remove leading `/open/test/jdk` from library path.

test/jdk/java/awt/TextArea/ScrollBarArrowScrollTest.java line 38:

> 36: 
> 37: 
> 38: public class ScrollBarArrowScrollTest extends Frame {

No need to extend the Frame, you can just create a frame in constructor, add the component and return it (Similar to WordWrappingTest).

test/jdk/java/awt/TextArea/ScrollBarArrowScrollTest.java line 40:

> 38: public class ScrollBarArrowScrollTest extends Frame {
> 39:     private static final String INSTRUCTIONS = """
> 40:                 1) Make sure, that the TextArea component has a focus.

Suggestion:

                1) Make sure, that the TextArea component has focus.

test/jdk/java/awt/TextArea/ScrollBarArrowScrollTest.java line 63:

> 61:         add(textarea);
> 62:         setSize(200, 200);
> 63:         pack();

SetSize and pack are redundant. One of them should be enough.

test/jdk/java/awt/TextArea/TextAreaHScrollbarTest.java line 1:

> 1: /*

Looks like few tests are part of https://github.com/openjdk/jdk/pull/21436 PR and wrongly pushed here. Please remove them.

test/jdk/java/awt/TextArea/WordWrappingTest.java line 32:

> 30:  * @bug 4992455
> 31:  * @summary REGRESSION: TextArea does not wrap text in JDK 1.5 as JDK 1.4.x
> 32:  * @library /open/test/jdk/java/awt/regtesthelpers

Remove leading `/open/test/jdk` from library path.

test/jdk/java/awt/TextArea/WordWrappingTest.java line 44:

> 42:                 scrollbars at all.
> 43:                 If their text is not wrapped at word boundaries and you partially see
> 44:                 mentioned text the test failed

Suggestion:

                mentioned text then the test failed

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

PR Review Comment: https://git.openjdk.org/jdk/pull/21438#discussion_r1795020319
PR Review Comment: https://git.openjdk.org/jdk/pull/21438#discussion_r1795025381
PR Review Comment: https://git.openjdk.org/jdk/pull/21438#discussion_r1795021024
PR Review Comment: https://git.openjdk.org/jdk/pull/21438#discussion_r1795026616
PR Review Comment: https://git.openjdk.org/jdk/pull/21438#discussion_r1795028253
PR Review Comment: https://git.openjdk.org/jdk/pull/21438#discussion_r1795029000
PR Review Comment: https://git.openjdk.org/jdk/pull/21438#discussion_r1795030608


More information about the client-libs-dev mailing list