1 |
|
|
2 |
|
|
3 |
|
|
4 |
|
|
5 |
|
|
6 |
|
|
7 |
|
|
8 |
|
|
9 |
|
|
10 |
|
|
11 |
|
|
12 |
|
|
13 |
|
|
14 |
|
|
15 |
|
|
16 |
|
|
17 |
|
|
18 |
|
|
19 |
|
|
20 |
|
|
21 |
|
package jalview.datamodel; |
22 |
|
|
23 |
|
import static org.testng.AssertJUnit.assertEquals; |
24 |
|
import static org.testng.AssertJUnit.assertFalse; |
25 |
|
import static org.testng.AssertJUnit.assertTrue; |
26 |
|
|
27 |
|
import jalview.gui.JvOptionPane; |
28 |
|
|
29 |
|
import org.testng.annotations.BeforeClass; |
30 |
|
import org.testng.annotations.Test; |
31 |
|
|
|
|
| 100% |
Uncovered Elements: 0 (13) |
Complexity: 3 |
Complexity Density: 0.3 |
|
32 |
|
public class AlignedCodonTest |
33 |
|
{ |
34 |
|
|
|
|
| 100% |
Uncovered Elements: 0 (2) |
Complexity: 1 |
Complexity Density: 0.5 |
|
35 |
1 |
@BeforeClass(alwaysRun = true)... |
36 |
|
public void setUpJvOptionPane() |
37 |
|
{ |
38 |
1 |
JvOptionPane.setInteractiveMode(false); |
39 |
1 |
JvOptionPane.setMockResponse(JvOptionPane.CANCEL_OPTION); |
40 |
|
} |
41 |
|
|
|
|
| 100% |
Uncovered Elements: 0 (6) |
Complexity: 1 |
Complexity Density: 0.17 |
1PASS
|
|
42 |
1 |
@Test(groups = { "Functional" })... |
43 |
|
public void testEquals() |
44 |
|
{ |
45 |
1 |
AlignedCodon ac = new AlignedCodon(1, 3, 4); |
46 |
1 |
assertTrue(ac.equals(null)); |
47 |
1 |
assertFalse(ac.equals("hello")); |
48 |
1 |
assertFalse(ac.equals(new AlignedCodon(1, 3, 5))); |
49 |
1 |
assertTrue(ac.equals(new AlignedCodon(1, 3, 4))); |
50 |
1 |
assertTrue(ac.equals(ac)); |
51 |
|
} |
52 |
|
|
|
|
| 100% |
Uncovered Elements: 0 (2) |
Complexity: 1 |
Complexity Density: 0.5 |
1PASS
|
|
53 |
1 |
@Test(groups = { "Functional" })... |
54 |
|
public void testToString() |
55 |
|
{ |
56 |
1 |
AlignedCodon ac = new AlignedCodon(1, 3, 4); |
57 |
1 |
assertEquals("[1, 3, 4]", ac.toString()); |
58 |
|
} |
59 |
|
} |