Added test for isCheckForBlocks
This commit is contained in:
parent
bae0e6c36f
commit
a8473c27a9
|
@ -230,5 +230,16 @@ public class DefaultNewIslandLocationStrategyTest {
|
|||
when(adjBlock.isEmpty()).thenReturn(false);
|
||||
assertEquals(Result.BLOCKS_IN_AREA, dnils.isIsland(location));
|
||||
}
|
||||
|
||||
/**
|
||||
* Test method for {@link world.bentobox.bentobox.managers.island.DefaultNewIslandLocationStrategy#isIsland(org.bukkit.Location)}.
|
||||
*/
|
||||
@Test
|
||||
public void testIsIslandBlocksInAreaNoCheck() {
|
||||
when(iwm.isCheckForBlocks(any())).thenReturn(false);
|
||||
when(adjBlock.getType()).thenReturn(Material.STONE);
|
||||
when(adjBlock.isEmpty()).thenReturn(false);
|
||||
assertEquals(Result.FREE, dnils.isIsland(location));
|
||||
}
|
||||
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue