X-Git-Url: http://source.jalview.org/gitweb/?a=blobdiff_plain;f=test%2Fjalview%2Fio%2FJalview2xmlTests.java;h=e1bc3ae362bb048e2da0d233acf6ecae0f924b24;hb=0f40a8334651302a74a223ecd3e583451302bb42;hp=915625f2672cfdaaa87d615c614fbf9fef87a34c;hpb=74d1897e700018c3a1eb01b6d6ed94f26b171824;p=jalview.git diff --git a/test/jalview/io/Jalview2xmlTests.java b/test/jalview/io/Jalview2xmlTests.java index 915625f..e1bc3ae 100644 --- a/test/jalview/io/Jalview2xmlTests.java +++ b/test/jalview/io/Jalview2xmlTests.java @@ -41,10 +41,13 @@ import jalview.gui.Desktop; import jalview.gui.Jalview2XML; import jalview.schemes.AnnotationColourGradient; import jalview.schemes.ColourSchemeI; +import jalview.structure.StructureImportSettings; import jalview.viewmodel.AlignmentViewport; import java.io.File; +import java.time.Instant; import java.util.ArrayList; +import java.util.Date; import java.util.HashMap; import java.util.List; import java.util.Map; @@ -67,6 +70,9 @@ public class Jalview2xmlTests { jalview.bin.Jalview.main(new String[] { "-props", "test/jalview/io/testProps.jvprops" }); + jalview.bin.Cache.setProperty("JALVIEW_NEWS_RSS_LASTMODIFIED", + Cache.date_format.format(Date.from(Instant.now().plusSeconds( + 3600)))); } /** @@ -270,10 +276,11 @@ public class Jalview2xmlTests @Test(groups = { "Functional" }) public void viewRefPdbAnnotation() throws Exception { - Cache.applicationProperties.setProperty("STRUCT_FROM_PDB", - Boolean.TRUE.toString()); - Cache.applicationProperties.setProperty("ADD_SS_ANN", - Boolean.TRUE.toString()); + // TODO: Make this pass without setting StructureParser.JALVIEW_PARSER + // StructureImportSettings + // .setDefaultPDBFileParser(StructureParser.JALVIEW_PARSER); + StructureImportSettings.setProcessSecondaryStructure(true); + StructureImportSettings.setVisibleChainAnnotation(true); AlignFrame af = new jalview.io.FileLoader().LoadFileWaitTillLoaded( "examples/exampleFile_2_7.jar", FormatAdapter.FILE); assertTrue("Didn't read in the example file correctly.", af != null); @@ -371,10 +378,12 @@ public class Jalview2xmlTests @Test(groups = { "Functional" }, enabled = true) public void testStoreAndRecoverExpandedviews() throws Exception { + Desktop.instance.closeAll_actionPerformed(null); AlignFrame af = new jalview.io.FileLoader().LoadFileWaitTillLoaded( "examples/exampleFile_2_7.jar", FormatAdapter.FILE); assertTrue("Didn't read in the example file correctly.", af != null); + Assert.assertEquals(Desktop.getAlignFrames().length, 1); String afid = af.getViewport().getSequenceSetId(); // check FileLoader returned a reference to the one alignFrame that is