@Test
    public void testFindReachableMassesAndInputsOnConnectingToInputs() {
        Range range = new Range(0, 10);
        mass1 = new Mass(0, 0, INPUT);
        mass2 = new Mass(0, 10, INPUT);
        mass3 = new Mass(5, 5);

        graph.addMasses(mass1, mass2, mass3);

        List<Mass> reachableMasses = graph.findReachableMassesAndInputs(mass3, range, excludeCrossings);
        assertEquals(2, reachableMasses.size());
        assertSame(mass1, reachableMasses.get(0));
        assertSame(mass2, reachableMasses.get(1));
    }