From a53a89a356aec50368a2c8d7d87a31f45c2048da Mon Sep 17 00:00:00 2001 From: gmungoc Date: Thu, 21 Mar 2019 10:12:06 +0000 Subject: [PATCH] JAL-1889 diagnostics for failing test on server --- test/jalview/util/PlatformTest.java | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/test/jalview/util/PlatformTest.java b/test/jalview/util/PlatformTest.java index 307f450..a9ddfbb 100644 --- a/test/jalview/util/PlatformTest.java +++ b/test/jalview/util/PlatformTest.java @@ -23,10 +23,12 @@ package jalview.util; import static org.testng.Assert.assertFalse; import static org.testng.Assert.assertTrue; +import jalview.bin.Jalview; import jalview.gui.JvOptionPane; import java.awt.Button; import java.awt.Event; +import java.awt.Toolkit; import java.awt.event.MouseEvent; import org.testng.annotations.BeforeClass; @@ -56,6 +58,12 @@ public class PlatformTest int buttonNo = MouseEvent.BUTTON1; boolean mac = true; + assertFalse(Jalview.isHeadlessMode()); + Toolkit toolkit = Toolkit.getDefaultToolkit(); + System.err.println("Toolkit is " + toolkit.getClass().getName()); + System.err.println("getMenuShortcutKeyMask is " + + toolkit.getMenuShortcutKeyMask()); + int mods = 0; // not concerned with MouseEvent id, when, x, y, xAbs, yAbs values assertFalse(Platform.isControlDown(new MouseEvent(b, 0, 0L, mods, 0, 0, -- 1.7.10.2