[Rt-commit] rt branch, 4.2-on-4.0/protect-more-chars-while-decoding-headers, updated. rt-4.0.12-23-gb498661

Alex Vandiver alexmv at bestpractical.com
Thu May 9 17:09:46 EDT 2013


The branch, 4.2-on-4.0/protect-more-chars-while-decoding-headers has been updated
       via  b498661b89c170f85b49f9901a3161c3192fe80d (commit)
      from  f428fe5e8f3dad991aca31a7e7c7ec25f9bc6049 (commit)

Summary of changes:
 sbin/rt-test-dependencies.in |  1 -
 t/mail/header-characters.t   | 60 ++++++++++++++++++--------------------------
 2 files changed, 24 insertions(+), 37 deletions(-)

- Log -----------------------------------------------------------------
commit b498661b89c170f85b49f9901a3161c3192fe80d
Author: Alex Vandiver <alexmv at bestpractical.com>
Date:   Thu May 9 17:09:07 2013 -0400

    Remove assumptions that we might have Email::Address < 1.897

diff --git a/sbin/rt-test-dependencies.in b/sbin/rt-test-dependencies.in
index 6961551..f5547be 100644
--- a/sbin/rt-test-dependencies.in
+++ b/sbin/rt-test-dependencies.in
@@ -370,7 +370,6 @@ HTML::Entities
 
 my %AVOID = (
     'DBD::Oracle' => [qw(1.23)],
-    'Email::Address' => [qw(1.893 1.894)],
     'Devel::StackTrace' => [qw(1.28 1.29)],
 );
 
diff --git a/t/mail/header-characters.t b/t/mail/header-characters.t
index 97fdd62..3e2638a 100644
--- a/t/mail/header-characters.t
+++ b/t/mail/header-characters.t
@@ -9,12 +9,7 @@ use Encode;
 my ($baseurl, $m) = RT::Test->started_ok;
 
 diag "Testing non-ASCII latin1 in From: header";
-SKIP:{
-    skip "Test requires Email::Address 1.893 or later, "
-      . "you have $Email::Address::VERSION", 3,
-      if $Email::Address::VERSION < 1.893;
-
-    my $mail = encode( 'iso-8859-1', <<'.' );
+my $mail = encode( 'iso-8859-1', <<'.' );
 From: <René@example.com>
 Reply-To: =?iso-8859-1?Q?Ren=E9?= <René@example.com>
 Subject: testing non-ASCII From
@@ -23,26 +18,20 @@ Content-Type: text/plain; charset=iso-8859-1
 here's some content
 .
 
-    my ($status, $id);
-    warnings_like { ( $status, $id ) = RT::Test->send_via_mailgate($mail) }
-        [(qr/Unable to parse an email address from/) x 2,
-         qr/Couldn't parse or find sender's address/
-        ],
-        'Got parse error for non-ASCII in From';
-    is( $status >> 8, 0, "The mail gateway exited normally" );
-    TODO: {
-          local $TODO = "Currently don't handle non-ASCII for sender";
-          ok( $id, "Created ticket" );
-      }
-}
+my ($status, $id);
+warnings_like { ( $status, $id ) = RT::Test->send_via_mailgate($mail) }
+    [(qr/Unable to parse an email address from/) x 2,
+     qr/Couldn't parse or find sender's address/
+    ],
+    'Got parse error for non-ASCII in From';
+is( $status >> 8, 0, "The mail gateway exited normally" );
+TODO: {
+      local $TODO = "Currently don't handle non-ASCII for sender";
+      ok( $id, "Created ticket" );
+  }
 
 diag "Testing non-ASCII latin1 in From: header with MIME-word-encoded phrase";
-SKIP:{
-    skip "Test requires Email::Address 1.893 or later, "
-      . "you have $Email::Address::VERSION", 3,
-      if $Email::Address::VERSION < 1.893;
-
-    my $mail = encode( 'iso-8859-1', <<'.' );
+my $mail = encode( 'iso-8859-1', <<'.' );
 From: =?iso-8859-1?Q?Ren=E9?= <René@example.com>
 Reply-To: =?iso-8859-1?Q?Ren=E9?= <René@example.com>
 Subject: testing non-ASCII From
@@ -51,18 +40,17 @@ Content-Type: text/plain; charset=iso-8859-1
 here's some content
 .
 
-    my ($status, $id);
-    warnings_like { ( $status, $id ) = RT::Test->send_via_mailgate($mail) }
-        [(qr/Unable to parse an email address from/) x 2,
-         qr/Couldn't parse or find sender's address/
-        ],
-        'Got parse error for iso-8859-1 in From';
-    is( $status >> 8, 0, "The mail gateway exited normally" );
-    TODO: {
-          local $TODO = "Currently don't handle non-ASCII in sender";
-          ok( $id, "Created ticket" );
-      }
-}
+my ($status, $id);
+warnings_like { ( $status, $id ) = RT::Test->send_via_mailgate($mail) }
+    [(qr/Unable to parse an email address from/) x 2,
+     qr/Couldn't parse or find sender's address/
+    ],
+    'Got parse error for iso-8859-1 in From';
+is( $status >> 8, 0, "The mail gateway exited normally" );
+TODO: {
+      local $TODO = "Currently don't handle non-ASCII in sender";
+      ok( $id, "Created ticket" );
+  }
 
 diag "No sender";
 {

-----------------------------------------------------------------------


More information about the Rt-commit mailing list