@Test public void testUseWithoutCleanup() { final Inventory inventory = mock(Inventory.class); final Character character = mock(Character.class); when(character.getInventory()).thenReturn(inventory); potion1.use(character); verify(character).setPoisoned(false); }
@Override public void use(Character character) { super.use(character); character.setPoisoned(false); }
PoisonPotion extends ConsumableItem { @Override public void use(Character character) { super.use(character); character.setPoisoned(false); } }
PoisonPotion extends ConsumableItem { @Override public void use(Character character) { super.use(character); character.setPoisoned(false); } PoisonPotion(ItemProperties properties, int amount); }
PoisonPotion extends ConsumableItem { @Override public void use(Character character) { super.use(character); character.setPoisoned(false); } PoisonPotion(ItemProperties properties, int amount); @Override Item clone(); @Override void use(Character character); }
PoisonPotion extends ConsumableItem { @Override public void use(Character character) { super.use(character); character.setPoisoned(false); } PoisonPotion(ItemProperties properties, int amount); @Override Item clone(); @Override void use(Character character);  }