r28151 - in /trunk/libemail-abstract-perl: Changes META.yml Makefile.PL debian/changelog debian/control debian/copyright lib/Email/Abstract.pm lib/Email/Abstract/Plugin.pm t/abstractions.t

rmayorga-guest at users.alioth.debian.org rmayorga-guest at users.alioth.debian.org
Sat Dec 13 01:35:51 UTC 2008


Author: rmayorga-guest
Date: Sat Dec 13 01:35:41 2008
New Revision: 28151

URL: http://svn.debian.org/wsvn/pkg-perl/?sc=1&rev=28151
Log:
* New upstream release
* debian/copyrigth - use changelog info to declare a more clear 
  debian/* copyright stanza
* add myself to uploaders

Modified:
    trunk/libemail-abstract-perl/Changes
    trunk/libemail-abstract-perl/META.yml
    trunk/libemail-abstract-perl/Makefile.PL
    trunk/libemail-abstract-perl/debian/changelog
    trunk/libemail-abstract-perl/debian/control
    trunk/libemail-abstract-perl/debian/copyright
    trunk/libemail-abstract-perl/lib/Email/Abstract.pm
    trunk/libemail-abstract-perl/lib/Email/Abstract/Plugin.pm
    trunk/libemail-abstract-perl/t/abstractions.t

Modified: trunk/libemail-abstract-perl/Changes
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libemail-abstract-perl/Changes?rev=28151&op=diff
==============================================================================
--- trunk/libemail-abstract-perl/Changes (original)
+++ trunk/libemail-abstract-perl/Changes Sat Dec 13 01:35:41 2008
@@ -1,4 +1,10 @@
 Revision history for Email-Abstract.
+
+3.001     2008-12-11
+          declare our prereq on Scalar::Util
+
+3.000     2008-12-09
+          accept scalar references for more efficient msg-from-string
 
 2.134     2007-11-16
           (no code changes from previous dev release)

Modified: trunk/libemail-abstract-perl/META.yml
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libemail-abstract-perl/META.yml?rev=28151&op=diff
==============================================================================
--- trunk/libemail-abstract-perl/META.yml (original)
+++ trunk/libemail-abstract-perl/META.yml Sat Dec 13 01:35:41 2008
@@ -1,15 +1,23 @@
 --- #YAML:1.0
-name:                Email-Abstract
-version:             2.134
-abstract:            ~
-license:             perl
-generated_by:        ExtUtils::MakeMaker version 6.36_01
-distribution_type:   module
-requires:     
-    Class::ISA:                    0.20
-    Email::Simple:                 1.91
-    Module::Pluggable:             1.5
-    Test::More:                    0.47
+name:               Email-Abstract
+version:            3.001
+abstract:           ~
+author:  []
+license:            perl
+distribution_type:  module
+configure_requires:
+    ExtUtils::MakeMaker:  0
+requires:
+    Class::ISA:         0.20
+    Email::Simple:      1.91
+    Module::Pluggable:  1.5
+    Scalar::Util:       0
+    Test::More:         0.47
+no_index:
+    directory:
+        - t
+        - inc
+generated_by:       ExtUtils::MakeMaker version 6.48
 meta-spec:
-    url:     http://module-build.sourceforge.net/META-spec-v1.2.html
-    version: 1.2
+    url:      http://module-build.sourceforge.net/META-spec-v1.4.html
+    version:  1.4

Modified: trunk/libemail-abstract-perl/Makefile.PL
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libemail-abstract-perl/Makefile.PL?rev=28151&op=diff
==============================================================================
--- trunk/libemail-abstract-perl/Makefile.PL (original)
+++ trunk/libemail-abstract-perl/Makefile.PL Sat Dec 13 01:35:41 2008
@@ -1,4 +1,6 @@
+require 5.006;
 use strict;
+use warnings;
 use ExtUtils::MakeMaker;
 
 WriteMakefile(
@@ -10,5 +12,6 @@
     'Email::Simple'     => '1.91', # avoid undef body
     'Module::Pluggable' => '1.5',
     'Test::More'        => '0.47',
+    'Scalar::Util'      => 0,      # minimum unknown
   },
 );

Modified: trunk/libemail-abstract-perl/debian/changelog
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libemail-abstract-perl/debian/changelog?rev=28151&op=diff
==============================================================================
--- trunk/libemail-abstract-perl/debian/changelog (original)
+++ trunk/libemail-abstract-perl/debian/changelog Sat Dec 13 01:35:41 2008
@@ -1,9 +1,16 @@
-libemail-abstract-perl (2.134-4) UNRELEASED; urgency=low
+libemail-abstract-perl (3.001-1) unstable; urgency=low
 
-  * debian/control: Changed: Switched Vcs-Browser field to ViewSVN
+  [ gregor herrmann ]
+   * debian/control: Changed: Switched Vcs-Browser field to ViewSVN
     (source stanza).
+  
+  [ Rene mayorga ]
+  * New upstream release
+  * debian/copyrigth - use changelog info to declare a more clear 
+    debian/* copyright stanza
+  * add myself to uploaders
 
- -- gregor herrmann <gregoa at debian.org>  Sun, 16 Nov 2008 20:42:15 +0100
+ -- Rene Mayorga <rmayorga at debian.org.sv>  Fri, 12 Dec 2008 19:27:26 -0600
 
 libemail-abstract-perl (2.134-3) unstable; urgency=low
 

Modified: trunk/libemail-abstract-perl/debian/control
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libemail-abstract-perl/debian/control?rev=28151&op=diff
==============================================================================
--- trunk/libemail-abstract-perl/debian/control (original)
+++ trunk/libemail-abstract-perl/debian/control Sat Dec 13 01:35:41 2008
@@ -3,7 +3,8 @@
 Priority: optional
 Maintainer: Debian Perl Group <pkg-perl-maintainers at lists.alioth.debian.org>
 Uploaders: gregor herrmann <gregoa at debian.org>, Niko Tyni <ntyni at iki.fi>,
- Carlo Segre <segre at debian.org>, David Bremner <bremner at unb.ca>
+ Carlo Segre <segre at debian.org>, David Bremner <bremner at unb.ca>,
+ Rene Mayorga <rmayorga at debian.org.sv>
 Build-Depends: debhelper (>= 7), quilt
 Build-Depends-Indep: perl (>= 5.6.0-16), perl-modules,
  libmodule-pluggable-perl, libemail-simple-perl, libemail-mime-perl,

Modified: trunk/libemail-abstract-perl/debian/copyright
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libemail-abstract-perl/debian/copyright?rev=28151&op=diff
==============================================================================
--- trunk/libemail-abstract-perl/debian/copyright (original)
+++ trunk/libemail-abstract-perl/debian/copyright Sat Dec 13 01:35:41 2008
@@ -12,7 +12,9 @@
 Files: debian/*
 Copyright:
  2004-2005, S. Zachariah Sprackett <zac at sprackett.com>
- 2006-2008, various members of the Debian Perl Group, cf. debian/changelog
+ 2006-2008 gregor herrmann  <gregoa at debian.org>
+ 2006-2008 Niko Tyni <ntyni at iki.fi
+ 2008 David Bremner <bremner at unb.ca>
 License: Artistic | GPL-1+
 
 License: Artistic

Modified: trunk/libemail-abstract-perl/lib/Email/Abstract.pm
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libemail-abstract-perl/lib/Email/Abstract.pm?rev=28151&op=diff
==============================================================================
--- trunk/libemail-abstract-perl/lib/Email/Abstract.pm (original)
+++ trunk/libemail-abstract-perl/lib/Email/Abstract.pm Sat Dec 13 01:35:41 2008
@@ -1,14 +1,16 @@
+require 5.006;
+use warnings;
+use strict;
 package Email::Abstract;
 use Carp;
 use Email::Simple;
-# use 5.006;
-# use warnings;
-use strict;
-$Email::Abstract::VERSION = '2.134';
+$Email::Abstract::VERSION = '3.001';
 use Module::Pluggable
   search_path => [__PACKAGE__],
   except      => 'Email::Abstract::Plugin',
   require     => 1;
+
+use Scalar::Util ();
 
 my @plugins = __PACKAGE__->plugins(); # Requires them.
 my %adapter_for =
@@ -30,7 +32,8 @@
 
   return $foreign if eval { $foreign->isa($class) };
 
-  $foreign = Email::Simple->new($foreign) unless ref $foreign;
+  $foreign = Email::Simple->new($foreign)
+    unless Scalar::Util::blessed($foreign);
 
   my $adapter = $class->__class_for($foreign); # dies if none available
   return bless [ $foreign, $adapter ] => $class;
@@ -41,7 +44,7 @@
   $method ||= 'handle';
 
   my $f_class = ref $foreign;
-     $f_class = $foreign unless $f_class;;
+     $f_class = $foreign unless $f_class;
 
   return $f_class if ref $foreign and $f_class->isa($self);
 
@@ -64,7 +67,9 @@
     return ($self->[1], $thing, @_);
   } else {
     my $thing   = shift;
-    my $adapter = $self->__class_for(ref $thing ? $thing : 'Email::Simple');
+    my $adapter = $self->__class_for(
+      Scalar::Util::blessed($thing) ? $thing : 'Email::Simple'
+    );
     return ($adapter, $thing, @_);
   }
 }
@@ -81,9 +86,11 @@
 
     # I suppose we could work around this by leaving @_ intact and assigning to
     # it.  That seems ... not good. -- rjbs, 2007-07-18
-    unless (ref $thing) {
+    unless (Scalar::Util::blessed($thing)) {
       Carp::croak "can't alter string in place" if substr($func, 0, 3) eq 'set';
-      $thing = Email::Simple->new($thing);
+      $thing = Email::Simple->new(
+        ref $thing ? \do{my$str=$$thing} : $thing
+      );
     }
 
     return $adapter->$func($thing, @args);

Modified: trunk/libemail-abstract-perl/lib/Email/Abstract/Plugin.pm
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libemail-abstract-perl/lib/Email/Abstract/Plugin.pm?rev=28151&op=diff
==============================================================================
--- trunk/libemail-abstract-perl/lib/Email/Abstract/Plugin.pm (original)
+++ trunk/libemail-abstract-perl/lib/Email/Abstract/Plugin.pm Sat Dec 13 01:35:41 2008
@@ -2,7 +2,7 @@
 
 package Email::Abstract::Plugin;
 
-$Email::Abstract::Plugin::VERSION = '2.134';
+$Email::Abstract::Plugin::VERSION = '3.000';
 
 =head1 NAME
 

Modified: trunk/libemail-abstract-perl/t/abstractions.t
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libemail-abstract-perl/t/abstractions.t?rev=28151&op=diff
==============================================================================
--- trunk/libemail-abstract-perl/t/abstractions.t (original)
+++ trunk/libemail-abstract-perl/t/abstractions.t Sat Dec 13 01:35:41 2008
@@ -10,9 +10,9 @@
   = qw(Email::MIME Email::Simple MIME::Entity Mail::Internet Mail::Message);
 
 plan tests => 2
-            + (@classes * 2 + 1) * Test::EmailAbstract->tests_per_object
-            + (@classes + 2) * Test::EmailAbstract->tests_per_class
-            + 1;
+            + (@classes * 2 + 2) * Test::EmailAbstract->tests_per_object
+            + (@classes + 4) * Test::EmailAbstract->tests_per_class
+            + 2;
 
 use_ok("Email::Abstract");
 
@@ -56,24 +56,31 @@
   }
 }
 
-{
-  my $email_abs = Email::Abstract->new($message);
-  $tester->object_ok('plaintext',        $email_abs, 0);
-  $tester->class_ok('plaintext (class)', $message,   1);
+for my $ref (0..1) {
+  my $get_msg = $ref
+              ? sub { my $copy = $message; \$copy }
+              : sub { $message };
+  my $desc = 'plaintext' . ($ref ? ' (ref)' : '');
+
+  {
+    my $email_abs = Email::Abstract->new($get_msg->());
+    $tester->object_ok($desc,          $email_abs,   0);
+    $tester->class_ok("$desc (class)", $get_msg->(), 1);
+  }
+
+  {
+    my $email_abs = Email::Abstract->new($get_msg->());
+    $tester->class_ok('Email::Abstract', $email_abs,   0);
+  }
+
+  {
+    # Ensure that we can use Email::Abstract->header($abstract, 'foo')
+    my $email_abs = Email::Abstract->new($get_msg->());
+
+    my $email_abs_new = Email::Abstract->new($email_abs);
+    ok(
+      $email_abs == $email_abs_new,
+      "trying to wrap a wrapper returns the wrapper; it doesn't re-wrap",
+    );
+  }
 }
-
-{
-  my $email_abs = Email::Abstract->new($message);
-  $tester->class_ok('Email::Abstract', $email_abs,   0);
-}
-
-{
-  # Ensure that we can use Email::Abstract->header($abstract, 'foo')
-  my $email_abs = Email::Abstract->new($message);
-
-  my $email_abs_new = Email::Abstract->new($email_abs);
-  ok(
-    $email_abs == $email_abs_new,
-    "trying to wrap a wrapper returns the wrapper; it doesn't re-wrap",
-  );
-}




More information about the Pkg-perl-cvs-commits mailing list