diff --git a/src/test/java/world/bentobox/bentobox/api/commands/admin/team/AdminTeamDisbandCommandTest.java b/src/test/java/world/bentobox/bentobox/api/commands/admin/team/AdminTeamDisbandCommandTest.java index 8efaa603a..10f784de3 100644 --- a/src/test/java/world/bentobox/bentobox/api/commands/admin/team/AdminTeamDisbandCommandTest.java +++ b/src/test/java/world/bentobox/bentobox/api/commands/admin/team/AdminTeamDisbandCommandTest.java @@ -235,7 +235,7 @@ public void testExecuteSuccess() { verify(user).sendMessage("commands.admin.team.disband.success", TextVariables.NAME, name[0]); verify(p).sendMessage("commands.admin.team.disband.disbanded"); verify(p2).sendMessage("commands.admin.team.disband.disbanded"); - // 2 * 2 + 1 - verify(pim, times(5)).callEvent(any()); + // 2 * 2 + verify(pim, times(4)).callEvent(any()); } } diff --git a/src/test/java/world/bentobox/bentobox/api/commands/admin/team/AdminTeamKickCommandTest.java b/src/test/java/world/bentobox/bentobox/api/commands/admin/team/AdminTeamKickCommandTest.java index aed70d1c0..9f8cacecc 100644 --- a/src/test/java/world/bentobox/bentobox/api/commands/admin/team/AdminTeamKickCommandTest.java +++ b/src/test/java/world/bentobox/bentobox/api/commands/admin/team/AdminTeamKickCommandTest.java @@ -217,8 +217,8 @@ public void testExecute() { verify(im).removePlayer(eq(world), eq(notUUID)); verify(pm).clearHomeLocations(eq(world), eq(notUUID)); verify(user).sendMessage(eq("commands.admin.team.kick.success"), eq(TextVariables.NAME), eq(name), eq("[owner]"), anyString()); - // Offline so event will be called six time - verify(pim, times(6)).callEvent(any()); + // Offline so event will be called 5 times + verify(pim, times(5)).callEvent(any()); } } diff --git a/src/test/java/world/bentobox/bentobox/api/commands/island/IslandResetCommandTest.java b/src/test/java/world/bentobox/bentobox/api/commands/island/IslandResetCommandTest.java index 5a7da91cc..507362541 100644 --- a/src/test/java/world/bentobox/bentobox/api/commands/island/IslandResetCommandTest.java +++ b/src/test/java/world/bentobox/bentobox/api/commands/island/IslandResetCommandTest.java @@ -257,8 +257,8 @@ public void testNoConfirmationRequired() throws Exception { assertTrue(irc.execute(user, irc.getLabel(), Collections.emptyList())); // TODO Verify that panel was shown // verify(bpm).showPanel(any(), eq(user), eq(irc.getLabel())); - // Verify event (13 * 2 + 1) - verify(pim, times(27)).callEvent(any(IslandBaseEvent.class)); + // Verify event (13 * 2) + verify(pim, times(26)).callEvent(any(IslandBaseEvent.class)); // Verify messaging verify(user).sendMessage("commands.island.create.creating-island"); verify(user, never()).sendMessage(eq("commands.island.reset.kicked-from-island"), eq(TextVariables.GAMEMODE), anyString()); @@ -446,8 +446,8 @@ public void testNoConfirmationRequiredCustomSchemHasPermission() throws Exceptio // Reset command, no confirmation required assertTrue(irc.execute(user, irc.getLabel(), Collections.singletonList("custom"))); verify(user).sendMessage("commands.island.create.creating-island"); - // Verify event (13 * 2 + 1) - verify(pim, times(27)).callEvent(any(IslandBaseEvent.class)); + // Verify event (13 * 2) + verify(pim, times(26)).callEvent(any(IslandBaseEvent.class)); } } diff --git a/src/test/java/world/bentobox/bentobox/api/events/island/IslandEventTest.java b/src/test/java/world/bentobox/bentobox/api/events/island/IslandEventTest.java index 13ae82e9c..d5add7b9e 100644 --- a/src/test/java/world/bentobox/bentobox/api/events/island/IslandEventTest.java +++ b/src/test/java/world/bentobox/bentobox/api/events/island/IslandEventTest.java @@ -168,7 +168,7 @@ public void testBuilder() { } } - verify(pim, Mockito.times(Reason.values().length * 3)).callEvent(any()); + verify(pim, Mockito.times(Reason.values().length * 2)).callEvent(any()); } }