Warning-Freies Projekt :-)

git-svn-id: svn://sunsvr01.isp.uni-luebeck.de/swproj13/trunk@218 72836036-5685-4462-b002-a69064685172
This commit is contained in:
Ida Massow 2011-05-10 04:13:58 +02:00
parent 5df9b9cc4b
commit 3940612608
2 changed files with 13 additions and 0 deletions

View file

@ -6,14 +6,24 @@ import java.util.Set;
import org.junit.*; import org.junit.*;
import static org.junit.Assert.*; import static org.junit.Assert.*;
/**
* test functions of Position-Class
*
*/
public class PositionTest { public class PositionTest {
/**
* String for debugging and testing
*/
@Test @Test
public void testToString() { public void testToString() {
Position pos = new Position(6, 2); Position pos = new Position(6, 2);
assertEquals("Position[x=6.0,y=2.0]", pos.toString()); assertEquals("Position[x=6.0,y=2.0]", pos.toString());
} }
/**
* tests hashing
*/
@Test @Test
public void testEqualsAndHashCode() { public void testEqualsAndHashCode() {
Position pos1 = new Position(0, 0); Position pos1 = new Position(0, 0);

View file

@ -175,6 +175,9 @@ public class StoneSetTest {
assertEquals(i, testSet.size()); assertEquals(i, testSet.size());
} }
/**
* String for Testing
*/
@Test @Test
public void testToString() { public void testToString() {
StoneSet testSet = new StoneSet(Arrays.asList(new Stone(2, BLUE), StoneSet testSet = new StoneSet(Arrays.asList(new Stone(2, BLUE),