def test_duplicated_links_remove_first_input():
    """
    # test changes introduced for #508
    """

    d1 = Data(x=[1, 2, 3])
    d2 = Data(y=[2, 4, 6])

    x = d1.id['x']
    y = d2.id['y']

    dc = DataCollection([d1, d2])

    dc.add_link(LinkSame(x, y))
    assert y not in d2.components
    assert y not in d1.components
    assert x in d2.components
    assert d2.components in x
dataset/ETHPy150Open glue-viz/glue/glue/core/tests/test_component_link.py/test_duplicated_links_remove_first_input/swapped operands of `in`