From: Jim Procter Date: Sat, 13 Aug 2016 15:59:34 +0000 (+0100) Subject: JAL-2154 check if the desktop is constructed before trying to clear it ! X-Git-Tag: Release_2_10_0~47^2~4^2~43^2~48 X-Git-Url: http://source.jalview.org/gitweb/?a=commitdiff_plain;h=ef3475e9a95da7e3af80ae155b1b14069311645c;p=jalview.git JAL-2154 check if the desktop is constructed before trying to clear it ! --- diff --git a/test/jalview/io/Jalview2xmlBase.java b/test/jalview/io/Jalview2xmlBase.java index d774f87..1ec34e4 100644 --- a/test/jalview/io/Jalview2xmlBase.java +++ b/test/jalview/io/Jalview2xmlBase.java @@ -41,7 +41,10 @@ public class Jalview2xmlBase @BeforeTest(alwaysRun = true) public static void clearDesktop() { - Desktop.instance.closeAll_actionPerformed(null); + if (Desktop.instance != null && Desktop.getAlignFrames() != null) + { + Desktop.instance.closeAll_actionPerformed(null); + } } public int countDsAnn(jalview.viewmodel.AlignmentViewport avp)