def test_get_visible_seats_multiple_diagonal(self): seats = ['...', 'A.B', '.X.', 'C.D'] self.assertCountEqual( part2.get_visible_seats((2, 1), seats), ['A', 'B', 'C', 'D'] )
def test_get_visible_seats_multiple(self): seats = ['.A.B', 'C...', 'DXE.', '.F.G'] self.assertCountEqual( part2.get_visible_seats((2, 1), seats), ['A', 'B', 'C', 'D', 'E', 'F'] )
def test_get_visible_seats_multiple_vertical(self): seats = ['.AB.', '.C..', '.X..', '.D.E'] self.assertCountEqual( part2.get_visible_seats((2, 1), seats), ['C', 'D'] )
def test_get_visible_seats_on_left(self): seats = ['A.B.X.'] self.assertEqual(part2.get_visible_seats((0, 4), seats), ['B'])
def test_get_visible_seats_diagonally_left_corner(self): seats = ['A.B..', 'X...C', 'D...E', '..F..'] self.assertCountEqual( part2.get_visible_seats((1, 0), seats), ['A', 'C', 'D', 'F'] )
def test_get_visible_seats_multiple_horizontal(self): seats = ['..A.', '....', 'BX.C', '...D'] self.assertCountEqual( part2.get_visible_seats((2, 1), seats), ['B', 'C'] )
def test_get_visible_seats_diagonally_right_corner(self): seats = ['..A..', '..B.C', '..D.X', '....E'] self.assertCountEqual( part2.get_visible_seats((2, 4), seats), ['A', 'C', 'D', 'E'] )
def test_get_visible_seats_diagonally_back_right(self): seats = ['...', '...', '.X.', '..A'] self.assertEqual(part2.get_visible_seats((2, 1), seats), ['A'])
def test_get_visible_seats_diagonally_front_right(self): seats = ['A.B', '..C', '.X.', '...'] self.assertEqual(part2.get_visible_seats((2, 1), seats), ['C'])
def test_get_visible_seats_at_back(self): seats = ['...', '...', '.X.', '.A.'] self.assertEqual(part2.get_visible_seats((2, 1), seats), ['A'])
def test_get_visible_seats_on_right(self): seats = ['...X.A'] self.assertEqual(part2.get_visible_seats((0, 3), seats), ['A'])