From ef0288b7a00ee17ffa92e80bbd808508d567e7e2 Mon Sep 17 00:00:00 2001 From: Jim Procter Date: Fri, 29 Jul 2016 17:37:32 +0100 Subject: [PATCH] =?utf8?q?JAL-1772=20JAL-2164=20make=20expanded=20view=20sav?= =?utf8?q?e/restore=20test=20pass=20when=20run=20in=20isolation=20(problem=20?= =?utf8?q?may=20be=20that=20load=20returns=20an=20alignFrame=20that=20isn=E2?= =?utf8?q?=80=99t=20actually=20the=20one=20shown=20in=20the=20desktop=E2=80=A6?= =?utf8?q?)?= MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit --- test/jalview/io/Jalview2xmlTests.java | 25 ++++--------------------- 1 file changed, 4 insertions(+), 21 deletions(-) diff --git a/test/jalview/io/Jalview2xmlTests.java b/test/jalview/io/Jalview2xmlTests.java index 38153df..26fba58 100644 --- a/test/jalview/io/Jalview2xmlTests.java +++ b/test/jalview/io/Jalview2xmlTests.java @@ -364,9 +364,7 @@ public class Jalview2xmlTests } /** - * test store and recovery of expanded views - currently this is disabled - * since the Desktop.explodeViews method doesn't seem to result in the views - * being expanded to distinct align frames when executed programmatically. + * test store and recovery of expanded views * * @throws Exception */ @@ -377,24 +375,9 @@ public class Jalview2xmlTests "examples/exampleFile_2_7.jar", FormatAdapter.FILE); assertTrue("Didn't read in the example file correctly.", af != null); String afid = af.getViewport().getSequenceSetId(); - { - final AlignFrame xaf = af; - af = null; - new Thread(new Runnable() - { - @Override - public void run() - { - Desktop.instance.explodeViews(xaf); - } - }).start(); - Thread.sleep(1000); - } - // int times = 0; - // while (++times < 5 && Desktop.getAlignFrames().length < ) - // { - // Thread.sleep(300); - // } + + Desktop.explodeViews(Desktop.getAlignFrameFor(af.getViewport())); + int oldviews = Desktop.getAlignFrames().length; Assert.assertEquals(Desktop.getAlignFrames().length, Desktop.getAlignmentPanels(afid).length); -- 1.7.10.2