Added test for reversed range selecting

git-svn-id: svn://sunsvr01.isp.uni-luebeck.de/swproj13/trunk@190 72836036-5685-4462-b002-a69064685172
This commit is contained in:
Jannis Harder 2011-05-09 20:15:17 +02:00
parent 3f8853b3e6
commit daebef77d8

View file

@ -366,6 +366,26 @@ public class TurnControlTest {
assertCollection(Arrays.asList(stone1, stone2, stone3, stone4));
}
@Test
public void rangeSelectOnTableReverse() {
testControl.startTurn();
Stone stone1 = new Stone(1, StoneColor.RED);
Stone stone2 = new Stone(2, StoneColor.RED);
Stone stone3 = new Stone(3, StoneColor.RED);
Stone stone4 = new Stone(4, StoneColor.RED);
StoneSet set1 = new StoneSet(Arrays.asList(stone1, stone2, stone3, stone4));
mockTable.findStoneSet.put(stone1, set1);
mockTable.findStoneSet.put(stone3, set1);
mockView.tablePanel.stoneClickEvent.emit(stone3, false);
mockView.tablePanel.rangeClickEvent.emit(stone1, true);
assertCollection(Arrays.asList(stone1, stone2, stone3));
}
@Test
public void rangeSelectOnTable() {
testControl.startTurn();