summaryrefslogtreecommitdiffstats
path: root/test/jrummikub/model
diff options
context:
space:
mode:
authorJannis Harder <harder@informatik.uni-luebeck.de>2011-05-04 19:41:41 +0200
committerJannis Harder <harder@informatik.uni-luebeck.de>2011-05-04 19:41:41 +0200
commit7d7a5e1494efc574ce41558df789db261e086283 (patch)
treef973ddc77ac9525a94d2793d1148e98b359f2c03 /test/jrummikub/model
parentea37e2f0d26cdef4537d4792fadcab1dbc4ec337 (diff)
downloadJRummikub-7d7a5e1494efc574ce41558df789db261e086283.tar
JRummikub-7d7a5e1494efc574ce41558df789db261e086283.zip
Implemented finding of sets by stone
git-svn-id: svn://sunsvr01.isp.uni-luebeck.de/swproj13/trunk@119 72836036-5685-4462-b002-a69064685172
Diffstat (limited to 'test/jrummikub/model')
-rw-r--r--test/jrummikub/model/TableTest.java11
1 files changed, 11 insertions, 0 deletions
diff --git a/test/jrummikub/model/TableTest.java b/test/jrummikub/model/TableTest.java
index 17ed8c8..25cc3c3 100644
--- a/test/jrummikub/model/TableTest.java
+++ b/test/jrummikub/model/TableTest.java
@@ -69,4 +69,15 @@ public class TableTest {
}
assertEquals(2, counter);
}
+
+ @Test
+ public void testFindSet() {
+ Stone targetStone = new Stone(BLACK);
+ StoneSet testSet = new StoneSet(Arrays.asList(new Stone(1, RED), targetStone,
+ new Stone(3, RED)));
+ testTable.drop(testSet, new Position(0,0));
+
+ StoneSet foundSet = testTable.findStoneSet(targetStone);
+ assertSame(testSet, foundSet);
+ }
}