add test script and data

This commit is contained in:
Xiretza 2020-12-06 16:34:20 +01:00
parent 0c3c153004
commit 7981c50a4e
Signed by: xiretza
GPG key ID: 17B78226F7139993
13 changed files with 5794 additions and 0 deletions

2
data/day1.expected Normal file
View file

@ -0,0 +1,2 @@
1018336
288756720

200
data/day1.input Normal file
View file

@ -0,0 +1,200 @@
1028
1987
1938
1136
1503
1456
1107
1535
1946
1986
855
1587
1632
1548
1384
1894
1092
1876
1914
1974
1662
1608
2004
1464
1557
1485
1267
1582
1307
1903
1102
1578
1421
1184
1290
1786
1295
1930
1131
1802
1685
1735
1498
1052
1688
990
1805
1768
1922
1781
1897
1545
1591
1393
1186
149
1619
1813
1708
1119
1214
1705
1942
1684
1460
1123
1439
1672
1980
1337
1731
1203
1481
2009
1110
1116
1443
1957
1891
1595
1951
1883
1733
1697
1321
1689
1103
1300
1262
1190
1667
1843
1544
1877
1718
1866
1929
1169
1693
1518
1375
1477
1222
1791
1612
1373
1253
1087
1959
1970
1112
1778
1412
1127
1767
1091
1653
1609
1810
1912
1917
935
1499
1878
1452
1935
1937
968
1905
1077
1701
1789
1506
1451
1125
1686
1117
1991
1215
1776
1976
846
1923
1945
1888
1193
1146
1583
1315
1372
1963
1491
1777
1799
1363
1579
1367
1863
1983
1679
1944
1654
1953
1297
530
1502
1738
1934
1185
1998
1764
1856
1207
1181
1494
1676
1900
1057
339
1994
2006
1536
2007
644
1173
1692
1493
1756
1916
1890
1908
1887
1241
1447
1997
1967
1098
1287
1392
1932

2
data/day2.expected Normal file
View file

@ -0,0 +1,2 @@
603
404

1000
data/day2.input Normal file

File diff suppressed because it is too large Load diff

2
data/day3.expected Normal file
View file

@ -0,0 +1,2 @@
205
3952146825

323
data/day3.input Normal file
View file

@ -0,0 +1,323 @@
..#...##...###.........#..#..#.
#.###........#..##.#......#...#
#.#.###..#.#..#.#............#.
.##............#......#...#.#..
..#..#.....##..##..##..........
...#...........###.#.##........
....#.#...#..#..##............#
....#....##...##..##........#..
.#..#..#....#...#..##.....##...
.#.###..#......####........##..
..#...###....#......#.....##.##
..#...#.......#......#..##....#
#...##....#.#..#.......#....#..
.#......#..#...........#....##.
.##.#......#.#.#.....##........
.....#.................#.#..#.#
....#..#........##......#..#.#.
..#...#..##.......#..##...#..#.
..#.......#.............#.#....
.#.................#.........#.
..#..#.#.#.#............##.#..#
.#.#.##.#.....#.....#..#......#
..#.#..#.#..........##........#
.........#...#.....#.#...#####.
##..#.....##.##........#...##..
.#.....#....##.#..#....##...##.
.##.....#.#....#.#.....#......#
.....#..#.##.....#.#....#.#..##
#......##..##....##...###..#...
.......#..#...........#......#.
#...#......#........#..#.......
##..#.....##.....#...#...#....#
.###..##..#.#........#..#.#....
#.#...#...#......##........#.#.
......#....#.#........##...#..#
.#.....#..#.#.....#......##....
.....#.....#.#.#....###.....#..
#.......##.#......#.#.#....###.
.......#..#..#...#.#.##........
.#......##..#.........###..#...
....#..##.......##.###...###...
.##............#..#.##.....#.##
..##.#.......##....#.......##.#
#..###............#.#...#...#.#
...##.#.#.#..#.##........#.#...
.#.....#...##.#..###..##.##...#
..............#.#.#.........#..
.....#...........#.#...#....#..
.....#...##.##.#....#.###..#...
#..###.........#......#.#.#....
.....#..#...##...###.#....#....
#..........#.#.#....#..#......#
###...................#......#.
........####......#.#..........
.......#.....#...#.......#...#.
.....#.....................#...
...#.#...#...#...........#.....
..#.........#...#....###..#....
.....#.#..##......##........##.
..#.............#............#.
.#....##.......#..#............
.#............#.#..#.##....#...
.####...##.#....#.....#...#....
##..#....#.#.#...........#..#.#
...#..#...........#...#..#....#
.....##.....#..#...#.........#.
...##........#....##........#..
.##.#...#...#..#.....#....##.#.
#.#...#.#.#.#.#..#....#....#...
#..#.#...#..#........#....#.#..
....#.#.....#......##...#....#.
.###.##...#....##.#...###..#..#
###..#...##..#......#.........#
..#.#......##.......#.....#...#
..#...#........#.........#.#...
#....#..#.........###.#......##
...#..#....#...#.......##.#.#..
....#.......#....###...##.#....
..#.....#.#.....###..#####....#
##......#....#.....##..#..#...#
#...........#..#..#....#....#..
.#...#.##.#.#.#....#......#..#.
.......#.#....#....#...#.#..#..
..#.#..#.##..##...##..#..#.....
...##.##.................#.#...
.....#...#......##.#....#.....#
......#..##.#..#.#.........#...
.............##.#......#.......
..#.#.....#...#.#.....#..#.....
.........#..#.#......#..#......
#..#.#.##..........#.##......##
......#.......#.....#..#.#...#.
.#....#....#.#.....#.......#...
#..#..##..................#....
............#...........##.#...
####...#..##.#....#.##..#......
#...#...#.....#.#...#.#........
.......##.........#.....#.....#
.....#...........##......#.####
.##....#.#.##......###.#.##....
........#.####.......#.#...#...
.#.#...##.#.#.#.........##.....
....#............###.##....#...
...##........##.#...#....#..###
..#.#.........#....##.#........
..#..##..#...##..#.##...#.....#
.#......#..#..#.........#......
..#........##.#......#.....#...
.##.......#....#.#......#......
#........#....#.####...#.#.....
##......#.............#....###.
..#....####.#.#.#.#...##......#
#.#.#.....#...#.......#...##...
........#...#....#..#......#.#.
#..#...#.#.##.....#.#....#....#
#...#....#......#.........##.##
..##.#..##............#........
#.........####.........#.......
#.##.........#..##....#.#.#.#..
.###......##..#.#.....#.#...##.
...#.........#.#...##.##....#..
#..#......#....##..#.#...#...##
...#.......#.#.#.....#..##...#.
....................###........
#...........###......#.#...##.#
.................#.#...###....#
...#..###..#.##...#..#....##...
###..#..#.#...#.....#.#.......#
.........#..#.#.....#.........#
.##..#.........#.#.....##......
.....#..........#.#.##....#....
........#.##.....#...##...#....
#.#.#...#......##....#.###.....
.#.##.....##.....#....#.##.#.##
.#...#.....##.#.##....#.....#.#
...#.....#........#............
##...####..#....#..##...#......
#.......#...#.#...#........#..#
......#.....#....#..#..#.#.....
..............##.....#.##....##
.#..##.........###..#..........
......#......#............#..#.
#.....###...###..........#.....
...###...........#....##..#....
.....................#...#.##..
###....#.#....#...#....#.#..##.
..#.............#.#....#..#.#..
.......#..###....#...#...#...#.
.##..#....##..............##...
...#...#..#..#.##.#....##...#..
#..#....##......#....###..####.
.##...#.#....#..#..#....#....#.
.#.##..#..#.........#.#......##
#..#.................#.....#...
..#............#........#...#..
##.##.......#.#....#..#....##.#
..##...#.#.....#......#........
......#.##.........##...#......
......##.#......#.##....##.#..#
.#.#......####.#.#.#.#..#......
..#.#....#...###....#.#...###..
.#.#...#....##..###.#..#.......
..#.....##..#............#..#.#
.#...#....#.....#....#..#.#.#..
..#....#..#......##...##......#
....#.......#.##.#.........#..#
#............#...##.....#..##..
......#..#..........#.#..#.....
...........#.#..#...##.#...#..#
.........###..#......##.###.#..
.....#....#......#...#....##...
..#.......#..#.#.#......#......
.#....#.....#.#.#.##...#....##.
....#.##.##.......#..#.....#...
.#.....#......#.......#..#.....
....###.....##.....##..#.#...#.
#.......#.#....#.#.#....#......
#...#..#.#......#...##.#.......
....##.##....#..#.......#..#.#.
.#.##.#.#..#.....#.#.......##..
..#..#..#..#.###...............
#.#......##....##.#.#.....#.#..
..##...#.........#.#..#.##..#..
.........####...#.....##.#.....
..#...................#.###....
..#.....#..#....#..#...........
.....###.#.........#.#.........
#..#..#........#..#......#..#..
###..##...#.......#........#.#.
.#.#.#.###.#............##.....
#..............#......#....#.##
.#...#..###...###.#..#.#.......
.###....##.#.......#.#.....###.
.##.....#.#....................
#..#.....#.....#...#.....#..##.
#.#....##..#......##..#...##..#
...........#....#..#.##.##....#
......#.......##....#.#....#.#.
###..#.#..........#.......#.#..
..#.#..##....##............##..
..#.....#..#....###............
.#...#...##...#..#..#..#.#....#
...#....#........#.............
#.#......#.#.....##..........#.
....#..#...............#...##..
........#..#....#..#..#..##....
....#......#.#.#...#.......#.##
.#.....#.#.#........###....#...
.#..#.......#...........#...#..
#.#.#####..#......#...#.#.###..
...##...#.#.....#..#...#...#...
..#....#.....#..#....#.#.....#.
....#.......#.....#........###.
..##..........#...###.......#..
#.#.##..#........##...#.#......
....##...#......#..........#.#.
#.......#..#.##.............#..
......#..........#...#....#...#
#.#.....#.##.#.#.............##
#...#.........##.##......#.##..
.........##.....#....#...##..#.
#.#...##.#...#.....##...#..#..#
......##.#.....#.#.....#.##....
....#.............#...#.......#
.#......##...#.#...#.##........
...#..#..#...........#..#..#.#.
.#...#...........#.#.##....#...
..#...#...#.#..#....#..#..#....
..###..##..#..#.........#.#..#.
....#.##.#...#.......#...#.....
.#.#.................#.......#.
.#..#.....#.##...#.#.....#...#.
.#.......#...#....#.......#....
###....##....#..#...#.#..##....
.........#.#.#.#...###.......##
....##.......#......#......##..
......##.###.#..#...#.#.#.#....
.#.###.#.#......#.#.......##...
.#.....##..#.#.....#...#.##....
.#..##.#.....#........###...#.#
.......#.#...........#........#
..........#...##..##.......#.#.
...#..#..#...#....#.#......#.#.
....#...#..#....#....#.#.##....
...#.#...##...#...##..#........
..#........#...##.#...##.#.#.#.
...##.#..#.......###.#.#.#.....
..##......#.#.#.........###.#..
.......#.#...##...#.#.......#.#
.#....##..#..#....#..#...#.....
.#....#.#.......#..#..##.#....#
#.#..##..#.#............#....#.
##..#....#.##.#....#...#..##...
.###.#.#..#...##........###.##.
...........#..#...#..#.#..###..
.#.#.#...#....#...##.##........
.....###.........#......#####..
#.#.#.....#....#..#...#.#.#.#..
..##.....#..#..#.#.#...#....#.#
......#.##..##..#.#.#.......#..
...#.#..###.........#........#.
......#.##..####...#...#..#...#
#.......#.........#....#....###
#......#...#........#.##....###
.#.#..............#...#...###.#
.#....####...#..##.###.....#...
.......#......#..#...#..##.#...
...........#.......#...........
..............#...#.#.#.#...##.
.###.....##.#.....#..........#.
##.##......#....##..#.....###.#
#.......#...##...#....##...#...
##.#.##...#....#....#....#.....
.....####...........#.#......#.
......#...#....#..#......#.....
...#...##..........#.......##.#
.#....#..........#.####........
...##...#..#...##........##..#.
.........##....#...##..#.##.#..
##.#.....#.......#.....#.......
#..#....#.##.#........#........
#.#...#...##........#.#.....###
....#...................#.#.#..
.......#..#.#...#....#.##.#....
....##...###.#.#.##...#...#....
.#....#....#...##.#......#...#.
............##..#.#.#........#.
...#....#.....#......#........#
...#.#.....#.##.....#....#...#.
.....#..##.......#.##.......#.#
........##................#....
....#..###...##.#..#...#......#
.#.#.......#.......#....##.#..#
..#........#............#......
..##.......#..#..#....#....#..#
#...###.......#.##...#.........
.....#...#...#..##..#....#..#..
.##.#..#...##.........###.#....
..#.#..#...#...####.#...#.#.#.#
#....#..###.....#......#.##..##
##......#...##...###......#.##.
...........#.....##...#...#...#
..#..#.#.....#..#.....###...#..
.............#..........###...#
....##............#....###.##.#
..##.#..##.....#.#.........#.#.
....#.#...........####.........
.##.###.##.#.#......#.##.#.#...
.....##.........#..#.......#...
...........#.........#....###..
...#.#..#..........#.....#..#..
.#..###.......##........#.#....
.#...###.....#..#.#..#...#.##..
##...###.#.#....#......#...#..#
....#.......#..#..##..#.#......
#.#......#.##..#......#..#....#
....#..#..#.....#.#......#..#..
..#...###......##.............#
..#....####...##.#...##.#......
.....#.......###...............
.......#...#.#.......#.#.##.###
.#.#...#.....#...##.........#..
..#..........#..#.........##...

2
data/day4.expected Normal file
View file

@ -0,0 +1,2 @@
202
137

1068
data/day4.input Normal file

File diff suppressed because it is too large Load diff

2
data/day5.expected Normal file
View file

@ -0,0 +1,2 @@
998
676

960
data/day5.input Normal file
View file

@ -0,0 +1,960 @@
BFBBBBBLLR
BBFFBBFRRL
FBFBFFFRRL
BBFFFBFRRL
BFFBFBFRLL
FFBBBFBLRL
BFFFBFFLLR
FBFFFFBLRR
FBFFBBBRRR
BFFBFFFLLR
BFFFFFBLLL
FFBBFFBLRR
BFFFFFBRLR
FBFBFBFLLL
FFBFBFFLLL
BBFFFFFLLL
FFFBBBFLLL
BBFFBFBLLR
FFBFBFBRRR
BFFBFFFRRR
BBFFBFBRLR
FFFBFBFLRL
BBFFBBBLRR
FBBFFFFLLR
BBBFBBFLLL
BFFFFBBRLL
FBBFBFBRRL
FFBBBFFRRR
BBFFFFBRRR
FBBBBFFLLR
BFFFFFBLRR
FFBBFBFLLR
BFFBFBBLLL
BBFBBBBLLL
FBFBBBFRLL
FFBFFFBLRL
FFFFBBBLRL
BBBBFBFRRR
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L
BBBFFBFRLR
BFFFFBFLLL
FFBBBBFRLL
BBFBBFFRLL
BFFFBFFLRR
BBFBBBFLLR
FFBFBBFLRL
BBBBFFBLRL
BFBBBFBRRR
FBBFBFFLLL
FBFFBFFRLR
BFFBFFFLRL
FBFFBFFLLR
FBFBBBBRLL
BBFFFBFLRL
BBFBBFBLRR
BFFFFBBLRL
BBFBFBFLRL
FBBFBBBRLL
FBBFFFFRLL
FFBFBBBLLL
FFBFFBBLLR
BFBBBFFLLR
BBBFBFFRLR
BFFBFFFRRL
BBFFBBBRLL
BBFFBBFRLL
FBBBBBBLLR
BFFBFBBRRR
BBFFFBBRRL
FFBFFFFRLL
FFFBFBBLRR
BBFFBFBRRL
BBFFFBBLRL
FBFFFFBLRL
BFFFFBFRLL
BFFBBBFLLL
BFBBFBFRRL
FBBFFFBLRR
FFBFFFFRLR
FBBFFFFLLL
FBFBBFFRRR
FBFBBFFLLR
FFBFFFBRRL
BFBBBBFRLL
BFFBBBFLRL
FBFFBFBRRL
FFBFFFFLRR
FBBBFBBRLL
BBFBBBFRRR
BFFBFFFRLL
FFFBBFFRRL
BFBFFFBLLR
FBFFFBFRLR
FBFBBBFLLL
FFBBFBFRRL
BBBFBFFRLL
FBFFBFFLRR
BBFBBBFLRR
FFBBBFBLRR
FFFBFFFRLR
FBFBFFBLLL
BFBBBFFLLL
BFFFFBBLRR
FBFBBBFLLR
FBFFBBFLRR
FFBBFBBRRL
BBFBFFFLRR
BBFFBFFRRL
FFBBFFFLLL
FFBFBFFRRL
BBBFBFBRLR
BFBFFFBRLR
FBFBBBBLLL
FFBBBBBRLL
FBBFBBBLLL
BFFFBBFRRR
BFBFFBFRLR
BBBFFFFRLR
FBFFBBFRLL
FFBBFBFRLR
BFFBFBBRLL
BFBFBFFRRR
FBBFFFBRLL

2
data/day6.expected Normal file
View file

@ -0,0 +1,2 @@
6683
3122

2179
data/day6.input Normal file

File diff suppressed because it is too large Load diff

52
test.sh Executable file
View file

@ -0,0 +1,52 @@
#!/usr/bin/bash
set -euo pipefail
cd "$(dirname "${BASH_SOURCE[0]}")"
run_solution() {
if [ -d "$solution" ]; then
runfile=$solution/run.sh
[ -f "$runfile" ] || { echo "Error: $runfile not found"; exit 1; }
"$runfile" "$input"
else
case "$(basename "$solution")" in
*.hs)
runhaskell -icommon "$solution" < "$input"
;;
*.py)
python "$solution" < "$input"
;;
*)
echo "Error: Unknown solution type: $solution"
exit 1
;;
esac
fi
}
for day in day*; do
input=data/$day.input
expected=data/$day.expected
for solution in "$day"/*; do
echo -n "$solution... "
solution_output=$(mktemp)
trap "rm $solution_output" EXIT
run_solution "$solution" > "$solution_output"
if ! diff -u "$expected" "$solution_output"; then
echo FAIL
rv=$?
case "$rv" in
1)
exit 2
;;
*)
exit 1
;;
esac
else
echo ok
fi
done
done