def test_part2(): solar_system = [ 'COM)B', 'B)C', 'C)D', 'D)E', 'E)F', 'B)G', 'G)H', 'D)I', 'E)J', 'J)K', 'K)L', 'K)YOU', 'I)SAN' ] answer = 4 assert day06.part2(solar_system) == answer
def test_day06_part2(): assert day06.part2('''COM)B B)C C)D D)E E)F B)G G)H D)I E)J J)K K)L K)YOU I)SAN'''.split()) == 4
def test_part2_example(self): input_list = [ "COM)B", "B)C", "C)D", "D)E", "E)F", "B)G", "G)H", "D)I", "E)J", "J)K", "K)L", "K)YOU", "I)SAN", ] result = day06.part2(input_list) self.assertEqual(4, result)
def test_part2_sample(sample_data): assert part2(sample_data) == 6
def test_part2(puzzle_input, answer): assert part2(puzzle_input) == answer
def test_part2(): assert day06.part2('input_day06.txt') == 418
def test_part2_input(self): result = day06.part2(aoc.read_input('day06.input')) self.assertEqual(460, result)
def test_day06_part2(): assert day06.part2(day06_example) == 6
def test_part2(self): input = read_inputfile("example06.txt") self.assertEqual(day06.part2(input), 6)
def test_6_2_examples(): examples = [] for (inp, out) in examples: assert out == day06.part2(inp)
def test_part2_example1(self): result = day06.part2(self.example, 32) self.assertEqual(result, 16)
def test_part2(): assert part2("day06/day06.dat") == 44868