diff --git a/test/unit/aaa_string_test.rb b/test/unit/aaa_string_test.rb index e1068e711..325e02c84 100644 --- a/test/unit/aaa_string_test.rb +++ b/test/unit/aaa_string_test.rb @@ -991,7 +991,7 @@ html.html2html_strict html = '' (body, attachments_inline) = HtmlSanitizer.replace_inline_images(html) assert_match(//, body) - assert(1, attachments_inline.count) + assert_equal(1, attachments_inline.count) assert_equal('image1.jpeg', attachments_inline[0][:filename]) assert_equal('image/jpeg', attachments_inline[0][:preferences]['Content-Type']) assert_match(/@#{Setting.get('fqdn')}/, attachments_inline[0][:preferences]['Content-ID']) @@ -1000,7 +1000,7 @@ html.html2html_strict html = 'abc' (body, attachments_inline) = HtmlSanitizer.replace_inline_images(html) assert_match(/abc/, body) - assert(1, attachments_inline.count) + assert_equal(1, attachments_inline.count) assert_equal('image1.jpeg', attachments_inline[0][:filename]) assert_equal('image/jpeg', attachments_inline[0][:preferences]['Content-Type']) assert_match(/@#{Setting.get('fqdn')}/, attachments_inline[0][:preferences]['Content-ID']) @@ -1009,7 +1009,7 @@ html.html2html_strict html = 'abc/, body) - assert(1, attachments_inline.count) + assert_equal(1, attachments_inline.count) assert_equal('image1.jpeg', attachments_inline[0][:filename]) assert_equal('image/jpeg', attachments_inline[0][:preferences]['Content-Type']) assert_match(/@#{Setting.get('fqdn')}/, attachments_inline[0][:preferences]['Content-ID']) @@ -1018,12 +1018,12 @@ html.html2html_strict html = 'abc' (body, attachments_inline) = HtmlSanitizer.replace_inline_images(html) assert_match(/abc/, body) - assert(0, attachments_inline.count) + assert_equal(0, attachments_inline.count) html = '

123

' (body, attachments_inline) = HtmlSanitizer.replace_inline_images(html) assert_match(/
\s+

123<\/p>\s+\s+<\/div>/, body) - assert(2, attachments_inline.count) + assert_equal(2, attachments_inline.count) assert_equal('image1.jpeg', attachments_inline[0][:filename]) assert_equal('image/jpeg', attachments_inline[0][:preferences]['Content-Type']) assert_match(/@#{Setting.get('fqdn')}/, attachments_inline[0][:preferences]['Content-ID'])