8213120: java/awt/TextArea/AutoScrollOnSelectAndAppend/AutoScrollOnSelectAndAppend.java fails on mac10.13

Reviewed-by: psadhukhan
This commit is contained in:
Jayathirth D V 2021-10-27 09:29:37 +00:00
parent 9e831bccd2
commit 2f979ecb5b
2 changed files with 6 additions and 5 deletions

View File

@ -494,7 +494,6 @@ java/awt/Modal/ModalFocusTransferTests/FocusTransferDialogsDocModalTest.java 816
java/awt/im/memoryleak/InputContextMemoryLeakTest.java 8023814 linux-all
java/awt/Frame/DisposeParentGC/DisposeParentGC.java 8079786 macosx-all
java/awt/FullScreen/NoResizeEventOnDMChangeTest/NoResizeEventOnDMChangeTest.java 8169468 macosx-all
java/awt/TextArea/AutoScrollOnSelectAndAppend/AutoScrollOnSelectAndAppend.java 8213120 macosx-all
java/awt/GraphicsDevice/DisplayModes/CycleDMImage.java 7099223,8274106 macosx-aarch64,linux-all,windows-all
java/awt/Window/WindowResizing/DoubleClickTitleBarTest.java 8233557 macosx-all

View File

@ -101,12 +101,14 @@ public class AutoScrollOnSelectAndAppend {
public AutoScrollOnSelectAndAppend() {
try {
robot = new Robot();
robot.setAutoDelay(100);
} catch (Exception ex) {
throw new RuntimeException("Robot Creation Failed.");
}
frame = new Frame();
frame.setSize(200, 200);
frame.setLayout(new FlowLayout());
frame.setLocationRelativeTo(null);
textArea = new TextArea(5, 20);
composeTextArea();
@ -128,11 +130,11 @@ public class AutoScrollOnSelectAndAppend {
// Delay to make sure auto scroll is finished.
robot.waitForIdle();
robot.delay(500);
robot.mousePress(InputEvent.BUTTON1_MASK);
robot.mouseRelease(InputEvent.BUTTON1_MASK);
robot.mousePress(InputEvent.BUTTON1_DOWN_MASK);
robot.mouseRelease(InputEvent.BUTTON1_DOWN_MASK);
robot.delay(100);
robot.mousePress(InputEvent.BUTTON1_MASK);
robot.mouseRelease(InputEvent.BUTTON1_MASK);
robot.mousePress(InputEvent.BUTTON1_DOWN_MASK);
robot.mouseRelease(InputEvent.BUTTON1_DOWN_MASK);
robot.waitForIdle();
}