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

Method surroundedByPieces

src/test/java/RookTest.java:46–57  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

44 }
45
46 @Test
47 public void surroundedByPieces() {
48 Board board = new Board();
49 board.placeRook(3, 3, Color.BLACK);
50 board.placePawn(4, 3, Color.BLACK);
51 board.placePawn(3, 4, Color.BLACK);
52 board.placeRook(2, 3, Color.BLACK);
53 board.placeRook(3, 2, Color.BLACK);
54 System.out.println(board);
55 System.out.println(board.getPiece(3, 3).getMoveList(board));
56 Assert.assertTrue(board.getPiece(3, 3).getMoveList(board).isEmpty());
57 }
58
59 @Test
60 public void surroundedByEnemy() {

Callers

nothing calls this directly

Calls 5

placeRookMethod · 0.95
placePawnMethod · 0.95
getPieceMethod · 0.95
isEmptyMethod · 0.80
getMoveListMethod · 0.45

Tested by

no test coverage detected