Tests
(t *testing.T)
| 4 | |
| 5 | // Tests |
| 6 | func TestProblem19_Func(t *testing.T) { |
| 7 | tests := []struct { |
| 8 | name string |
| 9 | expected int |
| 10 | }{ |
| 11 | {"Problem 19 - Counting Sundays", 171}, |
| 12 | } |
| 13 | |
| 14 | for _, test := range tests { |
| 15 | t.Run(test.name, func(t *testing.T) { |
| 16 | got := Problem19() |
| 17 | if got != test.expected { |
| 18 | t.Errorf("Problem19() = got %v, want %v", got, test.expected) |
| 19 | } |
| 20 | }) |
| 21 | } |
| 22 | } |
| 23 | |
| 24 | // Benchmarks |
| 25 | func BenchmarkProblem19_Func(b *testing.B) { |
nothing calls this directly
no test coverage detected