Ledger Nano X - The secure hardware wallet
SHARE
TWEET

Untitled

akwatic97460 Mar 29th, 2020 79 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. @Test
  2.     public void testMove_nextOnStar() {
  3.         System.out.println("move, next on star and win");
  4.         board = new Board(new Square[][]{
  5.             {new Square(GRASS), new Square(GRASS), new Square(STAR), new Square(GRASS)},
  6.             {null, new Square(GRASS), new Square(GRASS), null},
  7.             {null, null, new Square(STAR), null}
  8.         });
  9.         animals = new Animal[] {
  10.             new Spider(new Position(0, 0)),
  11.             new Snail(new Position(0, 3))
  12.         };
  13.         Spider instance = (Spider) animals[0];
  14.         Position expResult = new Position(0, 2);
  15.         Position result = instance.move(board, Direction.EAST, animals);
  16.         assertEquals(expResult, result);
  17.         assertTrue(animals[0].isOnStar());
  18.         assertEquals(GRASS, board.getSquareType(result));
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
Top