mirror of
https://github.com/plexusorg/Plex-FAWE.git
synced 2024-12-23 09:47:38 +00:00
Move Bukkit to JUnit 5
This commit is contained in:
parent
429d022752
commit
3b157b67c3
@ -19,20 +19,20 @@
|
|||||||
|
|
||||||
package com.sk89q.wepif;
|
package com.sk89q.wepif;
|
||||||
|
|
||||||
import static org.junit.Assert.assertFalse;
|
|
||||||
import static org.junit.Assert.assertTrue;
|
|
||||||
import static org.mockito.Mockito.mock;
|
|
||||||
import static org.mockito.Mockito.when;
|
|
||||||
|
|
||||||
import org.bukkit.Server;
|
import org.bukkit.Server;
|
||||||
import org.bukkit.plugin.PluginManager;
|
import org.bukkit.plugin.PluginManager;
|
||||||
import org.junit.Before;
|
import org.junit.jupiter.api.BeforeEach;
|
||||||
import org.junit.Test;
|
import org.junit.jupiter.api.Test;
|
||||||
|
|
||||||
|
import static org.junit.jupiter.api.Assertions.assertFalse;
|
||||||
|
import static org.junit.jupiter.api.Assertions.assertTrue;
|
||||||
|
import static org.mockito.Mockito.mock;
|
||||||
|
import static org.mockito.Mockito.when;
|
||||||
|
|
||||||
public class DinnerPermsResolverTest {
|
public class DinnerPermsResolverTest {
|
||||||
private DinnerPermsResolver resolver;
|
private DinnerPermsResolver resolver;
|
||||||
|
|
||||||
@Before
|
@BeforeEach
|
||||||
public void setUp() {
|
public void setUp() {
|
||||||
Server server = mock(Server.class);
|
Server server = mock(Server.class);
|
||||||
when(server.getPluginManager()).thenReturn(mock(PluginManager.class));
|
when(server.getPluginManager()).thenReturn(mock(PluginManager.class));
|
||||||
|
@ -20,15 +20,16 @@
|
|||||||
package com.sk89q.worldedit.bukkit;
|
package com.sk89q.worldedit.bukkit;
|
||||||
|
|
||||||
import com.sk89q.worldedit.util.TreeGenerator;
|
import com.sk89q.worldedit.util.TreeGenerator;
|
||||||
import org.junit.Assert;
|
import org.junit.jupiter.api.Test;
|
||||||
import org.junit.Test;
|
|
||||||
|
import static org.junit.jupiter.api.Assertions.assertNotNull;
|
||||||
|
|
||||||
public class BukkitWorldTest {
|
public class BukkitWorldTest {
|
||||||
|
|
||||||
@Test
|
@Test
|
||||||
public void testTreeTypeMapping() {
|
public void testTreeTypeMapping() {
|
||||||
for (TreeGenerator.TreeType type : TreeGenerator.TreeType.values()) {
|
for (TreeGenerator.TreeType type : TreeGenerator.TreeType.values()) {
|
||||||
Assert.assertNotNull("No mapping for: " + type, BukkitWorld.toBukkitTreeType(type));
|
assertNotNull(BukkitWorld.toBukkitTreeType(type), "No mapping for: " + type);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user