Skip to content

Commit

Permalink
fix(velocity): mock executor service maybe
Browse files Browse the repository at this point in the history
  • Loading branch information
bigspeedfpv committed Sep 24, 2024
1 parent fce5f50 commit f0f6c7f
Showing 1 changed file with 3 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,6 @@ class MockedVelocityServer {
}
Mockito.`when`(server.scheduler).thenReturn(scheduler)
Mockito.`when`(server.pluginManager).thenReturn(pluginManager)
Mockito.`when`(pluginManager.isLoaded(Mockito.anyString())).thenReturn(true)

val commandManager = VelocityCommandManager(eventManager, pluginManager)
Mockito.`when`(server.commandManager).thenReturn(commandManager)
Expand All @@ -79,6 +78,9 @@ class MockedVelocityServer {
val suspendingPluginContainer = SuspendingPluginContainer(plugin, server, logger)
suspendingPluginContainer.initialize(plugin.instance.get())

Mockito.`when`(pluginManager.isLoaded(Mockito.anyString())).thenReturn(true)
Mockito.`when`(pluginManager.ensurePluginContainer(Mockito.any())).thenReturn(plugin)

return plugin
}

Expand Down

0 comments on commit f0f6c7f

Please sign in to comment.