From: tcofoegbu Date: Fri, 26 Feb 2016 10:41:27 +0000 (+0000) Subject: JAL-1994 fix for broken tests X-Git-Tag: Release_2_10_0~307 X-Git-Url: http://source.jalview.org/gitweb/?a=commitdiff_plain;h=3fab3c719c7954ef6460764379b559773af4b92b;p=jalview.git JAL-1994 fix for broken tests --- diff --git a/src/jalview/viewmodel/AlignmentViewport.java b/src/jalview/viewmodel/AlignmentViewport.java index 7bbe677..3c69961 100644 --- a/src/jalview/viewmodel/AlignmentViewport.java +++ b/src/jalview/viewmodel/AlignmentViewport.java @@ -1557,7 +1557,9 @@ public abstract class AlignmentViewport implements AlignViewportI, } else { - if (alignment.getHiddenSequences() != null) + HiddenSequences hiddenSeqs = alignment.getHiddenSequences(); + if (hiddenSeqs != null && hiddenSeqs.hiddenSequences != null + && hiddenSeqs.hiddenSequences.length > 0) { iSize = alignment.getHiddenSequences().getFullAlignment() .getHeight(); diff --git a/test/jalview/analysis/TestAlignSeq.java b/test/jalview/analysis/TestAlignSeq.java index d6342ef..43ebd63 100644 --- a/test/jalview/analysis/TestAlignSeq.java +++ b/test/jalview/analysis/TestAlignSeq.java @@ -119,7 +119,7 @@ public class TestAlignSeq String expected = "Score = 320\nLength of alignment = 10\nSequence Seq1 : 3 - 18 (Sequence length = 14)\nSequence Seq1 : 1 - 10 (Sequence length = 10)\n\n" + "Seq1 SDFAQQQRRR\n" + " ||||||| \n" - + "Seq1 SDFAQQQSSS\n\n" + "Percentage ID = 70.00\n\n"; + + "Seq1 SDFAQQQSSS\n\n" + "Percentage ID = 70.00\n"; assertEquals(expected, baos.toString()); } }