From 3158d6fc128da5a06e30446e8eabb4afa9c53cb6 Mon Sep 17 00:00:00 2001 From: Jim Procter Date: Mon, 17 Oct 2022 12:19:24 +0100 Subject: [PATCH] JAL-2349 JAL-3855 tests that probably should be part of Functional.. --- test/jalview/analysis/AlignmentUtilsTests.java | 33 ++++++++++---------- .../structure/StructureSelectionManagerTest.java | 26 +++++++-------- 2 files changed, 30 insertions(+), 29 deletions(-) diff --git a/test/jalview/analysis/AlignmentUtilsTests.java b/test/jalview/analysis/AlignmentUtilsTests.java index c1eb9fd..8b6f67d 100644 --- a/test/jalview/analysis/AlignmentUtilsTests.java +++ b/test/jalview/analysis/AlignmentUtilsTests.java @@ -27,21 +27,34 @@ import static org.testng.AssertJUnit.assertNull; import static org.testng.AssertJUnit.assertSame; import static org.testng.AssertJUnit.assertTrue; -import jalview.analysis.AlignmentUtils.DnaVariant; +import java.io.IOException; +import java.util.ArrayList; +import java.util.Arrays; +import java.util.LinkedHashMap; +import java.util.List; +import java.util.Map; +import java.util.SortedMap; +import java.util.TreeMap; + +import org.testng.annotations.BeforeClass; +import org.testng.annotations.Test; + import jalview.datamodel.AlignedCodonFrame; import jalview.datamodel.Alignment; import jalview.datamodel.AlignmentAnnotation; import jalview.datamodel.AlignmentI; import jalview.datamodel.Annotation; +import jalview.datamodel.ContactListI; +import jalview.datamodel.ContactMatrixI; import jalview.datamodel.DBRefEntry; import jalview.datamodel.GeneLociI; import jalview.datamodel.Mapping; import jalview.datamodel.SearchResultMatchI; import jalview.datamodel.SearchResultsI; +import jalview.datamodel.SeqDistanceContactMatrix; import jalview.datamodel.Sequence; import jalview.datamodel.SequenceFeature; import jalview.datamodel.SequenceI; -import jalview.datamodel.features.SequenceFeatures; import jalview.gui.JvOptionPane; import jalview.io.AppletFormatAdapter; import jalview.io.DataSourceType; @@ -51,18 +64,6 @@ import jalview.io.FormatAdapter; import jalview.io.gff.SequenceOntologyI; import jalview.util.MapList; import jalview.util.MappingUtils; -import jalview.ws.params.InvalidArgumentException; - -import java.io.IOException; -import java.util.ArrayList; -import java.util.Arrays; -import java.util.LinkedHashMap; -import java.util.List; -import java.util.Map; -import java.util.TreeMap; - -import org.testng.annotations.BeforeClass; -import org.testng.annotations.Test; public class AlignmentUtilsTests { @@ -2457,7 +2458,7 @@ public class AlignmentUtilsTests * the given protein. That is, given a transcript-to-peptide mapping, find the * cds-to-peptide mapping that relates to both, and return the CDS sequence. */ - @Test + @Test(groups = "Functional") public void testFindCdsForProtein() { List mappings = new ArrayList<>(); @@ -2527,7 +2528,7 @@ public class AlignmentUtilsTests * cds-to-peptide mapping that relates to both, and return the CDS sequence. * This test is for the case where transcript and CDS are the same length. */ - @Test + @Test(groups = "Functional") public void testFindCdsForProtein_noUTR() { List mappings = new ArrayList<>(); diff --git a/test/jalview/structure/StructureSelectionManagerTest.java b/test/jalview/structure/StructureSelectionManagerTest.java index 66514f9..aac7b84 100644 --- a/test/jalview/structure/StructureSelectionManagerTest.java +++ b/test/jalview/structure/StructureSelectionManagerTest.java @@ -25,6 +25,18 @@ import static org.testng.Assert.assertNotNull; import static org.testng.AssertJUnit.assertEquals; import static org.testng.AssertJUnit.assertTrue; +import java.util.ArrayList; +import java.util.LinkedHashMap; +import java.util.List; +import java.util.Map; +import java.util.SortedMap; +import java.util.TreeMap; + +import org.testng.Assert; +import org.testng.annotations.BeforeClass; +import org.testng.annotations.BeforeMethod; +import org.testng.annotations.Test; + import jalview.analysis.AlignmentUtils; import jalview.api.structures.JalviewStructureDisplayI; import jalview.bin.Cache; @@ -50,18 +62,6 @@ import jalview.util.MapList; import jalview.ws.DBRefFetcher; import jalview.ws.sifts.SiftsSettings; -import java.util.ArrayList; -import java.util.LinkedHashMap; -import java.util.List; -import java.util.Map; -import java.util.SortedMap; -import java.util.TreeMap; - -import org.testng.Assert; -import org.testng.annotations.BeforeClass; -import org.testng.annotations.BeforeMethod; -import org.testng.annotations.Test; - @Test(singleThreaded = true) public class StructureSelectionManagerTest extends Jalview2xmlBase { @@ -433,7 +433,7 @@ public class StructureSelectionManagerTest extends Jalview2xmlBase AlignmentUtils.findAddableReferenceAnnotations(al.getSequences(), tipEntries, candidates, al); AlignmentUtils.addReferenceAnnotations(candidates, al, null); - + // FAILS BECAUSE LABEL HAS PDB ID STRING if (!al.findAnnotations(seq, null, TEMP_FACTOR_AA).iterator() .hasNext()) { -- 1.7.10.2