r72887 - in /branches/upstream/libmoosex-strictconstructor-perl/current: ./ lib/MooseX/ lib/MooseX/StrictConstructor/Role/ lib/MooseX/StrictConstructor/Trait/ lib/MooseX/StrictConstructor/Trait/Method/ t/

ghedo-guest at users.alioth.debian.org ghedo-guest at users.alioth.debian.org
Wed Apr 20 19:56:41 UTC 2011


Author: ghedo-guest
Date: Wed Apr 20 19:56:29 2011
New Revision: 72887

URL: http://svn.debian.org/wsvn/pkg-perl/?sc=1&rev=72887
Log:
[svn-upgrade] new version libmoosex-strictconstructor-perl (0.15)

Modified:
    branches/upstream/libmoosex-strictconstructor-perl/current/Changes
    branches/upstream/libmoosex-strictconstructor-perl/current/LICENSE
    branches/upstream/libmoosex-strictconstructor-perl/current/META.json
    branches/upstream/libmoosex-strictconstructor-perl/current/META.yml
    branches/upstream/libmoosex-strictconstructor-perl/current/Makefile.PL
    branches/upstream/libmoosex-strictconstructor-perl/current/README
    branches/upstream/libmoosex-strictconstructor-perl/current/SIGNATURE
    branches/upstream/libmoosex-strictconstructor-perl/current/dist.ini
    branches/upstream/libmoosex-strictconstructor-perl/current/lib/MooseX/StrictConstructor.pm
    branches/upstream/libmoosex-strictconstructor-perl/current/lib/MooseX/StrictConstructor/Role/Object.pm
    branches/upstream/libmoosex-strictconstructor-perl/current/lib/MooseX/StrictConstructor/Trait/Class.pm
    branches/upstream/libmoosex-strictconstructor-perl/current/lib/MooseX/StrictConstructor/Trait/Method/Constructor.pm
    branches/upstream/libmoosex-strictconstructor-perl/current/t/basic.t
    branches/upstream/libmoosex-strictconstructor-perl/current/t/instance.t
    branches/upstream/libmoosex-strictconstructor-perl/current/t/release-pod-syntax.t

Modified: branches/upstream/libmoosex-strictconstructor-perl/current/Changes
URL: http://svn.debian.org/wsvn/pkg-perl/branches/upstream/libmoosex-strictconstructor-perl/current/Changes?rev=72887&op=diff
==============================================================================
--- branches/upstream/libmoosex-strictconstructor-perl/current/Changes (original)
+++ branches/upstream/libmoosex-strictconstructor-perl/current/Changes Wed Apr 20 19:56:29 2011
@@ -1,3 +1,14 @@
+0.15     2011-04-13
+
+- The fix in 0.14 only worked with Moose 2.0, causing failures with earlier
+  versions.
+
+
+0.14     2011-04-13
+
+- Using extends caused strictness to be lost. Fixed by Karen Etheridge.
+
+
 0.13     2011-02-22
 
 - This release provides forward compatibility with Moose 1.99+. It will still

Modified: branches/upstream/libmoosex-strictconstructor-perl/current/LICENSE
URL: http://svn.debian.org/wsvn/pkg-perl/branches/upstream/libmoosex-strictconstructor-perl/current/LICENSE?rev=72887&op=diff
==============================================================================
--- branches/upstream/libmoosex-strictconstructor-perl/current/LICENSE (original)
+++ branches/upstream/libmoosex-strictconstructor-perl/current/LICENSE Wed Apr 20 19:56:29 2011
@@ -1,4 +1,4 @@
-This software is Copyright (c) 2010 by Dave Rolsky.
+This software is Copyright (c) 2011 by Dave Rolsky.
 
 This is free software, licensed under:
 

Modified: branches/upstream/libmoosex-strictconstructor-perl/current/META.json
URL: http://svn.debian.org/wsvn/pkg-perl/branches/upstream/libmoosex-strictconstructor-perl/current/META.json?rev=72887&op=diff
==============================================================================
--- branches/upstream/libmoosex-strictconstructor-perl/current/META.json (original)
+++ branches/upstream/libmoosex-strictconstructor-perl/current/META.json Wed Apr 20 19:56:29 2011
@@ -4,7 +4,7 @@
       "Dave Rolsky <autarch at urth.org>"
    ],
    "dynamic_config" : 0,
-   "generated_by" : "Dist::Zilla version 4.200004, CPAN::Meta::Converter version 2.110240",
+   "generated_by" : "Dist::Zilla version 4.200004, CPAN::Meta::Converter version 2.110580",
    "license" : [
       "artistic_2"
    ],
@@ -44,6 +44,6 @@
          "web" : "http://git.shadowcat.co.uk/gitweb/gitweb.cgi?p=gitmo/MooseX-StrictConstructor.git;a=summary"
       }
    },
-   "version" : "0.13"
+   "version" : "0.15"
 }
 

Modified: branches/upstream/libmoosex-strictconstructor-perl/current/META.yml
URL: http://svn.debian.org/wsvn/pkg-perl/branches/upstream/libmoosex-strictconstructor-perl/current/META.yml?rev=72887&op=diff
==============================================================================
--- branches/upstream/libmoosex-strictconstructor-perl/current/META.yml (original)
+++ branches/upstream/libmoosex-strictconstructor-perl/current/META.yml Wed Apr 20 19:56:29 2011
@@ -8,7 +8,7 @@
 configure_requires:
   ExtUtils::MakeMaker: 6.31
 dynamic_config: 0
-generated_by: 'Dist::Zilla version 4.200004, CPAN::Meta::Converter version 2.110240'
+generated_by: 'Dist::Zilla version 4.200004, CPAN::Meta::Converter version 2.110580'
 license: artistic_2
 meta-spec:
   url: http://module-build.sourceforge.net/META-spec-v1.4.html
@@ -20,4 +20,4 @@
 resources:
   bugtracker: http://rt.cpan.org/NoAuth/Bugs.html?Dist=MooseX-StrictConstructor
   repository: git://git.moose.perl.org/MooseX-StrictConstructor.git
-version: 0.13
+version: 0.15

Modified: branches/upstream/libmoosex-strictconstructor-perl/current/Makefile.PL
URL: http://svn.debian.org/wsvn/pkg-perl/branches/upstream/libmoosex-strictconstructor-perl/current/Makefile.PL?rev=72887&op=diff
==============================================================================
--- branches/upstream/libmoosex-strictconstructor-perl/current/Makefile.PL (original)
+++ branches/upstream/libmoosex-strictconstructor-perl/current/Makefile.PL Wed Apr 20 19:56:29 2011
@@ -26,7 +26,7 @@
     'Moose' => '0.94',
     'namespace::autoclean' => '0'
   },
-  'VERSION' => '0.13',
+  'VERSION' => '0.15',
   'test' => {
     'TESTS' => 't/*.t'
   }

Modified: branches/upstream/libmoosex-strictconstructor-perl/current/README
URL: http://svn.debian.org/wsvn/pkg-perl/branches/upstream/libmoosex-strictconstructor-perl/current/README?rev=72887&op=diff
==============================================================================
--- branches/upstream/libmoosex-strictconstructor-perl/current/README (original)
+++ branches/upstream/libmoosex-strictconstructor-perl/current/README Wed Apr 20 19:56:29 2011
@@ -1,11 +1,11 @@
 
 
 This archive contains the distribution MooseX-StrictConstructor,
-version 0.13:
+version 0.15:
 
   Make your object constructors blow up on unknown attributes
 
-This software is Copyright (c) 2010 by Dave Rolsky.
+This software is Copyright (c) 2011 by Dave Rolsky.
 
 This is free software, licensed under:
 

Modified: branches/upstream/libmoosex-strictconstructor-perl/current/SIGNATURE
URL: http://svn.debian.org/wsvn/pkg-perl/branches/upstream/libmoosex-strictconstructor-perl/current/SIGNATURE?rev=72887&op=diff
==============================================================================
--- branches/upstream/libmoosex-strictconstructor-perl/current/SIGNATURE (original)
+++ branches/upstream/libmoosex-strictconstructor-perl/current/SIGNATURE Wed Apr 20 19:56:29 2011
@@ -14,30 +14,30 @@
 -----BEGIN PGP SIGNED MESSAGE-----
 Hash: SHA1
 
-SHA1 099ab128447adaa7b9a0b34be3c08ae8d6d30349 Changes
+SHA1 c31bf62712bb4a85632905dadfdcbcad9e90809c Changes
 SHA1 b09c48494e1d0630c6bd6b11fef8e0ac35d509da INSTALL
-SHA1 eb84232fee945db1334ac42224747143e99285ac LICENSE
+SHA1 c715d20265d2931c7564fc64abfdc4f8ff33e297 LICENSE
 SHA1 b815cf8e0fa77a4b2a15e01518282ffbd68fd145 MANIFEST
-SHA1 dfafa4714a9a54ec236fe6e4aee0eb72fd648fdf META.json
-SHA1 c9e4931544d6fd0aa3c75cdc41d5e64704c0f6ac META.yml
-SHA1 07799668a9914b3e38dea1cc9eeaa1b80ebd24ea Makefile.PL
-SHA1 b93f06b8b80ef3a463afbff60f76c0cfdb1c8373 README
-SHA1 f6cd7eae7b7cb10e24ec9dafacc144473ea77330 dist.ini
-SHA1 ab7011339f74b185d49e659742ce022bce9e08cb lib/MooseX/StrictConstructor.pm
-SHA1 f4c98a08202a2da2c3d3b9414d013cd538fadab8 lib/MooseX/StrictConstructor/Role/Object.pm
-SHA1 f5c6cdcf64bb7181208aab9a9f30da42335229fd lib/MooseX/StrictConstructor/Trait/Class.pm
-SHA1 bc37a9cf21a4e7f2a327445c091be7e183f7b233 lib/MooseX/StrictConstructor/Trait/Method/Constructor.pm
-SHA1 25b48e3b97bb0b262c614332a95dea56e5a71aa9 t/basic.t
-SHA1 08967270a332012eb2b6930bc44768d07e7cb8fa t/instance.t
+SHA1 f6ad790c9f354b00fa06904f9d8975c0867b6889 META.json
+SHA1 ac1c0d343670f5691cd8ed8db6410e2f30182a96 META.yml
+SHA1 4fb31c6112fac1fedde81ec64d443eb27ba0326e Makefile.PL
+SHA1 37cfb9149fa6fc6205d204481450f5e4e7f2f682 README
+SHA1 70ff27110cdc9239162c05d745ef8156d5eb2bda dist.ini
+SHA1 65dd30a7f16929bbe47acce37a5cac6262f28634 lib/MooseX/StrictConstructor.pm
+SHA1 ef7980b2328c56d7f559be2ac415b6304f60c0ac lib/MooseX/StrictConstructor/Role/Object.pm
+SHA1 32d5dc72f45ab6172e4777e6dc8de2776df6de64 lib/MooseX/StrictConstructor/Trait/Class.pm
+SHA1 6a6b8f6bef66e4fc0209d8dcd99f761bd1946c5a lib/MooseX/StrictConstructor/Trait/Method/Constructor.pm
+SHA1 4f5938ee545701adeec552fb3f898d4a5c147880 t/basic.t
+SHA1 62e0d60d9456d31463f448be2265c9fc15efcceb t/instance.t
 SHA1 a032c41ef6887fab1b900669c2d304fab46680e2 t/release-eol.t
 SHA1 455d1dd1867212a665ad5ea4126b572411de300c t/release-no-tabs.t
 SHA1 9433c240fe590bc404ab68ff63984df763e347ed t/release-pod-coverage.t
 SHA1 48e2a1a1f3252d687ed5d54cb68109fb1466de7d t/release-pod-spell.t
-SHA1 9775e90d40f094f3e5a23c695d6e6e436a2232c3 t/release-pod-syntax.t
+SHA1 b30cbdfaf935017c4568c0c91b242438cb87786e t/release-pod-syntax.t
 -----BEGIN PGP SIGNATURE-----
 Version: GnuPG v1.4.10 (GNU/Linux)
 
-iEYEARECAAYFAk1khFEACgkQIgMCsV8qvRKvvACffTh26nduj6x3Z9djEYdvPx84
-rmsAn1USl273aFiybPdzq4epGvYyE2yK
-=56Q5
+iEYEARECAAYFAk2l9kcACgkQIgMCsV8qvRJxWgCfY24Ui2bUGnomM0+T5E57w9+G
+JCgAnAkWv5/HaIsrM9xCg+2dFktF5Y3o
+=69v3
 -----END PGP SIGNATURE-----

Modified: branches/upstream/libmoosex-strictconstructor-perl/current/dist.ini
URL: http://svn.debian.org/wsvn/pkg-perl/branches/upstream/libmoosex-strictconstructor-perl/current/dist.ini?rev=72887&op=diff
==============================================================================
--- branches/upstream/libmoosex-strictconstructor-perl/current/dist.ini (original)
+++ branches/upstream/libmoosex-strictconstructor-perl/current/dist.ini Wed Apr 20 19:56:29 2011
@@ -2,9 +2,9 @@
 author  = Dave Rolsky <autarch at urth.org>
 license = Artistic_2_0
 copyright_holder = Dave Rolsky
-copyright_year   = 2010
+copyright_year   = 2011
 
-version = 0.13
+version = 0.15
 
 [@Basic]
 
@@ -22,7 +22,8 @@
 
 [PkgVersion]
 
-[PodTests]
+[PodCoverageTests]
+[PodSyntaxTests]
 [NoTabsTests]
 [EOLTests]
 [Signature]

Modified: branches/upstream/libmoosex-strictconstructor-perl/current/lib/MooseX/StrictConstructor.pm
URL: http://svn.debian.org/wsvn/pkg-perl/branches/upstream/libmoosex-strictconstructor-perl/current/lib/MooseX/StrictConstructor.pm?rev=72887&op=diff
==============================================================================
--- branches/upstream/libmoosex-strictconstructor-perl/current/lib/MooseX/StrictConstructor.pm (original)
+++ branches/upstream/libmoosex-strictconstructor-perl/current/lib/MooseX/StrictConstructor.pm Wed Apr 20 19:56:29 2011
@@ -1,6 +1,6 @@
 package MooseX::StrictConstructor;
 BEGIN {
-  $MooseX::StrictConstructor::VERSION = '0.13';
+  $MooseX::StrictConstructor::VERSION = '0.15';
 }
 
 use strict;
@@ -12,19 +12,13 @@
 use MooseX::StrictConstructor::Role::Object;
 
 {
-    my %class_meta;
+    my %class_meta = ( class => ['MooseX::StrictConstructor::Trait::Class'] );
+
 
     if ( $Moose::VERSION < 1.9900 ) {
         require MooseX::StrictConstructor::Trait::Method::Constructor;
-        %class_meta = (
-            constructor => [
-                'MooseX::StrictConstructor::Trait::Method::Constructor']
-        );
-    }
-    else {
-        require MooseX::StrictConstructor::Trait::Class;
-        %class_meta
-            = ( class => ['MooseX::StrictConstructor::Trait::Class'] );
+        $class_meta{constructor}
+            = ['MooseX::StrictConstructor::Trait::Method::Constructor'];
     }
 
     Moose::Exporter->setup_import_methods(
@@ -47,7 +41,7 @@
 
 =head1 VERSION
 
-version 0.13
+version 0.15
 
 =head1 SYNOPSIS
 
@@ -67,7 +61,7 @@
 
 Simply loading this module makes your constructors "strict". If your
 constructor is called with an attribute init argument that your class
-does not declare, then it calls "Carp::confess()". This is a great way
+does not declare, then it calls C<Moose->throw_error()>. This is a great way
 to catch small typos.
 
 =head2 Subverting Strictness
@@ -104,7 +98,7 @@
 
 =head1 COPYRIGHT AND LICENSE
 
-This software is Copyright (c) 2010 by Dave Rolsky.
+This software is Copyright (c) 2011 by Dave Rolsky.
 
 This is free software, licensed under:
 

Modified: branches/upstream/libmoosex-strictconstructor-perl/current/lib/MooseX/StrictConstructor/Role/Object.pm
URL: http://svn.debian.org/wsvn/pkg-perl/branches/upstream/libmoosex-strictconstructor-perl/current/lib/MooseX/StrictConstructor/Role/Object.pm?rev=72887&op=diff
==============================================================================
--- branches/upstream/libmoosex-strictconstructor-perl/current/lib/MooseX/StrictConstructor/Role/Object.pm (original)
+++ branches/upstream/libmoosex-strictconstructor-perl/current/lib/MooseX/StrictConstructor/Role/Object.pm Wed Apr 20 19:56:29 2011
@@ -1,6 +1,6 @@
 package MooseX::StrictConstructor::Role::Object;
 BEGIN {
-  $MooseX::StrictConstructor::Role::Object::VERSION = '0.13';
+  $MooseX::StrictConstructor::Role::Object::VERSION = '0.15';
 }
 
 use Moose::Role;
@@ -21,8 +21,8 @@
     my @bad = sort grep { !$attrs{$_} } keys %{$params};
 
     if (@bad) {
-        confess
-            "Found unknown attribute(s) init_arg passed to the constructor: @bad";
+        Moose->throw_error(
+            "Found unknown attribute(s) init_arg passed to the constructor: @bad");
     }
 
     return;
@@ -42,7 +42,7 @@
 
 =head1 VERSION
 
-version 0.13
+version 0.15
 
 =head1 SYNOPSIS
 
@@ -65,7 +65,7 @@
 
 =head1 COPYRIGHT AND LICENSE
 
-This software is Copyright (c) 2010 by Dave Rolsky.
+This software is Copyright (c) 2011 by Dave Rolsky.
 
 This is free software, licensed under:
 

Modified: branches/upstream/libmoosex-strictconstructor-perl/current/lib/MooseX/StrictConstructor/Trait/Class.pm
URL: http://svn.debian.org/wsvn/pkg-perl/branches/upstream/libmoosex-strictconstructor-perl/current/lib/MooseX/StrictConstructor/Trait/Class.pm?rev=72887&op=diff
==============================================================================
--- branches/upstream/libmoosex-strictconstructor-perl/current/lib/MooseX/StrictConstructor/Trait/Class.pm (original)
+++ branches/upstream/libmoosex-strictconstructor-perl/current/lib/MooseX/StrictConstructor/Trait/Class.pm Wed Apr 20 19:56:29 2011
@@ -1,6 +1,6 @@
 package MooseX::StrictConstructor::Trait::Class;
 BEGIN {
-  $MooseX::StrictConstructor::Trait::Class::VERSION = '0.13';
+  $MooseX::StrictConstructor::Trait::Class::VERSION = '0.15';
 }
 
 use Moose::Role;
@@ -8,7 +8,6 @@
 use namespace::autoclean;
 
 use B ();
-use Carp ();
 
 around '_inline_BUILDALL' => sub {
     my $orig = shift;
@@ -28,8 +27,21 @@
         'my %attrs = (' . ( join ' ', @attrs ) . ');',
         'my @bad = sort grep { !$attrs{$_} } keys %{ $params };',
         'if (@bad) {',
-            'Carp::confess "Found unknown attribute(s) passed to the constructor: @bad";',
+            'Moose->throw_error("Found unknown attribute(s) passed to the constructor: @bad");',
         '}',
+    );
+} if $Moose::VERSION >= 1.9900;
+
+# If the base class role is applied first, and then a superclass is added, we
+# lose the role.
+after superclasses => sub {
+    my $self = shift;
+
+    return unless @_;
+
+    Moose::Util::MetaRole::apply_base_class_roles(
+        for   => $self->name(),
+        roles => ['MooseX::StrictConstructor::Role::Object'],
     );
 };
 
@@ -47,7 +59,7 @@
 
 =head1 VERSION
 
-version 0.13
+version 0.15
 
 =head1 DESCRIPTION
 
@@ -61,7 +73,7 @@
 
 =head1 COPYRIGHT AND LICENSE
 
-This software is Copyright (c) 2010 by Dave Rolsky.
+This software is Copyright (c) 2011 by Dave Rolsky.
 
 This is free software, licensed under:
 

Modified: branches/upstream/libmoosex-strictconstructor-perl/current/lib/MooseX/StrictConstructor/Trait/Method/Constructor.pm
URL: http://svn.debian.org/wsvn/pkg-perl/branches/upstream/libmoosex-strictconstructor-perl/current/lib/MooseX/StrictConstructor/Trait/Method/Constructor.pm?rev=72887&op=diff
==============================================================================
--- branches/upstream/libmoosex-strictconstructor-perl/current/lib/MooseX/StrictConstructor/Trait/Method/Constructor.pm (original)
+++ branches/upstream/libmoosex-strictconstructor-perl/current/lib/MooseX/StrictConstructor/Trait/Method/Constructor.pm Wed Apr 20 19:56:29 2011
@@ -1,6 +1,6 @@
 package MooseX::StrictConstructor::Trait::Method::Constructor;
 BEGIN {
-  $MooseX::StrictConstructor::Trait::Method::Constructor::VERSION = '0.13';
+  $MooseX::StrictConstructor::Trait::Method::Constructor::VERSION = '0.15';
 }
 
 use Moose::Role;
@@ -8,7 +8,6 @@
 use namespace::autoclean;
 
 use B ();
-use Carp ();
 
 around '_generate_BUILDALL' => sub {
     my $orig = shift;
@@ -30,7 +29,7 @@
 my \@bad = sort grep { ! \$attrs{\$_} }  keys \%{ \$params };
 
 if (\@bad) {
-    Carp::confess "Found unknown attribute(s) passed to the constructor: \@bad";
+    Moose->throw_error("Found unknown attribute(s) passed to the constructor: \@bad");
 }
 EOF
 
@@ -51,7 +50,7 @@
 
 =head1 VERSION
 
-version 0.13
+version 0.15
 
 =head1 DESCRIPTION
 
@@ -65,7 +64,7 @@
 
 =head1 COPYRIGHT AND LICENSE
 
-This software is Copyright (c) 2010 by Dave Rolsky.
+This software is Copyright (c) 2011 by Dave Rolsky.
 
 This is free software, licensed under:
 

Modified: branches/upstream/libmoosex-strictconstructor-perl/current/t/basic.t
URL: http://svn.debian.org/wsvn/pkg-perl/branches/upstream/libmoosex-strictconstructor-perl/current/t/basic.t?rev=72887&op=diff
==============================================================================
--- branches/upstream/libmoosex-strictconstructor-perl/current/t/basic.t (original)
+++ branches/upstream/libmoosex-strictconstructor-perl/current/t/basic.t Wed Apr 20 19:56:29 2011
@@ -34,6 +34,27 @@
 }
 
 {
+    package StrictSubclass;
+
+    use Moose;
+
+    extends 'Stricter';
+
+    has 'size' => ( is => 'rw' );
+}
+
+{
+    package OtherStrictSubclass;
+
+    use Moose;
+    use MooseX::StrictConstructor;
+
+    extends 'Standard';
+
+    has 'size' => ( is => 'rw' );
+}
+
+{
     package Tricky;
 
     use Moose;
@@ -59,7 +80,8 @@
     has 'size'  => ( is => 'rw', 'init_arg' => undef );
 }
 
-my @classes = qw( Standard Stricter Subclass Tricky InitArg );
+my @classes
+    = qw( Standard Stricter Subclass StrictSubclass OtherStrictSubclass Tricky InitArg );
 
 with_immutable {
     is(
@@ -85,6 +107,30 @@
     );
 
     is(
+        exception { StrictSubclass->new( thing => 1, size => 'large', ) },
+        undef,
+        q{subclass that doesn't use strict constructor handles known attributes correctly}
+    );
+
+    like(
+        exception { StrictSubclass->new( thing => 1, bad => 99 ) },
+        qr/unknown attribute.+: bad/,
+        q{subclass that doesn't use strict correctly recognizes bad attribute}
+    );
+
+    is(
+        exception { OtherStrictSubclass->new( thing => 1, size => 'large', ) },
+        undef,
+        q{strict subclass from parent that doesn't use strict constructor handles known attributes correctly}
+    );
+
+    like(
+        exception { OtherStrictSubclass->new( thing => 1, bad => 99 ) },
+        qr/unknown attribute.+: bad/,
+        q{strict subclass from parent that doesn't use strict correctly recognizes bad attribute}
+    );
+
+    is(
         exception { Tricky->new( thing => 1, spy => 99 ) }, undef,
         'can work around strict constructor by deleting params in BUILD()'
     );
@@ -93,12 +139,6 @@
         exception { Tricky->new( thing => 1, agent => 99 ) },
         qr/unknown attribute.+: agent/,
         'Tricky still blows up on unknown params other than spy'
-    );
-
-    like(
-        exception { Subclass->new( thing => 1, bad => 99 ) },
-        qr/unknown attribute.+: bad/,
-        'subclass constructor blows up on unknown params'
     );
 
     like(

Modified: branches/upstream/libmoosex-strictconstructor-perl/current/t/instance.t
URL: http://svn.debian.org/wsvn/pkg-perl/branches/upstream/libmoosex-strictconstructor-perl/current/t/instance.t?rev=72887&op=diff
==============================================================================
--- branches/upstream/libmoosex-strictconstructor-perl/current/t/instance.t (original)
+++ branches/upstream/libmoosex-strictconstructor-perl/current/t/instance.t Wed Apr 20 19:56:29 2011
@@ -3,6 +3,7 @@
 
 use Test::More;
 use Test::Moose qw( with_immutable );
+use Test::Fatal;
 
 {
     package Foo;
@@ -11,11 +12,17 @@
 }
 
 with_immutable {
-    eval { Foo->new( __INSTANCE__ => Foo->new ); };
-    ok( !$@, '__INSTANCE__ is ignored when passed to ->new' );
+    is(
+        exception { Foo->new( __INSTANCE__ => Foo->new ) },
+        undef,
+        '__INSTANCE__ is ignored when passed to ->new',
+    );
 
-    eval { Foo->meta->new_object( __INSTANCE__ => Foo->new ); };
-    ok( !$@, '__INSTANCE__ is ignored when passed to ->new_object' );
+    is(
+        exception { Foo->meta->new_object( __INSTANCE__ => Foo->new ) },
+        undef,
+        '__INSTANCE__ is ignored when passed to ->new_object',
+    );
 }
 'Foo';
 

Modified: branches/upstream/libmoosex-strictconstructor-perl/current/t/release-pod-syntax.t
URL: http://svn.debian.org/wsvn/pkg-perl/branches/upstream/libmoosex-strictconstructor-perl/current/t/release-pod-syntax.t?rev=72887&op=diff
==============================================================================
--- branches/upstream/libmoosex-strictconstructor-perl/current/t/release-pod-syntax.t (original)
+++ branches/upstream/libmoosex-strictconstructor-perl/current/t/release-pod-syntax.t Wed Apr 20 19:56:29 2011
@@ -9,7 +9,7 @@
 
 use Test::More;
 
-eval "use Test::Pod 1.00";
-plan skip_all => "Test::Pod 1.00 required for testing POD" if $@;
+eval "use Test::Pod 1.41";
+plan skip_all => "Test::Pod 1.41 required for testing POD" if $@;
 
 all_pod_files_ok();




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