From: Jim Procter Date: Sun, 2 Oct 2016 11:27:30 +0000 (+0100) Subject: JAL-2210 first pass at attempting to fix CrossRef tests due to removal of sequence... X-Git-Tag: Release_2_10_0~20^2~11 X-Git-Url: http://source.jalview.org/gitweb/?a=commitdiff_plain;h=6405be60655fe096cdbff89cccf0a5b12f8b7e80;p=jalview.git JAL-2210 first pass at attempting to fix CrossRef tests due to removal of sequence ID matcher based fallback for discovering crossrefs. --- diff --git a/test/jalview/analysis/CrossRefTest.java b/test/jalview/analysis/CrossRefTest.java index 24ddb34..50f38b6 100644 --- a/test/jalview/analysis/CrossRefTest.java +++ b/test/jalview/analysis/CrossRefTest.java @@ -80,11 +80,11 @@ public class CrossRefTest * Just the protein refs: */ found = DBRefUtils.selectDbRefs(false, refs); - assertEquals(4, found.length); + assertEquals(3, found.length); assertSame(ref1, found[0]); assertSame(ref2, found[1]); assertSame(ref4, found[2]); - assertSame(ref9, found[3]); + // assertSame(ref9, found[3]); ENSEMBL not protein } /** @@ -402,11 +402,14 @@ public class CrossRefTest public void testFindXrefSequences_withFetch() { SequenceI dna1 = new Sequence("AF039662", "GGGGCAGCACAAGAAC"); - dna1.addDBRef(new DBRefEntry("UNIPROT", "0", "Q9ZTS2")); - dna1.addDBRef(new DBRefEntry("UNIPROT", "0", "P30419")); - dna1.addDBRef(new DBRefEntry("UNIPROT", "0", "P00314")); + dna1.addDBRef(new DBRefEntry("UNIPROT", "ENA:0", "Q9ZTS2")); + dna1.addDBRef(new DBRefEntry("UNIPROT", "ENA:0", "P30419")); + dna1.addDBRef(new DBRefEntry("UNIPROT", "ENA:0", "P00314")); final SequenceI pep1 = new Sequence("Q9ZTS2", "MYQLIRSSW"); + pep1.addDBRef(new DBRefEntry("UNIPROT", "0", "Q9ZTS2")); + final SequenceI pep2 = new Sequence("P00314", "MRKLLAASG"); + pep2.addDBRef(new DBRefEntry("UNIPROT", "0", "P00314")); /* * argument false suppresses adding DAS sources @@ -471,7 +474,7 @@ public class CrossRefTest * 'spliced transcript' with CDS ranges */ SequenceI braf002 = new Sequence("ENST00000497784", "gCAGGCtaTCTGTTCaa"); - braf002.addDBRef(new DBRefEntry("UNIPROT", "0", "H7C5K3")); + braf002.addDBRef(new DBRefEntry("UNIPROT", "ENSEMBL|0", "H7C5K3")); braf002.addSequenceFeature(new SequenceFeature("CDS", "", 2, 6, 0f, null)); braf002.addSequenceFeature(new SequenceFeature("CDS", "", 9, 15, 0f, @@ -483,8 +486,9 @@ public class CrossRefTest * which happens to be true for Uniprot,PDB,EMBL but not Pfam,Rfam,Ensembl */ final SequenceI pep1 = new Sequence("UNIPROT|P15056", "MAAL"); + pep1.addDBRef(new DBRefEntry("UNIPROT", "0", "P15056")); final SequenceI pep2 = new Sequence("UNIPROT|H7C5K3", "QALF"); - + pep2.addDBRef(new DBRefEntry("UNIPROT", "0", "H7C5K3")); /* * argument false suppresses adding DAS sources * todo: define an interface type SequenceFetcherI and mock that