mirror of
https://github.com/peterosterlund2/droidfish.git
synced 2025-12-12 00:52:40 +01:00
DroidFish: Use helper function MoveGen.legalMoves().
This commit is contained in:
@@ -72,8 +72,7 @@ public class BookTest extends TestCase {
|
||||
/** Check that move is a legal move in position pos. */
|
||||
private void checkValid(Position pos, Move move) {
|
||||
assertTrue(move != null);
|
||||
ArrayList<Move> moveList = new MoveGen().pseudoLegalMoves(pos);
|
||||
moveList = MoveGen.removeIllegal(pos, moveList);
|
||||
ArrayList<Move> moveList = new MoveGen().legalMoves(pos);
|
||||
assertTrue(moveList.contains(move));
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user