Examples of EightPuzzleBoard


Examples of aima.core.environment.eightpuzzle.EightPuzzleBoard

  @Test
  public void testPosition2MoveDown() {
    // { 5, 0, 4, 6, 1, 8, 7, 3, 2 }
    setGapToPosition2();
    board.moveGapDown();
    Assert.assertEquals(new EightPuzzleBoard(new int[] { 5, 1, 4, 6, 0, 8,
        7, 3, 2 }), board);
  }
View Full Code Here

Examples of aima.core.environment.eightpuzzle.EightPuzzleBoard

  @Test
  public void testPosition2MoveLeft() {
    // { 5, 0, 4, 6, 1, 8, 7, 3, 2 }
    setGapToPosition2();
    board.moveGapLeft();
    Assert.assertEquals(new EightPuzzleBoard(new int[] { 0, 5, 4, 6, 1, 8,
        7, 3, 2 }), board);
  }
View Full Code Here

Examples of aima.core.environment.eightpuzzle.EightPuzzleBoard

  @Test
  public void testPosition2MoveRight() {
    // { 5, 0, 4, 6, 1, 8, 7, 3, 2 }
    setGapToPosition2();
    board.moveGapRight();
    Assert.assertEquals(new EightPuzzleBoard(new int[] { 5, 4, 0, 6, 1, 8,
        7, 3, 2 }), board);
  }
View Full Code Here

Examples of aima.core.environment.eightpuzzle.EightPuzzleBoard

  @Test
  public void testPosition3MoveUp() {
    // { 5, 4, 0, 6, 1, 8, 7, 3, 2 }
    setGapToPosition3();
    board.moveGapUp();
    Assert.assertEquals(new EightPuzzleBoard(new int[] { 5, 4, 0, 6, 1, 8,
        7, 3, 2 }), board);
  }
View Full Code Here

Examples of aima.core.environment.eightpuzzle.EightPuzzleBoard

  @Test
  public void testPosition3MoveDown() {
    // { 5, 4, 0, 6, 1, 8, 7, 3, 2 }
    setGapToPosition3();
    board.moveGapDown();
    Assert.assertEquals(new EightPuzzleBoard(new int[] { 5, 4, 8, 6, 1, 0,
        7, 3, 2 }), board);
  }
View Full Code Here

Examples of aima.core.environment.eightpuzzle.EightPuzzleBoard

  @Test
  public void testPosition3MoveLeft() {
    // { 5, 4, 0, 6, 1, 8, 7, 3, 2 }
    setGapToPosition3();
    board.moveGapLeft();
    Assert.assertEquals(new EightPuzzleBoard(new int[] { 5, 0, 4, 6, 1, 8,
        7, 3, 2 }), board);
  }
View Full Code Here

Examples of aima.core.environment.eightpuzzle.EightPuzzleBoard

  @Test
  public void testPosition3MoveRight() {
    // { 5, 4, 0, 6, 1, 8, 7, 3, 2 }
    setGapToPosition3();
    board.moveGapRight();
    Assert.assertEquals(new EightPuzzleBoard(new int[] { 5, 4, 0, 6, 1, 8,
        7, 3, 2 }), board);
  }
View Full Code Here

Examples of aima.core.environment.eightpuzzle.EightPuzzleBoard

  @Test
  public void testPosition4MoveUp() {
    // { 6, 5, 4, 0, 1, 8, 7, 3, 2 }
    setGapToPosition4();
    board.moveGapUp();
    Assert.assertEquals(new EightPuzzleBoard(new int[] { 0, 5, 4, 6, 1, 8,
        7, 3, 2 }), board);
  }
View Full Code Here

Examples of aima.core.environment.eightpuzzle.EightPuzzleBoard

  @Test
  public void testPosition4MoveDown() {
    // { 6, 5, 4, 0, 1, 8, 7, 3, 2 }
    setGapToPosition4();
    board.moveGapDown();
    Assert.assertEquals(new EightPuzzleBoard(new int[] { 6, 5, 4, 7, 1, 8,
        0, 3, 2 }), board);
  }
View Full Code Here

Examples of aima.core.environment.eightpuzzle.EightPuzzleBoard

  @Test
  public void testPosition4MoveLeft() {
    // { 6, 5, 4, 0, 1, 8, 7, 3, 2 }
    setGapToPosition4();
    board.moveGapLeft();
    Assert.assertEquals(new EightPuzzleBoard(new int[] { 6, 5, 4, 0, 1, 8,
        7, 3, 2 }), board);
  }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.