mirror of
https://github.com/onyx-and-iris/aoc2023.git
synced 2024-11-22 10:20:48 +00:00
26 lines
432 B
Go
26 lines
432 B
Go
|
package main
|
||
|
|
||
|
import (
|
||
|
"testing"
|
||
|
|
||
|
"github.com/stretchr/testify/assert"
|
||
|
)
|
||
|
|
||
|
func TestTwo(t *testing.T) {
|
||
|
//t.Skip("skipping test")
|
||
|
input := []string{
|
||
|
"two1nine",
|
||
|
"eightwothree",
|
||
|
"abcone2threexyz",
|
||
|
"xtwone3four",
|
||
|
"4nineeightseven2",
|
||
|
"zoneight234",
|
||
|
"7pqrstsixteen",
|
||
|
}
|
||
|
retval, _ := two(input)
|
||
|
|
||
|
t.Run("Return the sum of all calibrated numbers, solution two", func(t *testing.T) {
|
||
|
assert.Equal(t, 281, retval)
|
||
|
})
|
||
|
}
|