Equals(maze.start(), FAIL); map = new char[][] { { '.', '.', '.', '.' }, { '.', '.', '.', '.' }, { 'S', '.', '.', 'P' }, { '.', '.', '.', '.' } }; maze = new Maze(-1, map); assertEquals(maze.start(), FAIL); } /** * testStart04 临界值 */ @Test public void testStart04() { map = new char[][] { { '*', '*', '*', '*' }, { '*', '*', '*', '*' }, { '*', '*', '*', '.' }, { 'S', '*', '*', 'P' } }; maze = new Maze(2, map); assertEquals(maze.start(), FAIL); map = new char[][] { { '.', '.', '.', '.' }, { '.', '.', '.', '.' }, { 'S', 'P', '.', '*' }, { '.', '.', '.', '.' } }; maze = new Maze(1, map); assertEquals(maze.start(), SUCCESS); } }
|