RFR: 8346234: javax/swing/text/DefaultEditorKit/4278839/bug4278839.java still fails in CI
Alexander Zuev
kizune at openjdk.org
Mon Dec 16 19:22:37 UTC 2024
On Mon, 16 Dec 2024 16:46:10 GMT, Prasanta Sadhukhan <psadhukhan at openjdk.org> wrote:
> Test seem to fail in CI due to caret position not in expected position after pressing VK_RIGHT/VK_LEFT.
> Added some log which shows the same
>
>
> passed1 moveCaret1 true
> passed2 moveCaret5 true
> passed3 moveCaret8 true
> passed4 moveCaret9 false
> passed5 moveCaret13 false
> passed6 moveCaret16 false
> passed7 moveCaret17 false
>
>
> Added some delay for this slow system..Tested to pass in several systems..link in JBS
test/jdk/javax/swing/text/DefaultEditorKit/4278839/bug4278839.java line 71:
> 69:
> 70: passed &= moveCaret(true) == 1;
> 71: System.out.println("passed1 moveCaret1 " + passed);
If you are trying to get more information here why not logging the actual position of the caret after the move? Either inside the moveCaret() method or just add a new variable like
`int caret;`
And then every time you do the test you assign it.
`passed &= (caret = moveCaret(true)) == 1;`
and then you can just output the new caret position after each iteration like "Expected position 1 actual position " + caret.
-------------
PR Review Comment: https://git.openjdk.org/jdk/pull/22768#discussion_r1887371569
More information about the client-libs-dev
mailing list