diff -Nru libmoosex-log-log4perl-perl-0.45/Changes libmoosex-log-log4perl-perl-0.46/Changes --- libmoosex-log-log4perl-perl-0.45/Changes 2012-05-07 21:12:15.000000000 +0000 +++ libmoosex-log-log4perl-perl-0.46/Changes 2012-06-27 18:46:50.000000000 +0000 @@ -1,5 +1,9 @@ Revision history for MooseX::Log::Log4perl +0.46 Wed Jun 27 2012 (rl) + * RT#77451: Spelling mistake in Easy.pm (thanks gregoa@debian.org) + * RT#77783: Added tests (03inheritence) to showcase expected category in logging + 0.45 Mon May 7 2012 (rl) * RT#72596: META file needs regenerating, should be fixed now * Correct some dist stuff (copyright, license, bundled Module::Install) diff -Nru libmoosex-log-log4perl-perl-0.45/debian/changelog libmoosex-log-log4perl-perl-0.46/debian/changelog --- libmoosex-log-log4perl-perl-0.45/debian/changelog 2012-05-26 18:47:16.000000000 +0000 +++ libmoosex-log-log4perl-perl-0.46/debian/changelog 2012-06-30 15:40:32.000000000 +0000 @@ -1,3 +1,10 @@ +libmoosex-log-log4perl-perl (0.46-1) unstable; urgency=low + + * New upstream release. + * Drop fix-pod-spelling.patch, merged upstream. + + -- gregor herrmann Sat, 30 Jun 2012 17:40:28 +0200 + libmoosex-log-log4perl-perl (0.45-1) unstable; urgency=low * New upstream release. diff -Nru libmoosex-log-log4perl-perl-0.45/debian/patches/fix-pod-spelling.patch libmoosex-log-log4perl-perl-0.46/debian/patches/fix-pod-spelling.patch --- libmoosex-log-log4perl-perl-0.45/debian/patches/fix-pod-spelling.patch 2012-05-26 18:47:16.000000000 +0000 +++ libmoosex-log-log4perl-perl-0.46/debian/patches/fix-pod-spelling.patch 1970-01-01 00:00:00.000000000 +0000 @@ -1,19 +0,0 @@ -Description: fix POD spelling errors -Origin: vendor -Bug: https://rt.cpan.org/Ticket/Display.html?id=77451 -Forwarded: https://rt.cpan.org/Ticket/Display.html?id=77451 -Author: Jonathan Yu -Reviewed-by: gregor herrmann -Last-Update: 2012-05-26 - ---- a/lib/MooseX/Log/Log4perl/Easy.pm -+++ b/lib/MooseX/Log/Log4perl/Easy.pm -@@ -47,7 +47,7 @@ - - $self->log_info("blabla"); - --without having to access a seperate log attribute as in MooseX::Log::Log4perl; -+without having to access a separate log attribute as in MooseX::Log::Log4perl; - - In case your app grows and you need more of the super-cow powers of Log4perl or simply don't want the additional - methods to clutter up your class you can simply replace all code C<< $self->log_LEVEL >> with diff -Nru libmoosex-log-log4perl-perl-0.45/debian/patches/series libmoosex-log-log4perl-perl-0.46/debian/patches/series --- libmoosex-log-log4perl-perl-0.45/debian/patches/series 2012-05-26 18:47:16.000000000 +0000 +++ libmoosex-log-log4perl-perl-0.46/debian/patches/series 1970-01-01 00:00:00.000000000 +0000 @@ -1 +0,0 @@ -fix-pod-spelling.patch diff -Nru libmoosex-log-log4perl-perl-0.45/lib/MooseX/Log/Log4perl/Easy.pm libmoosex-log-log4perl-perl-0.46/lib/MooseX/Log/Log4perl/Easy.pm --- libmoosex-log-log4perl-perl-0.45/lib/MooseX/Log/Log4perl/Easy.pm 2012-05-07 21:12:41.000000000 +0000 +++ libmoosex-log-log4perl-perl-0.46/lib/MooseX/Log/Log4perl/Easy.pm 2012-06-27 18:47:40.000000000 +0000 @@ -4,7 +4,7 @@ with 'MooseX::Log::Log4perl'; -our $VERSION = '0.45'; +our $VERSION = '0.46'; sub log_fatal { local $Log::Log4perl::caller_depth += 1; return shift->logger->fatal(@_); } sub log_error { local $Log::Log4perl::caller_depth += 1; return shift->logger->error(@_); } @@ -47,7 +47,7 @@ $self->log_info("blabla"); -without having to access a seperate log attribute as in MooseX::Log::Log4perl; +without having to access a separate log attribute as in MooseX::Log::Log4perl; In case your app grows and you need more of the super-cow powers of Log4perl or simply don't want the additional methods to clutter up your class you can simply replace all code C<< $self->log_LEVEL >> with diff -Nru libmoosex-log-log4perl-perl-0.45/lib/MooseX/Log/Log4perl.pm libmoosex-log-log4perl-perl-0.46/lib/MooseX/Log/Log4perl.pm --- libmoosex-log-log4perl-perl-0.45/lib/MooseX/Log/Log4perl.pm 2012-05-07 21:12:29.000000000 +0000 +++ libmoosex-log-log4perl-perl-0.46/lib/MooseX/Log/Log4perl.pm 2012-06-27 18:47:32.000000000 +0000 @@ -4,7 +4,7 @@ use Any::Moose 'Role'; use Log::Log4perl; -our $VERSION = '0.45'; +our $VERSION = '0.46'; has 'logger' => ( is => 'rw', diff -Nru libmoosex-log-log4perl-perl-0.45/MANIFEST libmoosex-log-log4perl-perl-0.46/MANIFEST --- libmoosex-log-log4perl-perl-0.45/MANIFEST 2011-10-31 00:06:06.000000000 +0000 +++ libmoosex-log-log4perl-perl-0.46/MANIFEST 2012-06-27 18:48:41.000000000 +0000 @@ -19,6 +19,7 @@ t/00load.t t/01basic.t t/02easy.t +t/03inheritance.t t/99bench.t t/perl-critic.t t/perlcriticrc diff -Nru libmoosex-log-log4perl-perl-0.45/META.yml libmoosex-log-log4perl-perl-0.46/META.yml --- libmoosex-log-log4perl-perl-0.45/META.yml 2012-05-07 21:25:03.000000000 +0000 +++ libmoosex-log-log4perl-perl-0.46/META.yml 2012-06-27 18:51:04.000000000 +0000 @@ -30,4 +30,4 @@ resources: license: http://dev.perl.org/licenses/ repository: https://github.com/lammel/moosex-log-log4perl -version: 0.45 +version: 0.46 diff -Nru libmoosex-log-log4perl-perl-0.45/t/03inheritance.t libmoosex-log-log4perl-perl-0.46/t/03inheritance.t --- libmoosex-log-log4perl-perl-0.45/t/03inheritance.t 1970-01-01 00:00:00.000000000 +0000 +++ libmoosex-log-log4perl-perl-0.46/t/03inheritance.t 2012-06-27 18:45:15.000000000 +0000 @@ -0,0 +1,68 @@ +use strict; +use warnings; + +use IO::Scalar; +use Log::Log4perl; + +use Test::More tests => 3; + +BEGIN { + my $cfg = <<__ENDCFG__; +log4perl.rootLogger = TRACE, Console + +log4perl.appender.Console = Log::Log4perl::Appender::Screen +log4perl.appender.Console.stderr = 1 +log4perl.appender.Console.layout = Log::Log4perl::Layout::PatternLayout +log4perl.appender.Console.layout.ConversionPattern = %p [%c] [%M] %m%n +__ENDCFG__ + Log::Log4perl->init(\$cfg); +} + +{ + package Parent; + + use Moose; + with 'MooseX::Log::Log4perl'; + + sub overridden { shift->log->warn('Parent overridden'); } + sub parentonly { shift->log->warn('Parent parentonly'); } +} + +{ + package Child; + + use Moose; + extends 'Parent'; + with 'MooseX::Log::Log4perl'; + + sub overridden { shift->log->warn('Child overridden'); } +} + +{ + my $p = Parent->new(); + isa_ok( $p, 'Parent' ); + my $c = Child->new(); + isa_ok( $c, 'Child' ); + + tie *STDERR, 'IO::Scalar', \my $err; + local $SIG{__DIE__} = sub { untie *STDERR; die @_ }; + + $p->overridden; + $c->overridden; + $p->parentonly; + $c->parentonly; + + untie *STDERR; + + # Cleanup log output line-endings + $err =~ s/\r\n/\n/gm; + + my $expect = <<__ENDLOG__; +WARN [Parent] [Parent::overridden] Parent overridden +WARN [Child] [Child::overridden] Child overridden +WARN [Parent] [Parent::parentonly] Parent parentonly +WARN [Child] [Parent::parentonly] Parent parentonly +__ENDLOG__ + + is( $err, $expect, "Log messages for overridden and non-overridden methods are correct" ); +}