Update fmt_test.go

- changed default value
This commit is contained in:
Vladimir Kuznetsov 2020-03-01 08:56:17 +00:00 committed by Arseny Balobanov
parent 87fe7a193a
commit 2f8b92da34

View file

@ -11,8 +11,8 @@ import (
func TestFormat(t *testing.T) { func TestFormat(t *testing.T) {
s := make([]interface{}, 1002) s := make([]interface{}, 1002)
s[10] = 1 s[10] = 1
s[100] = 1 s[100] = 2
s[1000] = 1 s[1000] = 3
for _, tc := range []struct { for _, tc := range []struct {
format string format string
@ -57,12 +57,12 @@ func TestFormat(t *testing.T) {
{ {
format: "{100}", format: "{100}",
args: s[:101], args: s[:101],
result: "1", result: "2",
}, },
{ {
format: "{1000}", format: "{1000}",
args: s[:1001], args: s[:1001],
result: "1", result: "3",
}, },
} { } {
t.Run(tc.result, func(t *testing.T) { t.Run(tc.result, func(t *testing.T) {