# rubocop:disable all require 'test_helper' class AaaStringTest < ActiveSupport::TestCase test 'strip' do raw = ' test ' result = 'test' assert_equal(raw.strip, result) raw = "test\n" result = 'test' assert_equal(raw.strip, result) raw = " test \n test " result = "test \n test" assert_equal(raw.strip, result) raw = " \r\n test \u{200B} \n test\u{200B} \u{200B}" result = "test \u{200B} \n test" assert_equal(raw.strip, result) raw = "\xC2\xA92011 Z ".force_encoding('ASCII-8BIT') result = "\xC2\xA92011 Z".force_encoding('ASCII-8BIT') assert_equal(raw.strip, result) end test 'strip!' do raw = ' test ' result = 'test' raw.strip! assert_equal(raw, result) raw = "test\n" result = 'test' raw.strip! assert_equal(raw, result) raw = " test \n test " result = "test \n test" raw.strip! assert_equal(raw, result) raw = " \r\n test \u{200B} \n test\u{200B} \u{200B}" result = "test \u{200B} \n test" raw.strip! assert_equal(raw, result) raw = "\xC2\xA92011 Z ".force_encoding('ASCII-8BIT') result = "\xC2\xA92011 Z".force_encoding('ASCII-8BIT') raw.strip! assert_equal(raw, result) end test 'to_filename ref' do modul = 'test' result = 'test' modul.to_filename assert_equal(result, modul) modul = 'Some::File' result = 'Some::File' modul.to_filename assert_equal(result, modul) end test 'to_filename function' do modul = 'test' result = 'test' assert_equal(result, modul.to_filename) modul = 'Some::File' result = 'some/file' assert_equal(result, modul.to_filename) end test 'to_classname ref' do modul = 'test' result = 'test' modul.to_filename assert_equal(result, modul) modul = 'some/file' result = 'some/file' modul.to_filename assert_equal(result, modul) end test 'to_classname function' do modul = 'test' result = 'Test' assert_equal(result, modul.to_classname) modul = 'some/file' result = 'Some::File' assert_equal(result, modul.to_classname) modul = 'some/files' result = 'Some::Files' assert_equal(result, modul.to_classname) modul = 'some_test/files' result = 'SomeTest::Files' assert_equal(result, modul.to_classname) end test 'html2text ref' do html = 'test' result = 'test' html.html2text assert_equal(result, html) html = '
test
' result = '
test
' html.html2text assert_equal(result, html) end test 'html2text function' do html = 'test' result = 'test' assert_equal(result, html.html2text) html = ' test ' result = 'test' assert_equal(result, html.html2text) html = "\n\n test \n\n\n" result = 'test' assert_equal(result, html.html2text) html = '
test
' result = 'test' assert_equal(result, html.html2text) html = '
test
' result = 'test' assert_equal(result, html.html2text) html = "
test


\n
\n
\n
" result = 'test' assert_equal(result, html.html2text) html = "
test


\n
\n
\n
" result = 'test' assert_equal(result, html.html2text) html = "
test

 
 \n
 \n
 \n
" result = 'test' assert_equal(result, html.html2text) html = "
test

 
 \n
 \n
 \n
 " result = 'test' assert_equal(result, html.html2text) html = "
test\n\ntest
" result = "test\ntest" assert_equal(result, html.html2text) html = "test\n\ntest" result = "test\ntest" assert_equal(result, html.html2text) html = '
testcol
test4711
' result = "test col\ntest 4711" assert_equal(result, html.html2text) html = "

Was\nsoll verbessert werden:

" result = 'Was soll verbessert werden:' assert_equal(result, html.html2text) html = "
test


\n
\n
\n
" result = 'test' assert_equal(result, html.html2text) html = "\n
Best Tool of the World some other text
" result = "[1] Best Tool of the Worldsome other text\n\n[1] https://zammad.org" assert_equal(result, html.html2text) html = "
test


\n
\n
\n
" result = "test\n\n___" assert_equal(result, html.html2text) html = "test


--
abc
" result = "test\n\n--\nabc" assert_equal(result, html.html2text) html = "Ihr RZ-Team

" result = 'Ihr RZ-Team' assert_equal(result, html.html2text) html = ' Neues Fax von 1234-93900 ' result = "" assert_equal(result, html.html2html_strict) html = "
Dear Bob:Mr/Mrs

We are one of the leading manufacturer and supplier of conduits and cars since 3000.

Could you inform me the specification you need?

May I sent you our products catalogues for your reference?

Best regards!

Welcome to our booth B11/1 Hall 13 during SOMEWHERE\n9999.
Bob Smith
Exp. & Imp.
Town Example Electric Co., Ltd.
Tel: 0000-11-12345678 (Ext-220)  Fax: 0000-11-12345678 
Room1234, NO. 638, Smith Road, Town, 200000, Somewhere
Web: www.example.com
" result = "
\n
Dear Bob:Mr/Mrs
 
We are one of the leading manufacturer and supplier of conduits and cars since 3000.
 
Could you inform me the specification you need?
 
May I sent you our products catalogues for your reference?
 
Best regards!
 
Welcome to our booth B11/1 Hall 13 during SOMEWHERE 9999.
\n
Bob Smith
\n
Exp. & Imp.
Town Example Electric Co., Ltd.
Tel: 0000-11-12345678 (Ext-220) Fax: 0000-11-12345678
Room1234, NO. 638, Smith Road, Town, 200000, Somewhere
Web: www.example.com
" assert_equal(result, html.html2html_strict) html = '
  • Luxemburg
  • ' result = '
  • Luxemburg
  • ' assert_equal(result, html.html2html_strict) end test 'inline attachment replace' do html = '' (body, attachments_inline) = HtmlSanitizer.replace_inline_images(html) assert_match(//, body) assert(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']) assert_equal('inline', attachments_inline[0][:preferences]['Content-Disposition']) html = 'abc' (body, attachments_inline) = HtmlSanitizer.replace_inline_images(html) assert_match(/abc/, body) assert(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']) assert_equal('inline', attachments_inline[0][:preferences]['Content-Disposition']) html = 'abc/, body) assert(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']) assert_equal('inline', attachments_inline[0][:preferences]['Content-Disposition']) html = 'abc' (body, attachments_inline) = HtmlSanitizer.replace_inline_images(html) assert_match(/abc/, body) assert(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('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']) assert_equal('inline', attachments_inline[0][:preferences]['Content-Disposition']) assert_equal('image2.jpeg', attachments_inline[1][:filename]) assert_equal('image/jpeg', attachments_inline[1][:preferences]['Content-Type']) assert_match(/@#{Setting.get('fqdn')}/, attachments_inline[1][:preferences]['Content-ID']) assert_equal('inline', attachments_inline[1][:preferences]['Content-Disposition']) end test 'set dynamic image size' do html = '' body = HtmlSanitizer.dynamic_image_size(html) assert_match(//, body) html = 'abc' body = HtmlSanitizer.dynamic_image_size(html) assert_match(/abc/, body) html = 'abc' body = HtmlSanitizer.dynamic_image_size(html) assert_match(/abc/, body) html = 'abc' body = HtmlSanitizer.dynamic_image_size(html) assert_match(/abc/, body) end test 'signature_identify function' do marker_template = '######SIGNATURE_MARKER######' source = 'test' result = 'test' assert_equal(result, source.signature_identify('text', true)) source = "test\n--\nend" result = "test\n#{marker_template}--\nend" assert_equal(result, source.signature_identify('text', true)) source = "On 01/04/15 10:55, Bob Smith wrote:" result = "#{marker_template}On 01/04/15 10:55, Bob Smith wrote:" assert_equal(result, source.signature_identify('text', true)) source = "Am 03.04.2015 um 20:58 schrieb Martin Edenhofer :" result = "#{marker_template}Am 03.04.2015 um 20:58 schrieb Martin Edenhofer :" assert_equal(result, source.signature_identify('text', true)) source = "\ntest 123 \n1\n2\n3\n4\n5\n6\n7\n8\n9\n--\nBob Smith\n" result = "\ntest 123 \n1\n2\n3\n4\n5\n6\n7\n8\n9\n#{marker_template}--\nBob Smith\n" assert_equal(result, source.signature_identify('text', true)) source = "test 123 \n--no not match--\n--\nBob Smith\n" result = "test 123 \n--no not match--\n#{marker_template}--\nBob Smith\n" assert_equal(result, source.signature_identify('text', true)) source = "test 123 \n--no not match--\n -- \nBob Smith\n" result = "test 123 \n--no not match--\n#{marker_template} -- \nBob Smith\n" assert_equal(result, source.signature_identify('text', true)) source = "test 123 \n\n--\nBob Smith\n\n\n\n\n--\nBob Smith\n" result = "test 123 \n#{marker_template}\n--\nBob Smith\n\n\n\n\n--\nBob Smith\n" assert_equal(result, source.signature_identify('text', true)) source = "test 123\ntest 123\n--\nBob Smith\n" result = "test 123\ntest 123\n#{marker_template}--\nBob Smith\n" assert_equal(result, source.signature_identify('text', true)) source = "test 123\ntest 123\n--\nBob Smith\n\n" result = "test 123\ntest 123\n#{marker_template}--\nBob Smith\n\n" assert_equal(result, source.signature_identify('text', true)) # apple # en source = "test 123 \n--no not match--\nBob Smith\nOn 01/04/15 10:55, Bob Smith wrote:\nlalala\n--\nsome test" result = "test 123 \n--no not match--\nBob Smith\n#{marker_template}On 01/04/15 10:55, Bob Smith wrote:\nlalala\n#{marker_template}--\nsome test" assert_equal(result, source.signature_identify('text', true)) # de source = "test 123 \n\n--no not match--\n\nBob Smith\nAm 03.04.2015 um 20:58 schrieb Bob Smith :\nlalala" result = "test 123 \n\n--no not match--\n\nBob Smith\n#{marker_template}Am 03.04.2015 um 20:58 schrieb Bob Smith :\nlalala" assert_equal(result, source.signature_identify('text', true)) # ms # en source = "test 123 \n\n--no not match--\n\nBob Smith\nFrom: Martin Edenhofer via Znuny Support [mailto:support@znuny.inc]\nSent: Donnerstag, 2. April 2015 10:00\nlalala

    " result = "test 123 \n\n--no not match--\n\nBob Smith\n#{marker_template}From: Martin Edenhofer via Znuny Support [mailto:support@znuny.inc]\nSent: Donnerstag, 2. April 2015 10:00\nlalala" assert_equal(result, source.signature_identify('text', true)) # de source = "test 123 \n\n--no not match--\n\nBob Smith\nVon: Martin Edenhofer via Znuny Support [mailto:support@znuny.inc]\nGesendet: Donnerstag, 2. April 2015 10:00\nBetreff: lalala\n" result = "test 123 \n\n--no not match--\n\nBob Smith\n#{marker_template}Von: Martin Edenhofer via Znuny Support [mailto:support@znuny.inc]\nGesendet: Donnerstag, 2. April 2015 10:00\nBetreff: lalala\n" assert_equal(result, source.signature_identify('text', true)) # fr source = "\ntest 123 \n\n--no not match--\n\nBob Smith\nDe : Martin Edenhofer via Znuny Support [mailto:support@znuny.inc]\nEnvoyé : mercredi 29 avril 2015 17:31\nObjet : lalala\n" result = "\ntest 123 \n\n--no not match--\n\nBob Smith\n#{marker_template}De : Martin Edenhofer via Znuny Support [mailto:support@znuny.inc]\nEnvoyé : mercredi 29 avril 2015 17:31\nObjet : lalala\n" assert_equal(result, source.signature_identify('text', true)) marker_template = '' html = "lalala
    --
    Max Mix" result = "lalala#{marker_template}
    --
    Max Mix" assert_equal(result, html.html2html_strict) marker_template = '' html = "lalala
    --
    Max Mix" result = "lalala#{marker_template}
    --
    Max Mix" assert_equal(result, html.html2html_strict) marker_template = '' html = "lalala
    --
    Max Mix" result = "lalala#{marker_template}
    --
    Max Mix" assert_equal(result, html.html2html_strict) marker_template = '' html = "lalala

    --

    Max Mix" result = "lalala#{marker_template}

    --

    Max Mix" assert_equal(result, html.html2html_strict) marker_template = '' html = "lalala
    __
    Max Mix" result = "lalala#{marker_template}
    __
    Max Mix" assert_equal(result, html.html2html_strict) html = "den.

    Von: Fritz Bauer [mailto:me@example.com]
    Gesendet: Donnerstag, 3. Mai 2012 11:51
    An: John Smith
    Cc: Smith, John Marian; johnel.fratczak@example.com; ole.brei@example.com; Günther John | Example GmbH; bkopon@example.com; john.heisterhagen@team.example.com; sven.rocked@example.com; michael.house@example.com; tgutzeit@example.com
    Betreff: Re: OTRS::XXX Erweiterung - Anhänge an CI's

    Hello,

    ich versuche an den Punkten" result = "den.
    #{marker_template}
    Von: Fritz Bauer [mailto:me@example.com]
    Gesendet: Donnerstag, 3. Mai 2012 11:51
    An: John Smith
    Cc: Smith, John Marian; johnel.fratczak@example.com; ole.brei@example.com; Günther John | Example GmbH; bkopon@example.com; john.heisterhagen@team.example.com; sven.rocked@example.com; michael.house@example.com; tgutzeit@example.com
    Betreff: Re: OTRS::XXX Erweiterung - Anhänge an CI's

    Hello,

    ich versuche an den Punkten" assert_equal(result, html.html2html_strict) html = '

    Von: Martin Edenhofer via Zammad Helpdesk [mailto:support@zammad.com]
    Gesendet: ' result = '

    Von: Martin Edenhofer via Zammad Helpdesk [mailto:support@example.com]
    Gesendet:

    ' assert_equal(result, html.html2html_strict) html = '

    Von: Johanna Kiefer via Znuny Projects <projects@example.com>
    Organisation: Znuny Group
    Datum: Montag, 6. März 2017 um 13:32
    ' result = '

    Von: Johanna Kiefer via Znuny Projects <projects@example.com>
    Organisation: Znuny Group
    Datum: Montag, 6. März 2017 um 13:32

    ' assert_equal(result, html.html2html_strict) html = '



    Von:        Hotel <info@example.com>
    An:        
    ' result = '

    Von: Hotel <info@example.com>
    An:
    ' assert_equal(result, html.html2html_strict) html = '
    On 04 Mar 2017, at 14:47, Oliver Ruhm <oliver@example.com> wrote:

    ' result = '
    On 04 Mar 2017, at 14:47, Oliver Ruhm <oliver@example.com> wrote:

    ' assert_equal(result, html.html2html_strict) html = '
    some note

    ' result = '
    some note

    ' assert_equal(result, html.html2html_strict) html = '

    Am 17.03.2017 um 17:03 schrieb Martin Edenhofer via Zammad Helpdesk <support@example.com>:

    ' result = '

    Am 17.03.2017 um 17:03 schrieb Martin Edenhofer via Zammad Helpdesk <support@example.com>:

    ' assert_equal(result, html.html2html_strict) html = '

    Am 17.03.2017 um 17:03 schrieb Martin Edenhofer via Zammad Helpdesk <support@example.com>:

    Dear Mr. Smith,
    ' result = '

    Am 17.03.2017 um 17:03 schrieb Martin Edenhofer via Zammad Helpdesk <support@example.com>:

    Dear Mr. Smith,
    ' assert_equal(result, html.html2html_strict) end end


    ' result = 'Neues Fax von 1234-93900 Neues Fax Ihre Kundennummer: 12345678' assert_equal(result, html.html2text) html = ' line 1
    you
    -----&' should = 'line 1 you -----&' assert_equal(should, html.html2text) html = '
    • #1
    • #2
    ' should = '* #1 * #2' assert_equal(should, html.html2text) html = '
    > Welcome!
    >
    > Thank you for installing Zammad.
    >
    ' should = '> Welcome! > > Thank you for installing Zammad. >' assert_equal(should, html.html2text) html = '

    some other content

    ' should = 'some other content' assert_equal(should, html.html2text) html = ' IT-Infrastruktur
    ' should = 'IT-Infrastruktur' assert_equal(should, html.html2text) html = "

    some head

    some content

    line 1

    line 2

    some text later

    " result = 'some head some content > line 1 > line 2 some text later' assert_equal(result, html.html2text) html = "

    some head

    some content
    line 1
    line 2

    some text later

    " result = 'some head some content > line 1 > line 2 some text later' assert_equal(result, html.html2text) html = "

    some head

    some content
    line 1

    line 2

    some text later" result = 'some head some content > line 1 > > line 2 some text later' assert_equal(result, html.html2text) html = "

    Best regards,

    Your Team Team

    P.S.: You receive this e-mail because you are listed in our database as person who ordered a Team license. Please click here to unsubscribe from further e-mails.

    -----------------------------
    " result = 'Best regards, Your Team Team P.S.: You receive this e-mail because you are listed in our database as person who ordered a Team license. Please click [1] here to unsubscribe from further e-mails. ----------------------------- [1] http://www.teamviewer.example/en/company/unsubscribe.aspx?id=1009645&ident=xxx' assert_equal(result, html.html2text) html = "

    Dave and leaned her days adam.
    Maybe we want any help me that.
    Next morning charlie saw at their father.
    Well as though adam took out here. Melvin will be more money. Called him into this one last thing.
    Men-----------------------
    " result = 'Dave and leaned her days adam. Maybe we want any help me that. Next morning charlie saw at their father. Well as though adam took out here. Melvin will be more money. Called him into this one last thing. Men-----------------------' assert_equal(result, html.html2text) end test 'html2html_strict function' do html = 'test' result = 'test' assert_equal(result, html.html2html_strict) html = ' test ' result = 'test' assert_equal(result, html.html2html_strict) html = "\n\n test \n\n\n" result = 'test' assert_equal(result, html.html2html_strict) html = 'test' result = 'test' assert_equal(result, html.html2html_strict) html = 'test' result = 'test' assert_equal(result, html.html2html_strict) html = 'test' result = 'test' assert_equal(result, html.html2html_strict) html = '

    test

    ' result = '

    test

    ' assert_equal(result, html.html2html_strict) html = '

    test

    ' result = '

    test

    ' assert_equal(result, html.html2html_strict) html = '

    test

    ' result = '

    test

    ' assert_equal(result, html.html2html_strict) html = '

    test

    ' result = '

    test

    ' assert_equal(result, html.html2html_strict) html = "
    \n\n\ntest\n\n\n
    " result = "
    test
    " assert_equal(result, html.html2html_strict) html = "
    \n\t\ntest\n\t\n
    " result = "
    test
    " assert_equal(result, html.html2html_strict) html = "
    \n\t\ntest 123\n\t\n
    " result = "
    test 123
    " assert_equal(result, html.html2html_strict) html = "
    " result = "
    " assert_equal(result, html.html2html_strict) html = "

    " result = "
     
    " assert_equal(result, html.html2html_strict) html = "

    " result = "

     

    " assert_equal(result, html.html2html_strict) html = "
    " result = "
     
    " assert_equal(result, html.html2html_strict) html = "
    " result = "
     
    " assert_equal(result, html.html2html_strict) html = "


    " result = "
     
    " assert_equal(result, html.html2html_strict) html = '

    Description



    ' result = '

    Description



    ' assert_equal(result, html.html2html_strict) html = '

    Description




    ' result = '

    Description



    ' assert_equal(result, html.html2html_strict) html = '

     



     

    ' result = '

     

     

    ' assert_equal(result, html.html2html_strict) html = "
    a\nb\nc
    " result = "
    a\nb\nc
    " assert_equal(result, html.html2html_strict) html = "
    a\nb\nc
    " result = "
    a\nb\nc
    " assert_equal(result, html.html2html_strict) html = '

    Guten Morgen, Frau Koppenhagen,

     

    vielen Dank für die Reservierung. Dabei allerdings die Sprache (Niederländisch) nicht erwähnt. Können Sie bitte dieses in Ihrer Reservierung vormerken?

     

    Nochmals vielen Dank und herzliche Grüße

    ' result = '

    Guten Morgen, Frau Koppenhagen,

     

    vielen Dank für die Reservierung. Dabei allerdings die Sprache (Niederländisch) nicht erwähnt. Können Sie bitte dieses in Ihrer Reservierung vormerken?

     

    Nochmals vielen Dank und herzliche Grüße

    ' assert_equal(result, html.html2html_strict) html = 'http://example.com' result = 'http://example.com' assert_equal(result, html.html2html_strict) html = 'http://example.com?a=1;' result = 'http://example.com?a=1;' assert_equal(result, html.html2html_strict) html = 'http://example.com/withSoMeUpper/And/downCase' result = 'http://example.com/withSoMeUpper/And/downCase' assert_equal(result, html.html2html_strict) html = 'web.de' result = 'web.de' assert_equal(result, html.html2html_strict) html = 'web.de' result = 'web.de' assert_equal(result, html.html2html_strict) html = '
    https://www.facebook.com/test
    ' result = '' assert_equal(result, html.html2html_strict) html = '

    https://www.facebook.com/test
    ' result = '' assert_equal(result, html.html2html_strict) html = 'some text http://example.com some other text' result = 'some text http://example.com some other text' assert_equal(result, html.html2html_strict) html = 'some text www.example.com some other text' result = 'some text www.example.com some other text' assert_equal(result, html.html2html_strict) html = 'http://what-different.example.com' result = "http://what-different.example.com" assert_equal(result, html.html2html_strict) html = 'http://what-different.example.com' result = "http://what-different.example.com" assert_equal(result, html.html2html_strict) html = 'http://EXAMPLE.com' result = 'http://EXAMPLE.com' assert_equal(result, html.html2html_strict) html = 'http://example.com' result = 'http://example.com' assert_equal(result, html.html2html_strict) html = 'http://example.com' result = 'http://example.com' assert_equal(result, html.html2html_strict) html = "http://example.com" result = 'http://example.com' assert_equal(result, html.html2html_strict) html = "http://example.com" result = 'http://example.com' assert_equal(result, html.html2html_strict) html = "http://example.com?abc=123&123=abc" result = 'http://example.com?abc=123&123=abc' assert_equal(result, html.html2html_strict) html = "http://example.com?abc=123&123=abc" result = 'http://example.com?abc=123&123=abc' assert_equal(result, html.html2html_strict) html = "" result = '' assert_equal(result, html.html2html_strict) html = '

    https://wiki.lab.example.com/doku.php?id=xxxx:start&#ldap

    ' result = '

    https://wiki.lab.example.com/doku.php?id=xxxx:start&#ldap

    ' assert_equal(result, html.html2html_strict) html = '

    https://wiki.lab.example.com/doku.php?id=xxxx:start&a=1;#ldap

    ' result = '

    https://wiki.lab.example.com/doku.php?id=xxxx:start&a=1;#ldap

    ' assert_equal(result, html.html2html_strict) html = "
    http://example.com
    " result = "" assert_equal(result, html.html2html_strict) html = "
    http://example.com.
    " result = "" assert_equal(result, html.html2html_strict) html = "
    lala http://example.com.
    " result = '' assert_equal(result, html.html2html_strict) html = "
    http://example.com, and so on
    " result = "
    \nhttp://example.com, and so on
    " assert_equal(result, html.html2html_strict) html = "
    http://example.com?lala=me, and so on
    " result = "" assert_equal(result, html.html2html_strict) html = "http://facebook.de/examplesrbog" result = "http://facebook.de/examplesrbog" assert_equal(result, html.html2html_strict) html = "web                        www.example.com" result = "web www.example.com" assert_equal(result, html.html2html_strict) html = "web www.example.com" result = "web www.example.com" assert_equal(result, html.html2html_strict) html = "Damit Sie keinen Tag versäumen, empfehlen wir Ihnen den Link des Adventkalenders in
          Ihrer Lesezeichen-Symbolleiste zu ergänzen.

     " result = "Damit Sie keinen Tag versäumen, empfehlen wir Ihnen den Link des Adventkalenders in
    Ihrer Lesezeichen-Symbolleiste zu ergänzen.
    " assert_equal(result, html.html2html_strict) html = 'Hello Mr Smith,' result = 'Hello Mr Smith,' assert_equal(result, html.html2html_strict) html = "
    abc

    Von: Fritz Bauer [mailto:me@example.com]
    Gesendet: Donnerstag, 3. Mai 2012 11:51
    An: John Smith
    Cc: Smith, John Marian; johnel.fratczak@example.com; ole.brei@example.com; Günther John | Example GmbH; bkopon@example.com; john.heisterhagen@team.example.com; sven.rocked@example.com; michael.house@example.com; tgutzeit@example.com
    Betreff: Re: OTRS::XXX Erweiterung - Anhänge an CI's

    " result = "
    abc

    Von: Fritz Bauer [mailto:me@example.com]
    Gesendet: Donnerstag, 3. Mai 2012 11:51
    An: John Smith
    Cc: Smith, John Marian; johnel.fratczak@example.com; ole.brei@example.com; Günther John | Example GmbH; bkopon@example.com; john.heisterhagen@team.example.com; sven.rocked@example.com; michael.house@example.com; tgutzeit@example.com
    Betreff: Re: OTRS::XXX Erweiterung - Anhänge an CI's

    " assert_equal(result, html.html2html_strict) html = "
    abc

    Von: Fritz Bauer [mailto:me@example.com]
    Gesendet: Donnerstag, 3. Mai 2012 11:51
    An: John Smith
    Cc: Smith, John Marian; johnel.fratczak@example.com; ole.brei@example.com; Günther John | Example GmbH; bkopon@example.com; john.heisterhagen@team.example.com; sven.rocked@example.com; michael.house@example.com; tgutzeit@example.com
    Betreff: Re: OTRS::XXX Erweiterung - Anhänge an CI's

    " result = "
    abc

    Von: Fritz Bauer [mailto:me@example.com]
    Gesendet: Donnerstag, 3. Mai 2012 11:51
    An: John Smith
    Cc: Smith, John Marian; johnel.fratczak@example.com; ole.brei@example.com; Günther John | Example GmbH; bkopon@example.com; john.heisterhagen@team.example.com; sven.rocked@example.com; michael.house@example.com; tgutzeit@example.com
    Betreff: Re: OTRS::XXX Erweiterung - Anhänge an CI's

    " assert_equal(result, html.html2html_strict) html = "
    abc

    Von: Fritz Bauer [mailto:me@example.com]
    Gesendet: Donnerstag, 3. Mai 2012 11:51
    An: John Smith
    Cc: Smith, John Marian; johnel.fratczak@example.com; ole.brei@example.com; Günther John | Example GmbH; bkopon@example.com; john.heisterhagen@team.example.com; sven.rocked@example.com; michael.house@example.com; tgutzeit@example.com
    Betreff: Re: OTRS::XXX Erweiterung - Anhänge an CI's

    " result = "
    abc

    Von: Fritz Bauer [mailto:me@example.com]
    Gesendet: Donnerstag, 3. Mai 2012 11:51
    An: John Smith
    Cc: Smith, John Marian; johnel.fratczak@example.com; ole.brei@example.com; Günther John | Example GmbH; bkopon@example.com; john.heisterhagen@team.example.com; sven.rocked@example.com; michael.house@example.com; tgutzeit@example.com
    Betreff: Re: OTRS::XXX Erweiterung - Anhänge an CI's

    " assert_equal(result, html.html2html_strict) html = "
    Mit freundlichem Gruß 

    John Smith
    Service und Support

    Example Service AG & Co.
    Management OHG
    Someware-Str. 4
    xxxxx Someware

    Tel.: +49 001 7601 462
    Fax: +49 001 7601 472
    " result = "
    Mit freundlichem Gruß

    John Smith
    Service und Support

    Example Service AG & Co.
    Management OHG
    Someware-Str. 4
    xxxxx Someware

    Tel.: +49 001 7601 462
    Fax: +49 001 7601 472
    john.smith@example.com
    " assert_equal(result, html.html2html_strict) html = 'test' result = 'test' assert_equal(result, html.html2html_strict) html = 'test' result = 'test' assert_equal(result, html.html2html_strict) html = 'test< /b >' result = 'test< /b >' assert_equal(result, html.html2html_strict) html = "test<\n/b>" result = "test< /b>" assert_equal(result, html.html2html_strict) html = '
    Neues Fax
    Ihre Kundennummer: 12345678
    Franz Schäfer
    Manager Information Systems

    Telefon   +49 000 000 8565
    christian.schaefer@example.com

    ' result = "Franz Schäfer



    Telefon\n+49 000 000 8565
    \nchristian.schaefer@example.com


    " result = '
    Franz Schäfer
    Manager Information Systems

    Telefon +49 000 000 8565
    christian.schaefer@example.com
    ' assert_equal(result, html.html2html_strict) html = "test" result = 'test' assert_equal(result, html.html2html_strict) html = "test<\n/b>" result = "test< /b>" assert_equal(result, html.html2html_strict) html = "
    • test
    • \n
    • test
    • <\n/ul>" result = "
        \n
      • test
      • \n
      • test
      • < /ul>
      " assert_equal(result, html.html2html_strict) html = '
      Hello Martin,
      ' result = '
      Hello Martin,
      ' html.html2html_strict assert_equal(result, html.html2html_strict) html = '
      Hello Martin,
      ' result = '
      Hello Martin,
      ' assert_equal(result, html.html2html_strict) html = '
      Hello Martin,
      ' result = "
      \n
      Hello Martin,
      " assert_equal(result, html.html2html_strict) html = '' result = '' assert_equal(result, html.html2html_strict) html = '
      abc
      ' result = '
      abc
      ' assert_equal(result, html.html2html_strict) html = '

      abc
      ' result = '
      abc
      ' assert_equal(result, html.html2html_strict) html = '
      abc


      ' result = '
      abc
      ' assert_equal(result, html.html2html_strict) html = '



      ' result = '
       
      ' assert_equal(result, html.html2html_strict) html = '

      abc

      ' result = '

      abc

      ' assert_equal(result, html.html2html_strict) html = '

      ' result = '

       

      ' assert_equal(result, html.html2html_strict) html = '

      ' result = '

       

      ' assert_equal(result, html.html2html_strict) html = '

      ' result = '

      ' assert_equal(result, html.html2html_strict) html = '
      lala

      Hello Martin,

      ' result = "
      lala

      Hello Martin,

      " html.html2html_strict assert_equal(result, html.html2html_strict) html = '

      Hello Martin,

      ' result = '

      Hello Martin,

      ' assert_equal(result, html.html2html_strict) html = '

      Guten Morgen, Frau ABC,

       

      vielen Dank für die Reservierung. Dabei allerdings die Sprache (Niederländisch) nicht erwähnt. Können Sie bitte dieses in Ihrer Reservierung vormerken?

       

      Nochmals vielen Dank und herzliche Grüße

       

      Anna Smith

      art abc SEV GmbH

      art abc TRAV

      Marktstätte 123

      123456 Dorten

      T: +49 (0) 12345/1234560-1

      T: +49 (0) 12345/1234560-0

      F: +49 (0) 12345/1234560-2

      annad@example.com

      www.example.com          www.ABC.com

      Geschäftsführer Vor Nach, VorUndZu Nach     -     Amtsgericht Dort HRB 12345    -    Ein Unternehmer der ABC Gruppe

      ' result = "
      \n

      Guten Morgen, Frau ABC,

       

      vielen Dank für die Reservierung. Dabei allerdings die Sprache (Niederländisch) nicht erwähnt. Können Sie bitte dieses in Ihrer Reservierung vormerken?

       

      Nochmals vielen Dank und herzliche Grüße

       

      Anna Smith

      art abc SEV GmbH

      art abc TRAV

      Marktstätte 123

      123456 Dorten

      T: +49 (0) 12345/1234560-1

      T: +49 (0) 12345/1234560-0

      F: +49 (0) 12345/1234560-2

      annad@example.com

      www.example.com www.ABC.com

      Geschäftsführer Vor Nach, VorUndZu Nach - Amtsgericht Dort HRB 12345 - Ein Unternehmer der ABC Gruppe

      " assert_equal(result, html.html2html_strict) html = '

       

      Von: Besucherbüro, MKuk [mailto:besucherbuero@example.com]
      Gesendet: Freitag, 16. Dezember 2016 08:05
      An: \'Amaia Epalza\'
      Betreff: AW: Gruppe vtb Kultuur // 28.06.2017

       

      Reservierungsbestätigung Führung Skulptur-Projekte 2017 am

       

      Guten Morgen Frau Epalza,

      ' result = '

       

      Von: Besucherbüro, MKuk [besucherbuero@example.com]
      Gesendet: Freitag, 16. Dezember 2016 08:05
      An: \'Amaia Epalza\'
      Betreff: AW: Gruppe vtb Kultuur // 28.06.2017

       

      Reservierungsbestätigung Führung Skulptur-Projekte 2017 am

       

      Guten Morgen Frau Epalza,

      ' assert_equal(result, html.html2html_strict) html = '
      Hello Martin,
      ' result = '
      Hello Martin,
      ' assert_equal(result, html.html2html_strict) html = 'john.smith@example.com' result = 'john.smith@example.com' assert_equal(result, html.html2html_strict) html = 'john.smith@example.com' result = 'john.smith@example.com' assert_equal(result, html.html2html_strict) html = 'john.smith@example.com' #result = 'john.smith@example.com (mailto:john.smith2@example.com)' result = 'john.smith2@example.com' assert_equal(result, html.html2html_strict) html = '' result = '' assert_equal(result, html.html2html_strict) html = '' result = '' assert_equal(result, html.html2html_strict) html = '' result = '' assert_equal(result, html.html2html_strict) html = '

      ' result = '

      ' assert_equal(result, html.html2html_strict) html = '

      ' result = '

      ' assert_equal(result, html.html2html_strict) html = '

      ' result = '

      ' assert_equal(result, html.html2html_strict) html = '
      Wir brauchen also die Instanz example.zammad.com, kann die aber nicht mehr nutzen.

      Bitte um Freischaltung.


      ' result = '
      Wir brauchen also die Instanz example.zammad.com, kann die aber nicht mehr nutzen.
       
      Bitte um Freischaltung.
       
      ' assert_equal(result, html.html2html_strict) html = '

      oh jeee … Zauberwort vergessen ;-) Können Sie mir bitte noch meine Testphase verlängern?

       

      ' result = '

      oh jeee … Zauberwort vergessen ;-) Können Sie mir bitte noch meine Testphase verlängern?

       

      ' assert_equal(result, html.html2html_strict) html = '' result = '' assert_equal(result, html.html2html_strict) html = '

     

    20-29
    200
    -1
    201
    country
    Target (gross)
    Remaining Recruits
    Total Recruits

     

    20-29
    200 -1 201
    country
    Target (gross)
    Remaining Recruits
    Total Recruits