8190861: [TESTBUG] javax/swing/JWindow/ShapedAndTranslucentWindows/PerPixelTranslucentSwing.java is wrong

Reviewed-by: serb, psadhukhan
This commit is contained in:
Pankaj Bansal 2017-11-28 16:27:23 +05:30 committed by Pankaj Bansal
parent 2f2dc51f00
commit 360ce25e95

@ -90,7 +90,7 @@ public class PerPixelTranslucentSwing extends Common {
Color color = robot.getPixelColor(loc.x + bounds.width / 2, loc.y + bounds.height + 3);
System.out.println(color);
if (FG_COLOR.getRGB() == color.getRGB())
if (BG_COLOR.getRGB() != color.getRGB())
throw new RuntimeException("Background is not translucent (" + color + ")");
EventQueue.invokeAndWait(this::dispose);