feat: solve day 1 part 1
This commit is contained in:
@@ -0,0 +1,21 @@
|
||||
package file_test
|
||||
|
||||
import (
|
||||
"slices"
|
||||
"testing"
|
||||
|
||||
"github.com/StevanFreeborn/advent-of-code-2025/internal/file"
|
||||
)
|
||||
|
||||
func TestReadLines(t *testing.T) {
|
||||
expectedLines := []string{
|
||||
"hello",
|
||||
"world",
|
||||
}
|
||||
|
||||
result := file.ReadLines("test.txt")
|
||||
|
||||
if slices.Equal(result, expectedLines) == false {
|
||||
t.Errorf("got %s but expected %s", result, expectedLines)
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user