aufgeräumt
This commit is contained in:
parent
84a9c18a14
commit
c438beca4c
@ -10,7 +10,7 @@ import static org.junit.Assert.*;
|
||||
|
||||
public class CharCollectionTest2 {
|
||||
|
||||
CharCollection a, b, c, d;
|
||||
private CharCollection a, b, c, d;
|
||||
|
||||
@Before
|
||||
public void setUp()
|
||||
@ -56,10 +56,10 @@ public class CharCollectionTest2 {
|
||||
|
||||
@Test
|
||||
public void Vergleich(){
|
||||
assertTrue(a.equals(c));
|
||||
assertTrue(b.equals(new CharCollection("CCEHHHLOSU")));
|
||||
assertFalse(b.equals(new CharCollection("CEHLOSU")));
|
||||
assertTrue(d.equals(new CharCollection("")));
|
||||
assertEquals(a, c);
|
||||
assertEquals(b, new CharCollection("CCEHHHLOSU"));
|
||||
assertNotEquals(b, new CharCollection("CEHLOSU"));
|
||||
assertEquals(d, new CharCollection(""));
|
||||
}
|
||||
|
||||
@Test
|
||||
@ -83,23 +83,23 @@ public class CharCollectionTest2 {
|
||||
|
||||
@Test
|
||||
public void Mindestens(){
|
||||
assertTrue(a.moreThan(1).equals(new CharCollection("AAANN")));
|
||||
assertTrue(a.moreThan(2).equals(new CharCollection("AAA")));
|
||||
assertEquals(a.moreThan(1), new CharCollection("AAANN"));
|
||||
assertEquals(a.moreThan(2), new CharCollection("AAA"));
|
||||
assertEquals("(A, A, A)",a.moreThan(2).toString());
|
||||
assertTrue(b.moreThan(1).equals(new CharCollection("CCHHH")));
|
||||
assertTrue(b.moreThan(3).equals(new CharCollection("")));
|
||||
assertEquals(b.moreThan(1), new CharCollection("CCHHH"));
|
||||
assertEquals(b.moreThan(3), new CharCollection(""));
|
||||
assertEquals("()",b.moreThan(3).toString());
|
||||
}
|
||||
|
||||
@Test
|
||||
public void Differenz(){
|
||||
assertTrue(a.except(new CharCollection("NASE")).equals(new CharCollection("AAN")));
|
||||
assertTrue(a.except(new CharCollection("KIWI")).equals(new CharCollection("ANANAS")));
|
||||
assertTrue(a.except(new CharCollection()).equals(new CharCollection("ANANAS")));
|
||||
assertTrue(a.except(new CharCollection("ANANAS")).equals(new CharCollection()));
|
||||
assertTrue(b.except(new CharCollection("CHHO")).equals(new CharCollection("SCHULE")));
|
||||
assertTrue(c.except(new CharCollection("HOSIANNA")).equals(new CharCollection('A')));
|
||||
assertTrue(d.except(new CharCollection("ABCD")).equals(new CharCollection()));
|
||||
assertEquals(a.except(new CharCollection("NASE")), new CharCollection("AAN"));
|
||||
assertEquals(a.except(new CharCollection("KIWI")), new CharCollection("ANANAS"));
|
||||
assertEquals(a.except(new CharCollection()), new CharCollection("ANANAS"));
|
||||
assertEquals(a.except(new CharCollection("ANANAS")), new CharCollection());
|
||||
assertEquals(b.except(new CharCollection("CHHO")), new CharCollection("SCHULE"));
|
||||
assertEquals(c.except(new CharCollection("HOSIANNA")), new CharCollection('A'));
|
||||
assertEquals(d.except(new CharCollection("ABCD")), new CharCollection());
|
||||
}
|
||||
|
||||
@Test
|
||||
|
Loading…
Reference in New Issue
Block a user