# -*- coding: utf-8 -*- from day12 import Map class TestMap: def test_neighbours(self): map_input = ["".join([str(i) for i in range(8)]) for _ in range(5)] map = Map(map=map_input) assert set(map.neighbours(0, 0)) == { (0, 1), (1, 0), } assert set(map.neighbours(0, 4)) == { (0, 3), (1, 4), } assert set(map.neighbours(1, 1)) == { (0, 1), (1, 0), (1, 2), (2, 1), }