diff options
author | Go MAEDA <maeda@farend.jp> | 2023-01-16 01:23:36 +0000 |
---|---|---|
committer | Go MAEDA <maeda@farend.jp> | 2023-01-16 01:23:36 +0000 |
commit | 91705e083beeece533afcad8b7285f6698c2a6da (patch) | |
tree | b50243551846b55f68c08a15a636164e5c9aec11 /test/unit/lib | |
parent | 33088ed3c20bfa8c1d45fbdc9f17b0e2ea69a578 (diff) | |
download | redmine-91705e083beeece533afcad8b7285f6698c2a6da.tar.gz redmine-91705e083beeece533afcad8b7285f6698c2a6da.zip |
Support for WebP images (#38168).
* Inline image
* Thumbnail
* Inserting markup for an image uploaded by drag and drop
Patch by Go MAEDA.
git-svn-id: https://svn.redmine.org/redmine/trunk@22045 e93f8b46-1217-0410-a6f0-8f06a7374b81
Diffstat (limited to 'test/unit/lib')
-rw-r--r-- | test/unit/lib/redmine/mime_type_test.rb | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/test/unit/lib/redmine/mime_type_test.rb b/test/unit/lib/redmine/mime_type_test.rb index cbf1d3dec..943fef03c 100644 --- a/test/unit/lib/redmine/mime_type_test.rb +++ b/test/unit/lib/redmine/mime_type_test.rb @@ -77,6 +77,12 @@ class Redmine::MimeTypeTest < ActiveSupport::TestCase end end + def test_by_type + image_types = Redmine::MimeType.by_type('image') + assert_includes image_types, 'image/png' + assert_includes image_types, 'image/webp' + end + def test_should_default_to_mime_type_gem assert !Redmine::MimeType::EXTENSIONS.key?("zip") assert_equal "application/zip", Redmine::MimeType.of("file.zip") |