### Question:
HumanPlayer implements Player { @Override public void chooseWeapon() { try { chosenWeapon = (Weapon) inputPromptFunction.call(); } catch (Exception ex) { throw new RuntimeException("Fatal error.", ex); } } HumanPlayer(String name);  HumanPlayer(String name, Callable<Weapon> inputPromptFunction); @Override String getName(); @Override void chooseWeapon(); @Override Weapon getChosenWeapon();  }### Answer:
@Test public void shouldThrowExceptionWhenCallbackHasException() { Player player = new HumanPlayer("Alex", () -> { throw new RuntimeException("Some exception"); }); thrown.expect(RuntimeException.class); thrown.expectMessage("Fatal error."); player.chooseWeapon(); }