@Test
    public void testRemoveMassSpringNetworkOnSourceAndDestinationMass() {
        mass1 = new Mass(1, 2, INPUT);
        mass2 = new Mass(1, 2, INPUT);
        mass3 = new Mass(3, 4);
        mass4 = new Mass(5, 6);

        graph.addMasses(mass1, mass2, mass3, mass4);

        // not removable
        graph.addSpring(mass1, mass2);
        graph.addSpring(mass2, mass1);

        // removable 
        graph.addSpring(mass1, mass3);
        graph.addSpring(mass4, mass2);
        graph.addSpring(mass2, mass3);
        graph.addSpring(mass3, mass2);

        Spring spring1 = graph.getSprings().get(0);
        Spring spring2 = graph.getSprings().get(1);
        graph.getSprings().get(2);
        graph.getSprings().get(3);
        graph.getSprings().get(4);
        graph.getSprings().get(5);

        graph.removeMassSpringNetwork();
        assertEquals(2, graph.getMasses().size());
        assertSame(mass1, graph.getMasses().get(0));
        assertSame(mass2, graph.getMasses().get(1));

        assertEquals(2, graph.getSprings().size());
        assertSame(spring1, graph.getSprings().get(0));
        assertSame(spring2, graph.getSprings().get(1));
    }