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

Method fenRepresentation

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

Source from the content-addressed store, hash-verified

8
9public class EngineTest {
10 @Test
11 public void fenRepresentation() {
12 Board board = Board.getStartBoard();
13 Assert.assertEquals("rnbqkbnr/pppppppp/8/8/8/8/PPPPPPPP/RNBQKBNR w KQkq -", board.fenRepresentation());
14 board.makeMove(Move.get(board.getPiece(1, 4), Cell.get(3, 4), false));
15 Assert.assertEquals("rnbqkbnr/pppppppp/8/8/4P3/8/PPPP1PPP/RNBQKBNR b KQkq e3", board.fenRepresentation());
16 board.makeMove(Move.get(board.getPiece(6, 2), Cell.get(4, 2), false));
17 Assert.assertEquals("rnbqkbnr/pp1ppppp/8/2p5/4P3/8/PPPP1PPP/RNBQKBNR w KQkq c6", board.fenRepresentation());
18 board.makeMove(Move.get(board.getPiece(0, 6), Cell.get(2, 5), false));
19 Assert.assertEquals("rnbqkbnr/pp1ppppp/8/2p5/4P3/5N2/PPPP1PPP/RNBQKB1R b KQkq -", board.fenRepresentation());
20 }
21
22 @Test
23 public void otherBoard() {

Callers

nothing calls this directly

Calls 6

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

Tested by

no test coverage detected