From 3dc836bbfefc2ec514e908e938ff90df66b90001 Mon Sep 17 00:00:00 2001 From: tastybento Date: Sun, 8 Dec 2019 11:58:34 -0800 Subject: [PATCH] Fixed IslandCache test class. Added mock to make island.isOwned() true. --- .../bentobox/bentobox/managers/island/IslandCacheTest.java | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/src/test/java/world/bentobox/bentobox/managers/island/IslandCacheTest.java b/src/test/java/world/bentobox/bentobox/managers/island/IslandCacheTest.java index ff9a65866..cea1f3251 100644 --- a/src/test/java/world/bentobox/bentobox/managers/island/IslandCacheTest.java +++ b/src/test/java/world/bentobox/bentobox/managers/island/IslandCacheTest.java @@ -18,7 +18,6 @@ import org.bukkit.Location; import org.bukkit.World; import org.junit.After; import org.junit.Before; -import org.junit.Ignore; import org.junit.Test; import org.junit.runner.RunWith; import org.mockito.Mock; @@ -41,7 +40,6 @@ import world.bentobox.bentobox.util.Util; @RunWith(PowerMockRunner.class) @PrepareForTest({BentoBox.class, Util.class}) -@Ignore("Illegal reflective access operations occurring") public class IslandCacheTest { @Mock @@ -90,6 +88,7 @@ public class IslandCacheTest { when(location.getBlockZ()).thenReturn(0); when(island.getCenter()).thenReturn(location); when(island.getOwner()).thenReturn(owner); + when(island.isOwned()).thenReturn(true); Builder members = new ImmutableSet.Builder<>(); members.add(UUID.randomUUID()); members.add(UUID.randomUUID());