MCPcopy Index your code
hub / github.com/coding-parrot/chess-engine / countMovesAfterMove

Method countMovesAfterMove

src/test/java/EngineTest.java:42–53  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

40 }
41
42 @Test
43 public void countMovesAfterMove() {
44 Board board = Board.getStartBoard();
45 Piece piece = board.getPiece(1, 1);
46 board.makeMove(Move.get(piece, Cell.get(2, 1), false));
47 piece = board.getPiece(6, 1);
48 board.makeMove(Move.get(piece, Cell.get(5, 0), false));
49 Engine engine = new Engine();
50 System.out.println(board);
51 Assert.assertEquals("rnbqkbnr/p1pppppp/p7/8/8/1P6/P1PPPPPP/RNBQKBNR w KQkq -", board.fenRepresentation());
52 Assert.assertEquals(21, engine.countAllMoves(board, 1));
53 }
54
55 @Test
56 public void countMovesAtPosition31() {

Callers

nothing calls this directly

Calls 7

getStartBoardMethod · 0.95
getPieceMethod · 0.95
makeMoveMethod · 0.95
getMethod · 0.95
getMethod · 0.95
fenRepresentationMethod · 0.95
countAllMovesMethod · 0.95

Tested by

no test coverage detected