mirror of
https://github.com/willnorris/imageproxy.git
synced 2026-04-25 04:46:24 +02:00
scaleup flag
This commit is contained in:
parent
f6e6a2cc86
commit
4e60c683b0
7 changed files with 57 additions and 15 deletions
|
|
@ -29,11 +29,11 @@ func TestOptions_String(t *testing.T) {
|
|||
"0x0",
|
||||
},
|
||||
{
|
||||
Options{1, 2, true, 90, true, true, 80, ""},
|
||||
Options{1, 2, true, 90, true, true, 80, "", false},
|
||||
"1x2,fit,r90,fv,fh,q80",
|
||||
},
|
||||
{
|
||||
Options{0.15, 1.3, false, 45, false, false, 95, "c0ffee"},
|
||||
Options{0.15, 1.3, false, 45, false, false, 95, "c0ffee", false},
|
||||
"0.15x1.3,r45,q95,sc0ffee",
|
||||
},
|
||||
}
|
||||
|
|
@ -82,8 +82,8 @@ func TestParseOptions(t *testing.T) {
|
|||
{"FOO,1,BAR,r90,BAZ", Options{Width: 1, Height: 1, Rotate: 90}},
|
||||
|
||||
// all flags, in different orders
|
||||
{"q70,1x2,fit,r90,fv,fh,sc0ffee", Options{1, 2, true, 90, true, true, 70, "c0ffee"}},
|
||||
{"r90,fh,sc0ffee,q90,1x2,fv,fit", Options{1, 2, true, 90, true, true, 90, "c0ffee"}},
|
||||
{"q70,1x2,fit,r90,fv,fh,sc0ffee", Options{1, 2, true, 90, true, true, 70, "c0ffee", false}},
|
||||
{"r90,fh,sc0ffee,q90,1x2,fv,fit", Options{1, 2, true, 90, true, true, 90, "c0ffee", false}},
|
||||
}
|
||||
|
||||
for _, tt := range tests {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue