mirror of
https://github.com/Noettore/AdventOfCode.git
synced 2025-10-15 11:46:39 +02:00
AoC 2020: day6, benchmark
Signed-off-by: Ettore Dreucci <ettore.dreucci@gmail.com>
This commit is contained in:
@@ -49,12 +49,16 @@ def part2(entries: list) -> int:
|
||||
count += 1
|
||||
return count
|
||||
|
||||
def test():
|
||||
def test_input():
|
||||
"""pytest testing function"""
|
||||
entries = extract(TEST_INPUT)
|
||||
assert part1(entries) == 11
|
||||
assert part2(entries) == 6
|
||||
|
||||
def test_bench(benchmark):
|
||||
"""pytest-benchmark function"""
|
||||
benchmark(main)
|
||||
|
||||
def main():
|
||||
"""main function"""
|
||||
input_path = str(pathlib.Path(__file__).resolve().parent.parent) + "/inputs/" + str(pathlib.Path(__file__).stem)
|
||||
|
Reference in New Issue
Block a user