mirror of
https://github.com/dmulloy2/ProtocolLib.git
synced 2024-11-28 05:35:28 +01:00
Update unit tests to CraftBukkit 1.6.2
This commit is contained in:
parent
6fe7fe46f3
commit
a4eb219a9a
@ -11,12 +11,12 @@
|
|||||||
</arguments>
|
</arguments>
|
||||||
</buildCommand>
|
</buildCommand>
|
||||||
<buildCommand>
|
<buildCommand>
|
||||||
<name>org.eclipse.m2e.core.maven2Builder</name>
|
<name>net.sourceforge.metrics.builder</name>
|
||||||
<arguments>
|
<arguments>
|
||||||
</arguments>
|
</arguments>
|
||||||
</buildCommand>
|
</buildCommand>
|
||||||
<buildCommand>
|
<buildCommand>
|
||||||
<name>net.sourceforge.metrics.builder</name>
|
<name>org.eclipse.m2e.core.maven2Builder</name>
|
||||||
<arguments>
|
<arguments>
|
||||||
</arguments>
|
</arguments>
|
||||||
</buildCommand>
|
</buildCommand>
|
||||||
|
@ -214,7 +214,7 @@
|
|||||||
<dependency>
|
<dependency>
|
||||||
<groupId>org.bukkit</groupId>
|
<groupId>org.bukkit</groupId>
|
||||||
<artifactId>craftbukkit</artifactId>
|
<artifactId>craftbukkit</artifactId>
|
||||||
<version>1.5.1-R0.2-SNAPSHOT</version>
|
<version>1.6.2-R0.1-SNAPSHOT</version>
|
||||||
<scope>provided</scope>
|
<scope>provided</scope>
|
||||||
</dependency>
|
</dependency>
|
||||||
<dependency>
|
<dependency>
|
||||||
|
@ -219,6 +219,11 @@ public class MinecraftReflection {
|
|||||||
MINECRAFT_FULL_PACKAGE = minecraftPackage;
|
MINECRAFT_FULL_PACKAGE = minecraftPackage;
|
||||||
CRAFTBUKKIT_PACKAGE = craftBukkitPackage;
|
CRAFTBUKKIT_PACKAGE = craftBukkitPackage;
|
||||||
|
|
||||||
|
// Make sure it exists
|
||||||
|
if (getMinecraftServerClass() == null) {
|
||||||
|
throw new IllegalArgumentException("Cannot find MinecraftServer for package " + minecraftPackage);
|
||||||
|
}
|
||||||
|
|
||||||
// Standard matcher
|
// Standard matcher
|
||||||
setDynamicPackageMatcher(MINECRAFT_OBJECT);
|
setDynamicPackageMatcher(MINECRAFT_OBJECT);
|
||||||
}
|
}
|
||||||
|
@ -4,10 +4,10 @@ import static org.mockito.Matchers.any;
|
|||||||
import static org.mockito.Mockito.mock;
|
import static org.mockito.Mockito.mock;
|
||||||
import static org.mockito.Mockito.when;
|
import static org.mockito.Mockito.when;
|
||||||
|
|
||||||
import net.minecraft.server.v1_5_R2.StatisticList;
|
import net.minecraft.server.v1_6_R2.StatisticList;
|
||||||
|
|
||||||
// Will have to be updated for every version though
|
// Will have to be updated for every version though
|
||||||
import org.bukkit.craftbukkit.v1_5_R2.inventory.CraftItemFactory;
|
import org.bukkit.craftbukkit.v1_6_R2.inventory.CraftItemFactory;
|
||||||
|
|
||||||
import org.bukkit.Bukkit;
|
import org.bukkit.Bukkit;
|
||||||
import org.bukkit.Material;
|
import org.bukkit.Material;
|
||||||
@ -63,6 +63,6 @@ public class BukkitInitialization {
|
|||||||
*/
|
*/
|
||||||
public static void initializePackage() {
|
public static void initializePackage() {
|
||||||
// Initialize reflection
|
// Initialize reflection
|
||||||
MinecraftReflection.setMinecraftPackage("net.minecraft.server.v1_5_R2", "org.bukkit.craftbukkit.v1_5_R2");
|
MinecraftReflection.setMinecraftPackage("net.minecraft.server.v1_6_R2", "org.bukkit.craftbukkit.v1_6_R2");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -22,7 +22,7 @@ import java.lang.reflect.Array;
|
|||||||
import java.util.List;
|
import java.util.List;
|
||||||
|
|
||||||
// Will have to be updated for every version though
|
// Will have to be updated for every version though
|
||||||
import org.bukkit.craftbukkit.v1_5_R2.inventory.CraftItemFactory;
|
import org.bukkit.craftbukkit.v1_6_R2.inventory.CraftItemFactory;
|
||||||
|
|
||||||
import org.bukkit.Material;
|
import org.bukkit.Material;
|
||||||
import org.bukkit.WorldType;
|
import org.bukkit.WorldType;
|
||||||
|
Loading…
Reference in New Issue
Block a user