1
0
mirror of https://github.com/imgproxy/imgproxy.git synced 2025-12-01 23:11:31 +02:00

Use source image format as resulting one dy default

This commit is contained in:
DarthSim
2018-11-14 00:50:38 +06:00
parent 00b690e93d
commit da1a802632
5 changed files with 14 additions and 7 deletions

View File

@@ -37,7 +37,7 @@ func (s *ProcessingOptionsTestSuite) TestParseBase64URLWithoutExtension() {
require.Nil(s.T(), err)
assert.Equal(s.T(), imageURL, getImageURL(ctx))
assert.Equal(s.T(), imageTypeJPEG, getProcessingOptions(ctx).Format)
assert.Equal(s.T(), imageTypeUnknown, getProcessingOptions(ctx).Format)
}
func (s *ProcessingOptionsTestSuite) TestParseBase64URLWithBase() {
@@ -78,7 +78,7 @@ func (s *ProcessingOptionsTestSuite) TestParsePlainURLWithoutExtension() {
require.Nil(s.T(), err)
assert.Equal(s.T(), imageURL, getImageURL(ctx))
assert.Equal(s.T(), imageTypeJPEG, getProcessingOptions(ctx).Format)
assert.Equal(s.T(), imageTypeUnknown, getProcessingOptions(ctx).Format)
}
func (s *ProcessingOptionsTestSuite) TestParsePlainURLEscaped() {
imageURL := "http://images.dev/lorem/ipsum.jpg?param=value"