r2863 - in /packages/libemail-valid-perl/trunk: Changes MANIFEST META.yml Makefile.PL Valid.pm debian/changelog debian/control lib/ t/valid.t

gregoa-guest at users.alioth.debian.org gregoa-guest at users.alioth.debian.org
Sun Jun 4 21:15:04 UTC 2006


Author: gregoa-guest
Date: Sun Jun  4 21:14:58 2006
New Revision: 2863

URL: http://svn.debian.org/wsvn/pkg-perl/?sc=1&rev=2863
Log:
* New upstream release.
* Standards-Version set to 3.7.2.0 (no changes).
* Changed the tests (again) to work without a network connection.

Added:
    packages/libemail-valid-perl/trunk/META.yml
      - copied unchanged from r2862, packages/libemail-valid-perl/branches/upstream/current/META.yml
    packages/libemail-valid-perl/trunk/lib/
      - copied from r2862, packages/libemail-valid-perl/branches/upstream/current/lib/
Removed:
    packages/libemail-valid-perl/trunk/Valid.pm
Modified:
    packages/libemail-valid-perl/trunk/Changes
    packages/libemail-valid-perl/trunk/MANIFEST
    packages/libemail-valid-perl/trunk/Makefile.PL
    packages/libemail-valid-perl/trunk/debian/changelog
    packages/libemail-valid-perl/trunk/debian/control
    packages/libemail-valid-perl/trunk/t/valid.t

Modified: packages/libemail-valid-perl/trunk/Changes
URL: http://svn.debian.org/wsvn/pkg-perl/packages/libemail-valid-perl/trunk/Changes?rev=2863&op=diff
==============================================================================
--- packages/libemail-valid-perl/trunk/Changes (original)
+++ packages/libemail-valid-perl/trunk/Changes Sun Jun  4 21:14:58 2006
@@ -1,4 +1,10 @@
 Revision history for Perl extension Email::Valid.
+
+0.16 Fri Jun  2
+        - maintainership assumed by RJBS
+        - work with current, broken Net::Domain::TLD
+        - improve tests
+
 
 0.15 Sun Sep  7 21:39:12 PDT 2003
         - Support for top level domain validity check added by Elizabeth

Modified: packages/libemail-valid-perl/trunk/MANIFEST
URL: http://svn.debian.org/wsvn/pkg-perl/packages/libemail-valid-perl/trunk/MANIFEST?rev=2863&op=diff
==============================================================================
--- packages/libemail-valid-perl/trunk/MANIFEST (original)
+++ packages/libemail-valid-perl/trunk/MANIFEST Sun Jun  4 21:14:58 2006
@@ -1,6 +1,7 @@
 Changes
-Valid.pm
+lib/Email/Valid.pm
 README
 MANIFEST
 Makefile.PL
 t/valid.t
+META.yml                                 Module meta-data (added by MakeMaker)

Modified: packages/libemail-valid-perl/trunk/Makefile.PL
URL: http://svn.debian.org/wsvn/pkg-perl/packages/libemail-valid-perl/trunk/Makefile.PL?rev=2863&op=diff
==============================================================================
--- packages/libemail-valid-perl/trunk/Makefile.PL (original)
+++ packages/libemail-valid-perl/trunk/Makefile.PL Sun Jun  4 21:14:58 2006
@@ -2,7 +2,7 @@
 
 WriteMakefile(
     'NAME'	   => 'Email::Valid',
-    'VERSION_FROM' => 'Valid.pm', 
+    'VERSION_FROM' => 'lib/Email/Valid.pm', 
     'PREREQ_PM'    => { 'Mail::Address' => 0 },
     'dist'         => { 'COMPRESS'=>'gzip -9f', 'SUFFIX' => 'gz',
                         'ZIP'=>'/usr/bin/zip', 'ZIPFLAGS'=>'-rl' }

Modified: packages/libemail-valid-perl/trunk/debian/changelog
URL: http://svn.debian.org/wsvn/pkg-perl/packages/libemail-valid-perl/trunk/debian/changelog?rev=2863&op=diff
==============================================================================
--- packages/libemail-valid-perl/trunk/debian/changelog (original)
+++ packages/libemail-valid-perl/trunk/debian/changelog Sun Jun  4 21:14:58 2006
@@ -1,3 +1,11 @@
+libemail-valid-perl (0.16-1) unstable; urgency=low
+
+  * New upstream release.
+  * Standards-Version set to 3.7.2.0 (no changes).
+  * Changed the tests (again) to work without a network connection.
+
+ -- gregor herrmann <gregor+debian at comodo.priv.at>  Sun,  4 Jun 2006 23:07:39 +0200
+
 libemail-valid-perl (0.15-5) unstable; urgency=low
 
   * Set the maintainer field to the DPG.

Modified: packages/libemail-valid-perl/trunk/debian/control
URL: http://svn.debian.org/wsvn/pkg-perl/packages/libemail-valid-perl/trunk/debian/control?rev=2863&op=diff
==============================================================================
--- packages/libemail-valid-perl/trunk/debian/control (original)
+++ packages/libemail-valid-perl/trunk/debian/control Sun Jun  4 21:14:58 2006
@@ -4,7 +4,7 @@
 Build-Depends: debhelper (>=5.0.0)
 Build-Depends-Indep: perl (>=5.6.0-16), libmailtools-perl, libnet-dns-perl, libnet-domain-tld-perl (>= 1.65-2), netbase
 Maintainer: Debian Perl Group <pkg-perl-maintainers at lists.alioth.debian.org>
-Standards-Version: 3.7.0.0
+Standards-Version: 3.7.2.0
 Uploaders: Ron Lee <ron at debian.org>, Gunnar Wolf <gwolf at debian.org>, gregor herrmann <gregor+debian at comodo.priv.at>
 
 Package: libemail-valid-perl

Modified: packages/libemail-valid-perl/trunk/t/valid.t
URL: http://svn.debian.org/wsvn/pkg-perl/packages/libemail-valid-perl/trunk/t/valid.t?rev=2863&op=diff
==============================================================================
--- packages/libemail-valid-perl/trunk/t/valid.t (original)
+++ packages/libemail-valid-perl/trunk/t/valid.t Sun Jun  4 21:14:58 2006
@@ -1,69 +1,78 @@
-# Before `make install' is performed this script should be runnable with
-# `make test'. After `make install' it should work as `perl test.pl'
+#!perl
+use strict;
 
-######################### We start with some black magic to print on failure.
+use Test::More tests => 12;
 
-# Change 1..1 below to 1..last_test_to_print .
-# (It may become useful if the test is moved to ./t subdirectory.)
+BEGIN {
+  use_ok('Email::Valid');
+}
 
-BEGIN { $| = 1; print "1..12\n"; }
-END {print "not ok 1\n" unless $loaded;}
-use Email::Valid;
-$loaded = 1;
-print "ok 1\n";
+my $v = Email::Valid->new;
 
-######################### End of black magic.
+ok(
+  ! $v->address('Alfred Neuman <Neuman at BBN-TENEXA>'),
+  'Alfred Neuman <Neuman at BBN-TENEXA>',
+);
 
-# Insert your test code below (better if it prints "ok 13"
-# (correspondingly "not ok 13") depending on the success of chunk 13
-# of the test code):
+ok(
+  $v->address( -address => 'Alfred Neuman <Neuman at BBN-TENEXA>', -fqdn    => 0),
+  'Alfred Neuman <Neuman at BBN-TENEXA> { -fqdn => 0 }',
+);
 
-$test = 2;
-my $v = new Email::Valid;
+is(
+  $v->address( -address => 'first last at aol.com', -fudge   => 1),
+  'firstlast at aol.com',
+  "spaces fudged out of an address local-part",
+);
 
-sub not_ok { print "not ok $test\n"; $test++ }
-sub ok { print "ok $test\n"; $test++ }
-sub skipnet { print "ok $test # skip Network nameserver not available\n";
-              $test++ }
-sub skiptld { print "ok $test # skip Net::Domain::TLD not available\n";
-              $test++ }
+ok(
+  ! $v->address( -address => 'first last at aol.com', -fudge   => 0),
+  "spaces in localpart is not valid when not fudging",
+);
 
-$v->address('Alfred Neuman <Neuman at BBN-TENEXA>') ? not_ok : ok;
+is($v->details, 'rfc822', "details are rfc822");
 
-$v->address( -address => 'Alfred Neuman <Neuman at BBN-TENEXA>',
-             -fqdn    => 0) ? ok : not_ok;
+is(
+  $v->address('foo @ foo.com'),
+  'foo at foo.com',
+  "spaced out address is squished"
+);
+ 
+is(
+  $v->address(q{fred&barney at stonehenge(yup, the rock place).(that's dot)com}),
+  'fred&barney at stonehenge.com',
+  "comments nicely dropped from an address",
+);
 
-my $a = $v->address( -address => 'first last at aol.com',
-                     -fudge   => 1);
-$a eq 'firstlast at aol.com' ? ok : not_ok;
+SKIP: {
+  skip "Net::DNS not available or network down", 2
+    unless eval { require Net::DNS; 1; } && Net::DNS::mx('debian.org');
+    
+#  skip "your dns appears missing or failing to resolve", 2
+#    unless $v->address(-address=> 'devnull at pobox.com', -mxcheck => 1);
 
-$v->address( -address => 'first last at aol.com',
-             -fudge   => 0) ? not_ok : ok;
-$v->details eq 'rfc822' ? ok : not_ok;
+  ok(
+    $v->address(-address => 'blort at aol.com', -mxcheck => 1),
+    'blort at aol.com, with mxcheck, is ok',
+  );
 
-$a = $v->address('foo @ foo.com');
-$a eq 'foo at foo.com' ? ok : not_ok;
- 
-$a = $v->address("fred&barney\@stonehenge(yup, the rock place).(that's dot)com");
-$a eq 'fred&barney at stonehenge.com' ? ok : not_ok;   
+  ok(
+    !$v->address(-address => 'blort at will-never-exist.pobox.com', -mxcheck => 1),
+    'blort at will-never-exist.pobox.com, with mxcheck, is invalid',
+  );
+}
 
-eval {require Net::DNS};
-if( !$@ && Net::DNS::mx('debian.org') )
-{
-    $v->address( -address => 'blort at debian.org',
-                 -mxcheck => 1) ? ok : not_ok;
-    $v->address( -address => 'blort at notarealdomainfoo.com',
-                 -mxcheck => 1) ? not_ok : ok;   
+SKIP: {
+  skip "tests require Net::Domain::TLD", 2
+    unless eval { require Net::Domain::TLD; 1; };
 
-    eval {require Net::Domain::TLD};
-    if ($@) {
-        skiptld; skiptld;
-    } else {
-        $v->address( -address => 'blort at notarealdomainfoo.com',
-                     -tldcheck => 1) ? ok : not_ok;   
-        $v->address( -address => 'blort at notarealdomainfoo.bla',
-                     -tldcheck => 1) ? not_ok : ok;   
-    }
-} else {
-    skipnet; skipnet; skipnet; skipnet;
+  ok(
+    $v->address( -address => 'blort at notarealdomainfoo.com', -tldcheck => 1),
+    'blort at notarealdomainfoo.com is ok with tldcheck',
+  );
+
+  ok(
+    ! $v->address( -address => 'blort at notarealdomainfoo.bla', -tldcheck => 1),
+    'blort at notarealdomainfoo.bla is not ok with tldcheck',
+  );
 }




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