summaryrefslogtreecommitdiffstats
path: root/test/unit/helpers
diff options
context:
space:
mode:
authorJean-Philippe Lang <jp_lang@yahoo.fr>2017-01-30 19:37:55 +0000
committerJean-Philippe Lang <jp_lang@yahoo.fr>2017-01-30 19:37:55 +0000
commit6ef7a0fc2dc34adf78415c8a2b5ecf86eaf21f3a (patch)
tree7fbe16e194a2c87911538476c81958c1a1f5110a /test/unit/helpers
parent65804c34f3d19791b77df01898e6af18048c06d9 (diff)
downloadredmine-6ef7a0fc2dc34adf78415c8a2b5ecf86eaf21f3a.tar.gz
redmine-6ef7a0fc2dc34adf78415c8a2b5ecf86eaf21f3a.zip
Adds a test for #24922.
git-svn-id: http://svn.redmine.org/redmine/trunk@16312 e93f8b46-1217-0410-a6f0-8f06a7374b81
Diffstat (limited to 'test/unit/helpers')
-rw-r--r--test/unit/helpers/application_helper_test.rb6
1 files changed, 6 insertions, 0 deletions
diff --git a/test/unit/helpers/application_helper_test.rb b/test/unit/helpers/application_helper_test.rb
index 943f7a452..a0d88eb5d 100644
--- a/test/unit/helpers/application_helper_test.rb
+++ b/test/unit/helpers/application_helper_test.rb
@@ -169,6 +169,12 @@ RAW
end
end
+ def test_attached_images_with_hires_naming
+ attachment = Attachment.generate!(:filename => 'image@2x.png')
+ assert_equal %(<p><img src="/attachments/download/#{attachment.id}/image@2x.png" srcset="/attachments/download/#{attachment.id}/image@2x.png 2x" alt="" /></p>),
+ textilizable("!image@2x.png!", :attachments => [attachment])
+ end
+
def test_attached_images_filename_extension
set_tmp_attachments_directory
a1 = Attachment.new(