X-Git-Url: http://source.jalview.org/gitweb/?a=blobdiff_plain;f=test%2Fjalview%2Fschemes%2FResiduePropertiesTest.java;h=28f39d858012fbd9df809ec33b54494c53c07628;hb=d0aee5b0b2cbd0805c3dec027c6f2d2ac0148e66;hp=be6a10c9b53f3ad8f9a3d1112ec9ed1eb876d39e;hpb=a0559d1b4aa6c156f413cde0e7ae5c877cb3cbdb;p=jalview.git diff --git a/test/jalview/schemes/ResiduePropertiesTest.java b/test/jalview/schemes/ResiduePropertiesTest.java index be6a10c..28f39d8 100644 --- a/test/jalview/schemes/ResiduePropertiesTest.java +++ b/test/jalview/schemes/ResiduePropertiesTest.java @@ -27,11 +27,21 @@ import java.util.Collections; import java.util.List; import java.util.Map; +import org.testng.annotations.BeforeClass; import org.testng.annotations.Test; +import jalview.gui.JvOptionPane; + public class ResiduePropertiesTest { + @BeforeClass(alwaysRun = true) + public void setUpJvOptionPane() + { + JvOptionPane.setInteractiveMode(false); + JvOptionPane.setMockResponse(JvOptionPane.CANCEL_OPTION); + } + /** * Test 'standard' codon translations (no ambiguity codes) */ @@ -212,7 +222,8 @@ public class ResiduePropertiesTest */ residues = ResidueProperties.getResidues(true, true); Collections.sort(residues); - assertEquals("[A, C, G, I, N, R, T, U, X, Y]", residues.toString()); + assertEquals("[A, B, C, D, G, H, I, K, M, N, R, S, T, U, V, W, X, Y]", + residues.toString()); } @Test(groups = { "Functional" }) @@ -1559,6 +1570,16 @@ public class ResiduePropertiesTest } @Test(groups = { "Functional" }) + public void testGetDssp3State() + { + assertNull(ResidueProperties.getDssp3state(null)); + assertEquals("", ResidueProperties.getDssp3state("")); + String foo = "0123 []<>abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ"; + String bar = " E E HHH "; + assertEquals(bar, ResidueProperties.getDssp3state(foo)); + } + + @Test(groups = { "Functional" }) public void testPhysicoChemicalProperties() { checkProperty("aromatic", "FYWH-*");