From 0f74db6fb0ae5a4fcdfaaf1976d196efc01ab0b0 Mon Sep 17 00:00:00 2001 From: Mark Sapiro Date: Fri, 31 Jul 2009 13:27:06 -0700 Subject: Added recognition for more bounces. --- tests/bounces/aol_01.txt | 19 +++++++++++++++++++ tests/bounces/simple_37.txt | 36 ++++++++++++++++++++++++++++++++++++ tests/test_bounces.py | 2 ++ 3 files changed, 57 insertions(+) create mode 100644 tests/bounces/aol_01.txt create mode 100644 tests/bounces/simple_37.txt (limited to 'tests') diff --git a/tests/bounces/aol_01.txt b/tests/bounces/aol_01.txt new file mode 100644 index 00000000..2abf0975 --- /dev/null +++ b/tests/bounces/aol_01.txt @@ -0,0 +1,19 @@ +X-MimeOLE: Produced By Microsoft Exchange V6.5 +Content-class: urn:content-classes:message +MIME-Version: 1.0 +Content-Type: text/plain; + charset="iso-8859-1" +Content-Transfer-Encoding: quoted-printable +Subject: Mail Delivery Problem +Date: Fri, 17 Jul 2009 16:05:21 -0700 +Message-ID: <200907171908.7d834a6104831b4@omr-d25.mx.aol.com> +X-MS-Has-Attach: +X-MS-TNEF-Correlator: +From: "Mail Delivery Subsystem" +To: + + +Your mail to the following recipients could not be delivered because = +they are not accepting mail from xxx@lists.xxx.com: + screenname + diff --git a/tests/bounces/simple_37.txt b/tests/bounces/simple_37.txt new file mode 100644 index 00000000..50cb0b28 --- /dev/null +++ b/tests/bounces/simple_37.txt @@ -0,0 +1,36 @@ +X-MimeOLE: Produced By Microsoft Exchange V6.5 +Content-class: urn:content-classes:message +MIME-Version: 1.0 +Content-Type: text/plain; + charset="iso-8859-1" +Content-Transfer-Encoding: quoted-printable +Subject: Returned mail - nameserver error report +Date: Fri, 17 Jul 2009 16:05:22 -0700 +Message-ID: <200907172305.n6HN5Mn23080@mta1.service.uci.edu> +X-MS-Has-Attach: +X-MS-TNEF-Correlator: +From: +To: + + --------Message not delivered to the following addresses: + + user@uci.edu=20 + + --------Error Detail (phquery V3.0): + +---- user@uci.edu=20 + Does not have a final email delivery point, + please contact this person by alternate means. +=20 + name: User Name + alias: USER + +Please contact Postmaster@uci.edu if you have any questions. + + --------Unsent Message below: + +Received: from mx2.service.uci.edu (mx2.service.uci.edu = +[128.200.59.180]) + by mta1.service.uci.edu (8.11.4-20030923/8.11.2) with ESMTP id = +n6HN5Mi23070; + Fri, 17 Jul 2009 16:05:22 -0700 (PDT) diff --git a/tests/test_bounces.py b/tests/test_bounces.py index 7986c7d4..9a4cba4d 100644 --- a/tests/test_bounces.py +++ b/tests/test_bounces.py @@ -73,6 +73,7 @@ class BounceTest(unittest.TestCase): ('SimpleMatch', 'simple_33.txt', ['hmu@extralumin.com']), ('SimpleMatch', 'simple_34.txt', ['roland@xxx.com']), ('SimpleMatch', 'simple_36.txt', ['garyt@xxx.com']), + ('SimpleMatch', 'simple_37.txt', ['user@uci.edu']), ('SimpleMatch', 'bounce_02.txt', ['acinsp1@midsouth.rr.com']), ('SimpleMatch', 'bounce_03.txt', ['james@jeborall.demon.co.uk']), # SimpleWarning @@ -163,6 +164,7 @@ class BounceTest(unittest.TestCase): 'turtle4jne@yahoo.com']), # sina.com appears to use their own weird SINAEMAIL MTA ('Sina', 'sina_01.txt', ['boboman76@sina.com', 'alan_t18@sina.com']), + ('AOL', 'aol_01.txt', ['screenname@aol.com']), # No address can be detected in these... # dumbass_01.txt - We love Microsoft. :( # Done -- cgit v1.2.3