diff --git a/src/test/java/world/bentobox/bentobox/listeners/DeathListenerTest.java b/src/test/java/world/bentobox/bentobox/listeners/DeathListenerTest.java index abc3081d5..0a846fad4 100644 --- a/src/test/java/world/bentobox/bentobox/listeners/DeathListenerTest.java +++ b/src/test/java/world/bentobox/bentobox/listeners/DeathListenerTest.java @@ -11,7 +11,6 @@ import org.bukkit.Bukkit; import org.bukkit.Location; import org.bukkit.World; import org.bukkit.damage.DamageSource; -import org.bukkit.damage.DamageType; import org.bukkit.entity.Player; import org.bukkit.event.entity.PlayerDeathEvent; import org.junit.After; @@ -41,7 +40,7 @@ public class DeathListenerTest { private World world; private UUID uuid; private IslandWorldManager iwm; - private DamageSource ds = DamageSource.builder(DamageType.ARROW).build(); + private DamageSource ds = null; @Before public void setUp() { diff --git a/src/test/java/world/bentobox/bentobox/listeners/flags/worldsettings/IslandRespawnListenerTest.java b/src/test/java/world/bentobox/bentobox/listeners/flags/worldsettings/IslandRespawnListenerTest.java index c5f51610c..8baa36cfc 100644 --- a/src/test/java/world/bentobox/bentobox/listeners/flags/worldsettings/IslandRespawnListenerTest.java +++ b/src/test/java/world/bentobox/bentobox/listeners/flags/worldsettings/IslandRespawnListenerTest.java @@ -22,7 +22,6 @@ import org.bukkit.Server; import org.bukkit.World; import org.bukkit.World.Environment; import org.bukkit.damage.DamageSource; -import org.bukkit.damage.DamageType; import org.bukkit.entity.Player; import org.bukkit.event.entity.PlayerDeathEvent; import org.bukkit.event.player.PlayerRespawnEvent; @@ -73,7 +72,7 @@ public class IslandRespawnListenerTest { @Mock private Island island; - private DamageSource ds = DamageSource.builder(DamageType.ARROW).build(); + private DamageSource ds = null; /** */ diff --git a/src/test/java/world/bentobox/bentobox/listeners/flags/worldsettings/VisitorKeepInventoryListenerTest.java b/src/test/java/world/bentobox/bentobox/listeners/flags/worldsettings/VisitorKeepInventoryListenerTest.java index 88348fe04..4fdfa8840 100644 --- a/src/test/java/world/bentobox/bentobox/listeners/flags/worldsettings/VisitorKeepInventoryListenerTest.java +++ b/src/test/java/world/bentobox/bentobox/listeners/flags/worldsettings/VisitorKeepInventoryListenerTest.java @@ -23,8 +23,6 @@ import java.util.UUID; import org.bukkit.Location; import org.bukkit.Material; import org.bukkit.World; -import org.bukkit.damage.DamageSource; -import org.bukkit.damage.DamageType; import org.bukkit.entity.Player; import org.bukkit.event.entity.PlayerDeathEvent; import org.bukkit.inventory.ItemStack; @@ -136,8 +134,7 @@ public class VisitorKeepInventoryListenerTest { // Default death event List drops = new ArrayList<>(); drops.add(new ItemStack(Material.ACACIA_BOAT)); - DamageSource ds = DamageSource.builder(DamageType.ARROW).build(); - e = new PlayerDeathEvent(player, ds, drops, 100, 0, 0, 0, "Death message"); + e = new PlayerDeathEvent(player, null, drops, 100, 0, 0, 0, "Death message"); // Make new l = new VisitorKeepInventoryListener(); }