def test_get_links_contains_cell_when_linked(): cell_A = Cell(0, 0) cell_B = Cell(1, 1) cell_A.link(cell_B) links = cell_A.links assert cell_B in links
def test_link_cell_links_cell(): cell_A = Cell(0, 0) cell_B = Cell(1, 1) cell_A.link(cell_B) assert cell_A.is_linked(cell_B) assert not cell_B.is_linked(cell_A)