Skip to content

Commit

Permalink
7030774: javax/swing/text/CSSBorder/6796710/bug6796710.java test fail…
Browse files Browse the repository at this point in the history
…s against jdk7 b134

Reviewed-by: malenkov
  • Loading branch information
rupashka committed Apr 13, 2011
1 parent bf0116f commit 48203fb
Showing 1 changed file with 7 additions and 2 deletions.
9 changes: 7 additions & 2 deletions test/javax/swing/text/CSSBorder/6796710/bug6796710.java
Expand Up @@ -31,6 +31,8 @@
@run main bug6796710
*/

import sun.awt.SunToolkit;

import javax.swing.*;
import java.awt.*;
import java.awt.image.BufferedImage;
Expand Down Expand Up @@ -91,7 +93,7 @@ public void run() {
}
});

robot.waitForIdle();
((SunToolkit) SunToolkit.getDefaultToolkit()).realSync();

BufferedImage bufferedImage = getPnBottomImage();

Expand All @@ -101,7 +103,10 @@ public void run() {
}
});

robot.waitForIdle();
((SunToolkit) SunToolkit.getDefaultToolkit()).realSync();

// On Linux platforms realSync doesn't guaranties setSize completion
Thread.sleep(1000);

if (!Util.compareBufferedImages(bufferedImage, getPnBottomImage())) {
throw new RuntimeException("The test failed");
Expand Down

0 comments on commit 48203fb

Please sign in to comment.