diff --git a/lib/regex.js b/lib/regex.js index f66234e..192f4e2 100644 --- a/lib/regex.js +++ b/lib/regex.js @@ -52,6 +52,7 @@ class RegexList { // DE /^Von (?:\s*.+) gesendet$/, // de + /^Gesendet von (?:\s*.+) für (?:\s*.+)$/, // de // DA /^Sendt fra (?:\s*.+)$/, // da diff --git a/test/fixtures/email_german_3.txt b/test/fixtures/email_german_3.txt new file mode 100644 index 0000000..97b505c --- /dev/null +++ b/test/fixtures/email_german_3.txt @@ -0,0 +1,9 @@ +Fusce bibendum, quam hendrerit sagittis tempor, dui turpis tempus erat, pharetra sodales ante sem sit amet metus. +Nulla malesuada, orci non vulputate lobortis, massa felis pharetra ex, convallis consectetur ex libero eget ante. +Nam vel turpis posuere, rhoncus ligula in, venenatis orci. Duis interdum venenatis ex a rutrum. +Duis ut libero eu lectus consequat consequat ut vel lorem. Vestibulum convallis lectus urna, +et mollis ligula rutrum quis. Fusce sed odio id arcu varius aliquet nec nec nibh. + +Gesendet von Outlook für Android + +Hi there! diff --git a/test/test.js b/test/test.js index 51d604e..259d745 100644 --- a/test/test.js +++ b/test/test.js @@ -273,6 +273,16 @@ exports.test_email_german_2 = function(test) { test.done(); }; +exports.test_email_german_3 = function(test) { + let email = get_email("email_german_3"); + + let fragments = email.getFragments(); + + test.equal(COMMON_FIRST_FRAGMENT, fragments[0].toString().trim()); + + test.done(); +}; + exports.test_email_gmail_no = function(test) { let email = get_email("email_norwegian_gmail");