Search in sources :

Example 1 with MinecraftDedicatedServer

use of net.minecraft.server.dedicated.MinecraftDedicatedServer in project Plan by plan-player-analytics.

the class FabricMockComponent method mockServer.

private MinecraftDedicatedServer mockServer() {
    MinecraftDedicatedServer serverMock = Mockito.mock(MinecraftDedicatedServer.class);
    doReturn("").when(serverMock).getServerIp();
    doReturn(25565).when(serverMock).getPort();
    doReturn("1.17.1").when(serverMock).getVersion();
    return serverMock;
}
Also used : MinecraftDedicatedServer(net.minecraft.server.dedicated.MinecraftDedicatedServer)

Aggregations

MinecraftDedicatedServer (net.minecraft.server.dedicated.MinecraftDedicatedServer)1