assertTrue(sq.isProtein());
}
+ @Test(groups = ("Functional"))
+ public void testIsProteinWithXorNAmbiguityCodes()
+ {
+ // test Protein with N - poly asparagine
+ assertTrue(new Sequence("prot", "ASDFASDFASDFNNNNNNNNN").isProtein());
+ assertTrue(new Sequence("prot", "NNNNNNNNNNNNNNNNNNNNN").isProtein());
+ // test Protein with X
+ assertTrue(new Sequence("prot", "ASDFASDFASDFXXXXXXXXX").isProtein());
+ // test DNA with X
+ assertFalse(new Sequence("prot", "ACGTACGTACGTXXXXXXXX").isProtein());
+ // test DNA with N
+ assertFalse(new Sequence("prot", "ACGTACGTACGTNNNNNNNN").isProtein());
+ // test RNA with X
+ assertFalse(new Sequence("prot", "ACGUACGUACGUXXXXXXXXX").isProtein());
+ assertFalse(new Sequence("prot", "ACGUACGUACGUNNNNNNNNN").isProtein());
+ }
+
@Test(groups = { "Functional" })
public void testGetAnnotation()
{