use of com.builtbroken.mc.testing.junit.world.FakeWorld in project Engine by VoltzEngine-Project.
the class AbstractTileTest method testRandomDisplayTick.
@Test
public void testRandomDisplayTick() {
FakeWorld world = FakeWorld.newWorld("TestRandomDisplayTick");
world.setBlock(0, 0, 0, block);
Tile tile = ((Tile) world.getTileEntity(0, 0, 0));
tile.randomDisplayTick();
}
use of com.builtbroken.mc.testing.junit.world.FakeWorld in project Engine by VoltzEngine-Project.
the class AbstractTileTest method testGetplayersUsing.
@Test
public void testGetplayersUsing() {
FakeWorld world = FakeWorld.newWorld("TestGetplayersUsing");
world.setBlock(0, 0, 0, block);
Tile tile = ((Tile) world.getTileEntity(0, 0, 0));
tile.getPlayersUsing();
}
use of com.builtbroken.mc.testing.junit.world.FakeWorld in project Engine by VoltzEngine-Project.
the class AbstractTileTest method testGetSelectBounds.
@Test
public void testGetSelectBounds() {
FakeWorld world = FakeWorld.newWorld("TestGetSelectBounds");
world.setBlock(0, 0, 0, block);
Tile tile = ((Tile) world.getTileEntity(0, 0, 0));
Cube cube = tile.getSelectBounds();
assertTrue(cube != null);
//TODO add check to ensure cube size and values are good
}
use of com.builtbroken.mc.testing.junit.world.FakeWorld in project Engine by VoltzEngine-Project.
the class AbstractTileTest method testGetSideIcon.
@Test
public void testGetSideIcon() {
FakeWorld world = FakeWorld.newWorld("TestGetSideIcon");
world.setBlock(0, 0, 0, block);
Tile tile = ((Tile) world.getTileEntity(0, 0, 0));
tile.registerIcons(new SudoIconReg());
try {
Method method = Tile.class.getDeclaredMethod("getSideIcon", Integer.TYPE, Integer.TYPE);
method.setAccessible(true);
for (int i = 0; i < 6; i++) {
method.invoke(tile, 0, i);
}
} catch (NoSuchMethodException e) {
fail("Could not find method getTextureName");
} catch (InvocationTargetException e) {
e.printStackTrace();
fail("Failed to invoke method getTextureName");
} catch (IllegalAccessException e) {
fail("Couldn't access method getTextureName");
}
}
use of com.builtbroken.mc.testing.junit.world.FakeWorld in project Engine by VoltzEngine-Project.
the class AbstractTileTest method testOnFillRain.
@Test
public void testOnFillRain() {
FakeWorld world = FakeWorld.newWorld("TestOnFillRain");
world.setBlock(0, 0, 0, block);
Tile tile = ((Tile) world.getTileEntity(0, 0, 0));
tile.onFillRain();
}
Aggregations