mirror of
https://github.com/Anuken/Mindustry.git
synced 2025-01-05 13:08:20 +07:00
Testing tests
This commit is contained in:
parent
8b8d990852
commit
7b1c60c24f
@ -34,7 +34,7 @@ public class ItemLiquidGeneratorTests extends PowerTestFixture{
|
||||
public void createGenerator(InputType inputType){
|
||||
Vars.state = new GameState();
|
||||
Vars.state.rules = new Rules();
|
||||
generator = new ItemLiquidGenerator(inputType != InputType.liquids, inputType != InputType.items, "fakegen"){
|
||||
generator = new ItemLiquidGenerator(inputType != InputType.liquids, inputType != InputType.items, "fakegen" + System.nanoTime()){
|
||||
{
|
||||
powerProduction = 0.1f;
|
||||
itemDuration = fakeItemDuration;
|
||||
|
@ -50,21 +50,21 @@ public class PowerTestFixture{
|
||||
}
|
||||
|
||||
protected static PowerGenerator createFakeProducerBlock(float producedPower){
|
||||
return new PowerGenerator("fakegen"){{
|
||||
return new PowerGenerator("fakegen" + System.nanoTime()){{
|
||||
buildType = () -> new GeneratorBuild();
|
||||
powerProduction = producedPower;
|
||||
}};
|
||||
}
|
||||
|
||||
protected static Battery createFakeBattery(float capacity){
|
||||
return new Battery("fakebattery"){{
|
||||
return new Battery("fakebattery" + System.nanoTime()){{
|
||||
buildType = () -> new BatteryBuild();
|
||||
consumes.powerBuffered(capacity);
|
||||
}};
|
||||
}
|
||||
|
||||
protected static Block createFakeDirectConsumer(float powerPerTick){
|
||||
return new PowerBlock("fakedirectconsumer"){{
|
||||
return new PowerBlock("fakedirectconsumer" + System.nanoTime()){{
|
||||
buildType = Building::create;
|
||||
consumes.power(powerPerTick);
|
||||
}};
|
||||
|
Loading…
Reference in New Issue
Block a user