Files
advent-of-code/internal/2015/DaySix/code_test.go
2025-12-01 20:52:57 +01:00

26 lines
483 B
Go

package daysix
import "testing"
var testInput = []string{
"turn on 0,0 through 999,999",
"toggle 0,0 through 999,0",
"turn off 499,499 through 500,500",
}
func TestPartOne(t *testing.T) {
expected := 998996
got := PartOne(testInput)
if got != expected {
t.Errorf("PartOne() = %d, want %d", got, expected)
}
}
func TestPartTwo(t *testing.T) {
expected := 1001996
got := PartTwo(testInput)
if got != expected {
t.Errorf("PartTwo() = %d, want %d", got, expected)
}
}