use of com.builtbroken.mc.testing.junit.world.FakeWorld in project Engine by VoltzEngine-Project.
the class AbstractTileTest method testY.
@Test
public void testY() {
FakeWorld world = FakeWorld.newWorld("TestY");
world.setBlock(0, 0, 0, block);
TileEntity tile = world.getTileEntity(0, 0, 0);
assertTrue(tile.getClass() == tileClazz);
assertTrue(tile.yCoord == (int) ((T) tile).y());
}
use of com.builtbroken.mc.testing.junit.world.FakeWorld in project Engine by VoltzEngine-Project.
the class AbstractTileTest method testSetMeta.
@Test
public void testSetMeta() {
FakeWorld world = FakeWorld.newWorld("TestSetMeta");
world.setBlock(0, 0, 0, block);
Tile tile = ((Tile) world.getTileEntity(0, 0, 0));
tile.setMeta(10);
}
use of com.builtbroken.mc.testing.junit.world.FakeWorld in project Engine by VoltzEngine-Project.
the class AbstractTileTest method testMarkRender.
@Test
public void testMarkRender() {
FakeWorld world = FakeWorld.newWorld("TestMarkRender");
world.setBlock(0, 0, 0, block);
Tile tile = ((Tile) world.getTileEntity(0, 0, 0));
try {
Method method = Tile.class.getDeclaredMethod("markRender");
method.setAccessible(true);
method.invoke(tile);
} catch (NoSuchMethodException e) {
fail("Could not find method markRender");
} catch (InvocationTargetException e) {
e.printStackTrace();
fail("Failed to invoke method markRender");
} catch (IllegalAccessException e) {
fail("Couldn't access method markRender");
}
}
use of com.builtbroken.mc.testing.junit.world.FakeWorld in project Engine by VoltzEngine-Project.
the class AbstractTileTest method testRegisterSideTextureSet.
@Test
public void testRegisterSideTextureSet() {
FakeWorld world = FakeWorld.newWorld("TestRegisterSideTextureSet");
world.setBlock(0, 0, 0, block);
Tile tile = ((Tile) world.getTileEntity(0, 0, 0));
SudoIconReg reg = new SudoIconReg();
//TODO check to see if the texture exists
tile.registerSideTextureSet(reg);
}
use of com.builtbroken.mc.testing.junit.world.FakeWorld in project Engine by VoltzEngine-Project.
the class AbstractTileTest method testYi.
@Test
public void testYi() {
FakeWorld world = FakeWorld.newWorld("TestYi");
world.setBlock(0, 0, 0, block);
TileEntity tile = world.getTileEntity(0, 0, 0);
assertTrue(tile.getClass() == tileClazz);
assertTrue(tile.yCoord == ((T) tile).yi());
}
Aggregations