@Test public void testGetRightNode() { Node node = board.getNode(SUSPECTS[0], Direction.NORTH); assertEquals("Should be 8", 8, node.getPoint().x); assertEquals("Should be 24", 24, node.getPoint().y); assertTrue("Should be able to move back south", node.canMove(Direction.SOUTH)); }
@Test public void testFindPath() { Node node = board.getNode(SUSPECTS[0], Direction.NORTH); assertFalse("Should not be a path", node.isPath()); board.findPaths(SUSPECTS[0], 2); assertTrue("Should be a path", node.isPath()); board.clearPaths(); assertFalse("Should not be a path", node.isPath()); }