提交 e9f30601 编写于 作者: R rupashka

7030774: javax/swing/text/CSSBorder/6796710/bug6796710.java test fails against jdk7 b134

Reviewed-by: malenkov
上级 f6240ca8
...@@ -31,6 +31,8 @@ ...@@ -31,6 +31,8 @@
@run main bug6796710 @run main bug6796710
*/ */
import sun.awt.SunToolkit;
import javax.swing.*; import javax.swing.*;
import java.awt.*; import java.awt.*;
import java.awt.image.BufferedImage; import java.awt.image.BufferedImage;
...@@ -91,7 +93,7 @@ public class bug6796710 { ...@@ -91,7 +93,7 @@ public class bug6796710 {
} }
}); });
robot.waitForIdle(); ((SunToolkit) SunToolkit.getDefaultToolkit()).realSync();
BufferedImage bufferedImage = getPnBottomImage(); BufferedImage bufferedImage = getPnBottomImage();
...@@ -101,7 +103,10 @@ public class bug6796710 { ...@@ -101,7 +103,10 @@ public class bug6796710 {
} }
}); });
robot.waitForIdle(); ((SunToolkit) SunToolkit.getDefaultToolkit()).realSync();
// On Linux platforms realSync doesn't guaranties setSize completion
Thread.sleep(1000);
if (!Util.compareBufferedImages(bufferedImage, getPnBottomImage())) { if (!Util.compareBufferedImages(bufferedImage, getPnBottomImage())) {
throw new RuntimeException("The test failed"); throw new RuntimeException("The test failed");
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册