• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

CyclopsMC / IntegratedDynamics / 20210191346

14 Dec 2025 03:32PM UTC coverage: 19.514% (-33.5%) from 53.061%
20210191346

push

github

rubensworks
Remove deprecations

663 of 8728 branches covered (7.6%)

Branch coverage included in aggregate %.

6786 of 29445 relevant lines covered (23.05%)

1.09 hits per line

Source File
Press 'n' to go to next uncovered line, 'b' for previous

0.0
/src/main/java/org/cyclops/integrateddynamics/gametest/GameTestsAspectsReadBlock.java
1
package org.cyclops.integrateddynamics.gametest;
2

3
import net.minecraft.core.BlockPos;
4
import net.minecraft.gametest.framework.GameTestHelper;
5
import net.minecraft.nbt.CompoundTag;
6
import net.minecraft.world.level.block.Blocks;
7
import net.minecraft.world.level.block.entity.BlockEntity;
8
import org.cyclops.cyclopscore.gametest.GameTest;
9
import org.cyclops.integrateddynamics.core.evaluate.variable.*;
10
import org.cyclops.integrateddynamics.core.part.PartTypes;
11
import org.cyclops.integrateddynamics.part.aspect.Aspects;
12

13
import static org.cyclops.integrateddynamics.gametest.GameTestHelpersIntegratedDynamics.testReadAspect;
14

15
public class GameTestsAspectsReadBlock {
×
16

17
    public static final String TEMPLATE_EMPTY = "integrateddynamics:empty10";
18
    public static final BlockPos POS = BlockPos.ZERO.offset(2, 0, 2);
×
19

20
    @GameTest(template = TEMPLATE_EMPTY)
21
    public void testAspectsReadBlockBooleanBlockTrue(GameTestHelper helper) {
22
        helper.setBlock(POS.west(), Blocks.STONE);
×
23
        testReadAspect(POS, helper, PartTypes.BLOCK_READER, Aspects.Read.Block.BOOLEAN_BLOCK, ValueTypeBoolean.ValueBoolean.of(true));
×
24
    }
×
25

26
    @GameTest(template = TEMPLATE_EMPTY)
27
    public void testAspectsReadBlockBooleanBlockFalse(GameTestHelper helper) {
28
        testReadAspect(POS, helper, PartTypes.BLOCK_READER, Aspects.Read.Block.BOOLEAN_BLOCK, ValueTypeBoolean.ValueBoolean.of(false));
×
29
    }
×
30

31
    @GameTest(template = TEMPLATE_EMPTY)
32
    public void testAspectsReadBlockDimension(GameTestHelper helper) {
33
        testReadAspect(POS, helper, PartTypes.BLOCK_READER, Aspects.Read.Block.STRING_DIMENSION, ValueTypeString.ValueString.of(helper.getLevel().dimension().location().toString()));
×
34
    }
×
35

36
    @GameTest(template = TEMPLATE_EMPTY)
37
    public void testAspectsReadBlockPosX(GameTestHelper helper) {
38
        testReadAspect(POS, helper, PartTypes.BLOCK_READER, Aspects.Read.Block.INTEGER_POSX, ValueTypeInteger.ValueInteger.of(helper.absolutePos(POS.west()).getX()));
×
39
    }
×
40
    @GameTest(template = TEMPLATE_EMPTY)
41
    public void testAspectsReadBlockPosY(GameTestHelper helper) {
42
        testReadAspect(POS, helper, PartTypes.BLOCK_READER, Aspects.Read.Block.INTEGER_POSY, ValueTypeInteger.ValueInteger.of(helper.absolutePos(POS.west()).getY()));
×
43
    }
×
44
    @GameTest(template = TEMPLATE_EMPTY)
45
    public void testAspectsReadBlockPosZ(GameTestHelper helper) {
46
        testReadAspect(POS, helper, PartTypes.BLOCK_READER, Aspects.Read.Block.INTEGER_POSZ, ValueTypeInteger.ValueInteger.of(helper.absolutePos(POS.west()).getZ()));
×
47
    }
×
48

49
    @GameTest(template = TEMPLATE_EMPTY)
50
    public void testAspectsReadBlockBlock(GameTestHelper helper) {
51
        helper.setBlock(POS.west(), Blocks.STONE);
×
52
        testReadAspect(POS, helper, PartTypes.BLOCK_READER, Aspects.Read.Block.BLOCK, ValueObjectTypeBlock.ValueBlock.of(Blocks.STONE.defaultBlockState()));
×
53
    }
×
54

55
    @GameTest(template = TEMPLATE_EMPTY)
56
    public void testAspectsReadBlockNbt(GameTestHelper helper) {
57
        helper.setBlock(POS.west(), Blocks.FURNACE);
×
58
        CompoundTag tag = helper.getBlockEntity(POS.west(), BlockEntity.class)
×
59
                .saveWithFullMetadata(helper.getLevel().registryAccess());
×
60
        testReadAspect(POS, helper, PartTypes.BLOCK_READER, Aspects.Read.Block.NBT, ValueTypeNbt.ValueNbt.of(tag));
×
61
    }
×
62

63
    @GameTest(template = TEMPLATE_EMPTY)
64
    public void testAspectsReadBlockBiome(GameTestHelper helper) {
65
        testReadAspect(POS, helper, PartTypes.BLOCK_READER, Aspects.Read.Block.STRING_DIMENSION, ValueTypeString.ValueString.of("minecraft:overworld"));
×
66
    }
×
67

68
    @GameTest(template = TEMPLATE_EMPTY)
69
    public void testAspectsReadBlockLight(GameTestHelper helper) {
70
        testReadAspect(POS, helper, PartTypes.BLOCK_READER, Aspects.Read.Block.INTEGER_LIGHT, ValueTypeInteger.ValueInteger.of(helper.getLevel().getMaxLocalRawBrightness(helper.absolutePos(POS.west()))));
×
71
    }
×
72

73
}
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc