assertEquals(Color.magenta, sr.getResidueBoxColour(seq, 5)); // G
assertEquals(Color.orange, sr.getResidueBoxColour(seq, 12)); // F
}
+
+ @Test(groups = { "Functional" })
+ public void testGetResidueBoxColour_none()
+ {
+ SequenceI seq = new Sequence("name", "MA--TVLGSPRAPAFF");
+ AlignmentI al = new Alignment(new SequenceI[] { seq });
+ final AlignViewport av = new AlignViewport(al);
+ SequenceRenderer sr = new SequenceRenderer(av);
+
+ assertEquals(Color.white, sr.getResidueBoxColour(seq, 0));
+ assertEquals(Color.white, sr.getResidueBoxColour(seq, 2));
+
+ // set for overview
+ sr.forOverview = true;
+ assertEquals(Color.lightGray, sr.getResidueBoxColour(seq, 0));
+ assertEquals(Color.white, sr.getResidueBoxColour(seq, 2));
+ }
+
// TODO more tests for getResidueBoxColour covering groups, feature rendering,
// gaps, overview...