@Test public void testCanRollNumber() { game.setPhase(TurnTracker.Phase.ROLLING); final int turn = game.getCurrentTurn(); assertTrue(game.canRollNumber(turn)); try { game.getTurnTracker().nextPhase(); } catch (Exception e) { e.printStackTrace(); } assertFalse(game.canRollNumber(turn)); }
@Test public void testRollNumber() throws InvalidDiceRollException { final int turn = game.getCurrentTurn(); try { game.getTurnTracker().nextPhase(); game.getTurnTracker().nextPhase(); } catch (Exception e) { e.printStackTrace(); } final int roll = game.rollDice(turn); assertTrue(roll > 1); assertTrue(roll <= 12); }