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

CyclopsMC / IntegratedDynamics / 22182377337

19 Feb 2026 12:46PM UTC coverage: 44.49% (-1.7%) from 46.183%
22182377337

push

github

rubensworks
Fix performance workflow failing

2663 of 8850 branches covered (30.09%)

Branch coverage included in aggregate %.

12028 of 24171 relevant lines covered (49.76%)

2.36 hits per line

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

73.08
/src/main/java/org/cyclops/integrateddynamics/capability/path/SidedPathElement.java
1
package org.cyclops.integrateddynamics.capability.path;
2

3
import net.minecraft.core.Direction;
4
import org.cyclops.integrateddynamics.api.path.IPathElement;
5
import org.cyclops.integrateddynamics.api.path.ISidedPathElement;
6

7
import javax.annotation.Nullable;
8

9
/**
10
 * @author rubensworks
11
 */
12
public class SidedPathElement implements ISidedPathElement {
13

14
    private final IPathElement pathElement;
15
    private final Direction side;
16

17
    public SidedPathElement(IPathElement pathElement, @Nullable Direction side) {
2✔
18
        this.pathElement = pathElement;
3✔
19
        this.side = side;
3✔
20
    }
1✔
21

22
    @Override
23
    public IPathElement getPathElement() {
24
        return pathElement;
3✔
25
    }
26

27
    @Override
28
    @Nullable
29
    public Direction getSide() {
30
        return side;
3✔
31
    }
32

33
    @Override
34
    public boolean equals(Object o) {
35
        return o instanceof ISidedPathElement && compareTo((ISidedPathElement)o) == 0;
×
36
    }
37

38
    @Override
39
    public int compareTo(ISidedPathElement o) {
40
        int pathElement = getPathElement().getPosition().compareTo(o.getPathElement().getPosition());
8✔
41
        if (pathElement == 0) {
2✔
42
            Direction thisSide = getSide();
3✔
43
            Direction thatSide = o.getSide();
3✔
44
            // If one of the sides is null, assume equality
45
            return thisSide != null && thatSide != null ? thisSide.compareTo(thatSide) : 0;
10!
46
        }
47
        return pathElement;
2✔
48
    }
49

50
    @Override
51
    public int hashCode() {
52
        return getPathElement().getPosition().hashCode();
5✔
53
    }
54

55
    @Override
56
    public String toString() {
57
        return "[Sided PE: " + getPathElement().getPosition() + " @ " + getSide() + "]";
×
58
    }
59

60
    public static SidedPathElement of(IPathElement pathElement, @Nullable Direction side) {
61
        return new SidedPathElement(pathElement, side);
6✔
62
    }
63
}
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