1
0
Fork 0
mirror of https://github.com/miniflux/v2.git synced 2025-08-01 17:38:37 +00:00

Add FeedIcon API call and update dependencies

This commit is contained in:
Frédéric Guillot 2017-12-16 11:25:18 -08:00
parent 231ebf2daa
commit 27196589fb
262 changed files with 83830 additions and 30061 deletions

30
vendor/golang.org/x/text/message/fmt_test.go generated vendored Executable file → Normal file
View file

@ -1786,7 +1786,12 @@ func TestNilDoesNotBecomeTyped(t *testing.T) {
type B struct{}
var a *A = nil
var b B = B{}
got := p.Sprintf("%s %s %s %s %s", nil, a, nil, b, nil) // go vet should complain about this line.
// indirect the Sprintf call through this noVetWarn variable to avoid
// "go test" failing vet checks in Go 1.10+.
noVetWarn := p.Sprintf
got := noVetWarn("%s %s %s %s %s", nil, a, nil, b, nil)
const expect = "%!s(<nil>) %!s(*message.A=<nil>) %!s(<nil>) {} %!s(<nil>)"
if got != expect {
t.Errorf("expected:\n\t%q\ngot:\n\t%q", expect, got)
@ -1864,26 +1869,3 @@ func TestFormatterFlags(t *testing.T) {
}
}
}
func TestParsenum(t *testing.T) {
testCases := []struct {
s string
start, end int
num int
isnum bool
newi int
}{
{"a123", 0, 4, 0, false, 0},
{"1234", 1, 1, 0, false, 1},
{"123a", 0, 4, 123, true, 3},
{"12a3", 0, 4, 12, true, 2},
{"1234", 0, 4, 1234, true, 4},
{"1a234", 1, 3, 0, false, 1},
}
for _, tt := range testCases {
num, isnum, newi := parsenum(tt.s, tt.start, tt.end)
if num != tt.num || isnum != tt.isnum || newi != tt.newi {
t.Errorf("parsenum(%q, %d, %d) = %d, %v, %d, want %d, %v, %d", tt.s, tt.start, tt.end, num, isnum, newi, tt.num, tt.isnum, tt.newi)
}
}
}