This commit is contained in:
Gareth
2025-01-10 20:44:19 +00:00
parent a5b1227979
commit 305ce52a98
4 changed files with 173 additions and 4 deletions

View File

@@ -0,0 +1,39 @@
package day08
import (
"testing"
"github.com/stretchr/testify/assert"
)
func TestPart1(t *testing.T) {
r := Part1(`............
........0...
.....0......
.......0....
....0.......
......A.....
............
............
........A...
.........A..
............
............`)
assert.Equal(t, 14, r)
}
func TestPart2(t *testing.T) {
r := Part2(`............
........0...
.....0......
.......0....
....0.......
......A.....
............
............
........A...
.........A..
............
............`)
assert.Equal(t, 11387, r)
}