Hello community,
here is the log from the commit of package perl-MooseX-Log-Log4perl for openSUSE:Factory checked in at 2015-12-13 09:39:51
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/perl-MooseX-Log-Log4perl (Old)
and /work/SRC/openSUSE:Factory/.perl-MooseX-Log-Log4perl.new (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "perl-MooseX-Log-Log4perl"
Changes:
--------
--- /work/SRC/openSUSE:Factory/perl-MooseX-Log-Log4perl/perl-MooseX-Log-Log4perl.changes 2013-06-06 13:24:00.000000000 +0200
+++ /work/SRC/openSUSE:Factory/.perl-MooseX-Log-Log4perl.new/perl-MooseX-Log-Log4perl.changes 2015-12-13 09:39:57.000000000 +0100
@@ -1,0 +2,8 @@
+Wed Dec 9 09:24:31 UTC 2015 - coolo@suse.com
+
+- updated to 0.47
+ see /usr/share/doc/packages/perl-MooseX-Log-Log4perl/Changes
+
+ * RT#82888: Refactor to use Moo instead of Any::Moose (Alexander Hartmaier)
+
+-------------------------------------------------------------------
Old:
----
MooseX-Log-Log4perl-0.46.tar.gz
New:
----
MooseX-Log-Log4perl-0.47.tar.gz
cpanspec.yml
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Other differences:
------------------
++++++ perl-MooseX-Log-Log4perl.spec ++++++
--- /var/tmp/diff_new_pack.Cboxqv/_old 2015-12-13 09:39:58.000000000 +0100
+++ /var/tmp/diff_new_pack.Cboxqv/_new 2015-12-13 09:39:58.000000000 +0100
@@ -1,7 +1,7 @@
#
# spec file for package perl-MooseX-Log-Log4perl
#
-# Copyright (c) 2013 SUSE LINUX Products GmbH, Nuernberg, Germany.
+# Copyright (c) 2015 SUSE LINUX GmbH, Nuernberg, Germany.
#
# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed
@@ -17,47 +17,33 @@
Name: perl-MooseX-Log-Log4perl
-Version: 0.46
+Version: 0.47
Release: 0
%define cpan_name MooseX-Log-Log4perl
-Summary: A Logging Role for Moose based on Log::Log4perl
+Summary: Logging Role for Moose based on Log::Log4perl
License: Artistic-1.0 or GPL-1.0+
Group: Development/Libraries/Perl
Url: http://search.cpan.org/dist/MooseX-Log-Log4perl/
-Source: http://www.cpan.org/authors/id/L/LA/LAMMEL/%{cpan_name}-%{version}.tar.gz
+Source0: http://www.cpan.org/authors/id/L/LA/LAMMEL/%{cpan_name}-%{version}.tar.gz
+Source1: cpanspec.yml
BuildArch: noarch
BuildRoot: %{_tmppath}/%{name}-%{version}-build
BuildRequires: perl
BuildRequires: perl-macros
-BuildRequires: perl(Any::Moose) >= 0.12
BuildRequires: perl(IO::Scalar)
BuildRequires: perl(Log::Log4perl) >= 1.13
-BuildRequires: perl(Moose) >= 0.65
-#BuildRequires: perl(CPANPLUS::Backend)
-#BuildRequires: perl(inc::Module::Install)
-#BuildRequires: perl(JSON)
-#BuildRequires: perl(Log::Log4perl::Appender::TestBuffer)
-#BuildRequires: perl(LWP::Simple)
-#BuildRequires: perl(Module::AutoInstall)
-#BuildRequires: perl(Module::Build)
-#BuildRequires: perl(Module::Install::Base)
-#BuildRequires: perl(MooseX::Log::Log4perl)
-#BuildRequires: perl(MooseX::Log::Log4perl::Easy)
-#BuildRequires: perl(Parent)
-#BuildRequires: perl(Parse::CPAN::Meta)
-#BuildRequires: perl(Test::Perl::Critic)
-#BuildRequires: perl(YAML::Tiny)
-Requires: perl(Any::Moose) >= 0.12
+BuildRequires: perl(Moo) >= 1.000007
Requires: perl(Log::Log4perl) >= 1.13
+Requires: perl(Moo) >= 1.000007
Recommends: perl(Moose) >= 0.65
%{perl_requires}
%description
-A logging role building a very lightweight wrapper to the Log::Log4perl
-manpage for use with your the Moose manpage classes. The initialization of
-the Log4perl instance must be performed prior to logging the first log
-message. Otherwise the default initialization will happen, probably not
-doing the things you expect.
+A logging role building a very lightweight wrapper to Log::Log4perl for use
+with your Moose or Moo classes. The initialization of the Log4perl instance
+must be performed prior to logging the first log message. Otherwise the
+default initialization will happen, probably not doing the things you
+expect.
For compatibility the 'logger' attribute can be accessed to use a common
interface for application logging.
++++++ MooseX-Log-Log4perl-0.46.tar.gz -> MooseX-Log-Log4perl-0.47.tar.gz ++++++
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/MooseX-Log-Log4perl-0.46/Changes new/MooseX-Log-Log4perl-0.47/Changes
--- old/MooseX-Log-Log4perl-0.46/Changes 2012-06-27 20:46:50.000000000 +0200
+++ new/MooseX-Log-Log4perl-0.47/Changes 2015-12-08 19:07:16.000000000 +0100
@@ -1,4 +1,5 @@
Revision history for MooseX::Log::Log4perl
+ * RT#82888: Refactor to use Moo instead of Any::Moose (Alexander Hartmaier)
0.46 Wed Jun 27 2012 (rl)
* RT#77451: Spelling mistake in Easy.pm (thanks gregoa@debian.org)
@@ -14,7 +15,7 @@
* Fix wrong META.yml file
0.43 Thu Aug 25 2011 (rl)
- * Change to use Any::Moose to also support Mouse environemnt
+ * Change to use Any::Moose to also support Mouse environment
* Documentation improvements for Any::Moose
0.42 Thu Apr 29 2010 (again)
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/MooseX-Log-Log4perl-0.46/META.yml new/MooseX-Log-Log4perl-0.47/META.yml
--- old/MooseX-Log-Log4perl-0.46/META.yml 2012-06-27 20:51:04.000000000 +0200
+++ new/MooseX-Log-Log4perl-0.47/META.yml 2015-12-08 21:47:16.000000000 +0100
@@ -3,31 +3,30 @@
author:
- 'Roland Lammel '
build_requires:
- ExtUtils::MakeMaker: 6.57
- IO::Scalar: 0
- Moose: 0.65
- Test::More: 0
+ ExtUtils::MakeMaker: '6.59'
+ IO::Scalar: '0'
+ Test::More: '0'
configure_requires:
- ExtUtils::MakeMaker: 6.57
-distribution_type: module
+ ExtUtils::MakeMaker: '0'
dynamic_config: 0
-generated_by: 'Module::Install version 1.06'
+generated_by: 'Module::Install version 1.06, CPAN::Meta::Converter version 2.150005'
license: perl
meta-spec:
url: http://module-build.sourceforge.net/META-spec-v1.4.html
- version: 1.4
+ version: '1.4'
name: MooseX-Log-Log4perl
no_index:
directory:
- inc
- t
recommends:
- Moose: 0.65
+ Moose: '0.65'
requires:
- Any::Moose: 0.12
- Log::Log4perl: 1.13
- perl: 5.8.0
+ Log::Log4perl: '1.13'
+ Moo: '1.000007'
+ perl: '5.008'
resources:
license: http://dev.perl.org/licenses/
repository: https://github.com/lammel/moosex-log-log4perl
-version: 0.46
+version: '0.47'
+x_serialization_backend: 'CPAN::Meta::YAML version 0.016'
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/MooseX-Log-Log4perl-0.46/Makefile.PL new/MooseX-Log-Log4perl-0.47/Makefile.PL
--- old/MooseX-Log-Log4perl-0.46/Makefile.PL 2012-06-27 20:05:33.000000000 +0200
+++ new/MooseX-Log-Log4perl-0.47/Makefile.PL 2015-12-08 21:15:18.000000000 +0100
@@ -5,13 +5,10 @@
build_requires 'IO::Scalar';
build_requires 'Test::More';
-build_requires 'Moose' => '0.65';
-requires 'Any::Moose' => '0.12';
+requires 'Moo' => '1.000007';
requires 'Log::Log4perl' => '1.13';
-recommends 'Moose' => '0.65';
-
license 'perl';
auto_install;
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/MooseX-Log-Log4perl-0.46/README new/MooseX-Log-Log4perl-0.47/README
--- old/MooseX-Log-Log4perl-0.46/README 2012-06-27 20:05:33.000000000 +0200
+++ new/MooseX-Log-Log4perl-0.47/README 2015-12-08 22:00:51.000000000 +0100
@@ -1,34 +1,170 @@
-MooseX-Log-Log4perl version 0.45
+NAME
+----
-INSTALLATION
+ MooseX::Log::Log4perl - A Logging Role for Moose based on Log::Log4perl
-To install this module, run the following commands:
+SYNOPSIS
+--------
- perl Makefile.PL
- make
- make test
- make install
+ package MyApp;
+ use Moose;
+ with 'MooseX::Log::Log4perl';
-Alternatively, to install with Module::Build, you can use the following commands:
+ sub something {
+ my ($self) = @_;
+ $self->log->debug("started bar"); ### logs with default class catergory "MyApp"
+ ...
+ $self->log('special')->info('bar'); ### logs with category "special"
+ ...
+ $self->log('.special')->info('bar'); ### logs with category "MyApp.special"
+ $self->log('::special')->info('bar');### logs with category "MyApp.special"
+ }
- perl Build.PL
- ./Build
- ./Build test
- ./Build install
+DESCRIPTION
+-----------
+A logging role building a very lightweight wrapper to Log::Log4perl for
+use with your Moose or Moo classes. The initialization of the Log4perl
+instance must be performed prior to logging the first log message.
+Otherwise the default initialization will happen, probably not doing the
+things you expect.
+For compatibility the "logger" attribute can be accessed to use a common
+interface for application logging.
-DEPENDENCIES
+Using the logger within a class is as simple as consuming a role:
-- Any::Moose
-- Moose or Mouse
-- Log::Log4perl
+ package MyClass;
+ use Moose;
+ with 'MooseX::Log::Log4perl';
+ sub dummy {
+ my $self = shift;
+ $self->log->info("Dummy log entry");
+ }
-COPYRIGHT AND LICENSE
+The logger needs to be setup before using the logger, which could happen
+in the main application:
-Copyright (C) 2008-2012, Roland Lammel
+ package main;
+ use Log::Log4perl qw(:easy);
+ use MyClass;
-This library is free software; you can redistribute it and/or modify
-it under the same terms as Perl itself.
+ BEGIN { Log::Log4perl->easy_init() };
+
+ my $myclass = MyClass->new();
+ $myclass->log->info("In my class"); # Access the log of the object
+ $myclass->dummy; # Will log "Dummy log entry"
+
+EVEN SIMPLER USE
+----------------
+
+For simple logging needs use MooseX::Log::Log4perl::Easy to directly add
+log_<level> methods to your class instance.
+
+ $self->log_info("Dummy");
+
+USING WITH MOO INSTEAD OF MOOSE
+-------------------------------
+
+As this module is using Moo, you can use it with Moo instead of Moose too.
+This will allow to simple use it as documented above in a Moo based application,
+like shown in the example below:
+
+This is your class consuming the MooseX::Log::Log4perl role.
+
+ package MyCat;
+ use Moo;
+
+ with 'MooseX::Log::Log4perl';
+
+ sub catch_it {
+ my $self = shift;
+ $self->log->debug("Say Miau");
+ }
+
+Which can be simply used in your main application then.
+
+ package main;
+ use MyCat;
+ use Log::Log4perl qw(:easy);
+ BEGIN { Log::Log4perl->easy_init() };
+
+ my $log = Log::Log4perl->get_logger();
+ $log->info("Application startup...");
+ MyCat->new()->catch_it(); ### Will log "Dummy dodo"
+
+ACCESSORS
+---------
+
+### logger
+
+The "logger" attribute holds the Log::Log4perl object that implements all
+logging methods for the defined log levels, such as "debug" or "error". As
+this method is defined also in other logging roles/systems like
+MooseX::Log::LogDispatch this can be thought of as a common logging
+interface.
+
+ package MyApp::View::JSON;
+
+ extends 'MyApp::View';
+ with 'MooseX:Log::Log4perl';
+
+ sub bar {
+ $self->logger->info("Everything fine so far"); # logs a info message
+ $self->logger->debug("Something is fishy here"); # logs a debug message
+ }
+
+### log([$category])
+
+Basically the same as logger, but also allowing to change the log category
+for this log message. If the category starts with a "+", we pre-pend the
+current class (what would have been the category if you didn't specify
+one).
+
+ if ($myapp->log->is_debug()) {
+ $myapp->log->debug("Woot"); # category is class myapp
+ }
+ $myapp->log("TempCat")->info("Foobar"); # category TempCat
+ $myapp->log->info("Grumble"); # category class again myapp
+ $myapp->log(".TempCat")->info("Foobar"); # category myapp.TempCat
+ $myapp->log("::TempCat")->info("Foobar"); # category myapp.TempCat
+
+SEE ALSO
+--------
+
+Log::Log4perl, Moose, Moo, MooX::Log::Any, MooX::Role::Logger
+
+BUGS AND LIMITATIONS
+--------------------
+
+Please report any issues at https://github.com/lammel/moosex-log-log4perl
+
+Or come bother us in "#moose" on "irc.perl.org".
+
+AUTHOR
+-------
+
+Roland Lammel
+
+Inspired by the work by Chris Prather and Ash Berlin
+ on MooseX::LogDispatch
+
+CONTRIBUTORS
+------------
+
+In alphabetical order:
+
+* abraxxa for Any::Moose deprectation
+* Michael Schilli for Log::Log4perl and interface suggestions
+* omega for catgory prefix support
+* Tim Bunce for corrections in the MooseX::Log::Log4perl::Easy module.
+
+LICENSE AND COPYRIGHT
+---------------------
+
+Copyright (c) 2008-2016, Roland Lammel , http://www.quikit.at
+
+This module is free software; you can redistribute it and/or modify it
+under the same terms as Perl itself. See perlartistic.
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/MooseX-Log-Log4perl-0.46/inc/Module/AutoInstall.pm new/MooseX-Log-Log4perl-0.47/inc/Module/AutoInstall.pm
--- old/MooseX-Log-Log4perl-0.46/inc/Module/AutoInstall.pm 2012-06-27 20:05:33.000000000 +0200
+++ new/MooseX-Log-Log4perl-0.47/inc/Module/AutoInstall.pm 2015-12-08 19:07:16.000000000 +0100
@@ -28,7 +28,7 @@
$PostambleActionsListAllDeps, $PostambleUsed, $NoTest);
# See if it's a testing or non-interactive session
-_accept_default( $ENV{AUTOMATED_TESTING} or ! -t STDIN );
+_accept_default( $ENV{AUTOMATED_TESTING} or ! -t STDIN );
_init();
sub _accept_default {
@@ -433,7 +433,7 @@
$conf->set_conf( makeflags => $makeflags );
$conf->set_conf( prereqs => 1 );
-
+
while ( my ( $key, $val ) = splice( @config, 0, 2 ) ) {
$conf->set_conf( $key, $val );
@@ -769,7 +769,7 @@
# check for version numbers that are not in decimal format
if ( ref($cur) or ref($min) or $cur =~ /v|\..*\./ or $min =~ /v|\..*\./ ) {
if ( ( $version::VERSION or defined( _load('version') )) and
- version->can('new')
+ version->can('new')
) {
# use version.pm if it is installed.
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/MooseX-Log-Log4perl-0.46/lib/MooseX/Log/Log4perl/Easy.pm new/MooseX-Log-Log4perl-0.47/lib/MooseX/Log/Log4perl/Easy.pm
--- old/MooseX-Log-Log4perl-0.46/lib/MooseX/Log/Log4perl/Easy.pm 2012-06-27 20:47:40.000000000 +0200
+++ new/MooseX-Log-Log4perl-0.47/lib/MooseX/Log/Log4perl/Easy.pm 2015-12-08 21:29:47.000000000 +0100
@@ -1,10 +1,10 @@
package MooseX::Log::Log4perl::Easy;
-use Any::Moose 'Role';
+use Moo::Role;
with 'MooseX::Log::Log4perl';
-our $VERSION = '0.46';
+our $VERSION = '0.47';
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(@_); }
@@ -30,7 +30,7 @@
with 'MooseX::Log::Log4perl::Easy';
BEGIN {
- Log::Log4perl->easy_init();
+ Log::Log4perl->easy_init();
}
sub foo {
@@ -42,16 +42,17 @@
=head1 DESCRIPTION
-The Easy logging role based on the LMooseX::Log::Log4perl logging role for Moose directly adds the
-logmethods for all available levels to your class instance. Hence it is possible to use
+The "Easy" logging role based on the LMooseX::Log::Log4perl logging role for
+Moose directly adds the log methods for all available levels to your class
+instance. Hence it is possible to use
$self->log_info("blabla");
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
-C<< $self->log->LEVEL >>.
+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 C<< $self->log->LEVEL >>.
You can use the following regex substitution to accomplish that:
@@ -105,28 +106,15 @@
=head1 SEE ALSO
-LMooseX::Log::Log4perl, LLog::Log4perl, L<Moose>
-
-=head1 BUGS AND LIMITATIONS
-
-Please report any bugs or feature requests to
-C, or through the web interface at
-Lhttp://rt.cpan.org.
-
-Or come bother us in C<#moose> on C.
+LMooseX::Log::Log4perl
=head1 AUTHOR
Roland Lammel C<< >>
-Inspired by suggestions by Michael Schilli C<< >>
-
-Contributions from Tim Bunce C<< >>
-
=head1 LICENSE AND COPYRIGHT
-Copyright (c) 2008-2012, Roland Lammel C<< >>, http://www.quikit.at
+Copyright (c) 2008-2016, Roland Lammel L<< >>, http://www.quikit.at
This module is free software; you can redistribute it and/or
modify it under the same terms as Perl itself. See L<perlartistic>.
-
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/MooseX-Log-Log4perl-0.46/lib/MooseX/Log/Log4perl.pm new/MooseX-Log-Log4perl-0.47/lib/MooseX/Log/Log4perl.pm
--- old/MooseX-Log-Log4perl-0.46/lib/MooseX/Log/Log4perl.pm 2012-06-27 20:47:32.000000000 +0200
+++ new/MooseX-Log-Log4perl-0.47/lib/MooseX/Log/Log4perl.pm 2015-12-08 21:31:04.000000000 +0100
@@ -1,14 +1,13 @@
package MooseX::Log::Log4perl;
use 5.008;
-use Any::Moose 'Role';
+use Moo::Role;
use Log::Log4perl;
-our $VERSION = '0.46';
+our $VERSION = '0.47';
has 'logger' => (
is => 'rw',
- isa => 'Log::Log4perl::Logger',
lazy => 1,
default => sub { return Log::Log4perl->get_logger(ref($_[0])) }
);
@@ -37,9 +36,9 @@
package MyApp;
use Moose;
-
+
with 'MooseX::Log::Log4perl';
-
+
sub something {
my ($self) = @_;
$self->log->debug("started bar"); ### logs with default class catergory "MyApp"
@@ -52,7 +51,7 @@
=head1 DESCRIPTION
-A logging role building a very lightweight wrapper to LLog::Log4perl for use with your L<Moose> classes.
+A logging role building a very lightweight wrapper to LLog::Log4perl for use with your L<Moose> or L<Moo> classes.
The initialization of the Log4perl instance must be performed prior to logging the first log message.
Otherwise the default initialization will happen, probably not doing the things you expect.
@@ -63,7 +62,7 @@
package MyClass;
use Moose;
with 'MooseX::Log::Log4perl';
-
+
sub dummy {
my $self = shift;
$self->log->info("Dummy log entry");
@@ -74,9 +73,9 @@
package main;
use Log::Log4perl qw(:easy);
use MyClass;
-
+
BEGIN { Log::Log4perl->easy_init() };
-
+
my $myclass = MyClass->new();
$myclass->log->info("In my class"); # Access the log of the object
$myclass->dummy; # Will log "Dummy log entry"
@@ -89,19 +88,19 @@
$self->log_info("Dummy");
-=head1 USING WITH MOUSE INSTEAD OF MOOSE
+=head1 USING WITH MOO INSTEAD OF MOOSE
-As this module is using LAny::Moose, you can use it with Mouse instead of Moose too.
+As this module is using L<Moo>, you can use it with Moo instead of Moose too.
-This will allow to simple use it as documented above in a Mouse based application, like shown in the example below:
+This will allow to simple use it as documented above in a Moo based application, like shown in the example below:
This is your class consuming the MooseX::Log::Log4perl role.
package MyCat;
- use Mouse;
-
+ use Moo;
+
with 'MooseX::Log::Log4perl';
-
+
sub catch_it {
my $self = shift;
$self->log->debug("Say Miau");
@@ -113,7 +112,7 @@
use MyCat;
use Log::Log4perl qw(:easy);
BEGIN { Log::Log4perl->easy_init() };
-
+
my $log = Log::Log4perl->get_logger();
$log->info("Application startup...");
MyCat->new()->catch_it(); ### Will log "Dummy dodo"
@@ -154,22 +153,20 @@
=head1 SEE ALSO
-LLog::Log4perl, L<Moose>, LMooseX::LogDispatch
+LLog::Log4perl, L<Moose>, L<Moo>, LMooX::Log::Any, LMooX::Role::Logger
=head1 BUGS AND LIMITATIONS
-Please report any bugs or feature requests to
-C, or through the web interface at
-Lhttp://rt.cpan.org.
+Please report any issues at Lhttps://github.com/lammel/moosex-log-log4perl
Or come bother us in C<#moose> on C.
=head1 AUTHOR
-Roland Lammel C<< >>
+Roland Lammel L<< >>
-Inspired by the work by Chris Prather C<< >> and Ash
-Berlin C<< >> on LMooseX::LogDispatch
+Inspired by the work by Chris Prather L<< >> and Ash
+Berlin L<< >> on LMooseX::LogDispatch
=head1 CONTRIBUTORS
@@ -177,16 +174,19 @@
=over 2
-=item Michael Schilli C<< >> for LLog::Log4perl and suggestions in the interface.
+=item * abraxxa for Any::Moose deprectation
+
+=item * Michael Schilli for LLog::Log4perl and interface suggestions
-=item Tim Bunce C<< >> for corrections in the LMooseX::Log::Log4perl::Easy module.
+=item * omega for catgory prefix support
+
+=item * Tim Bunce for corrections in the LMooseX::Log::Log4perl::Easy module.
=back
=head1 LICENSE AND COPYRIGHT
-Copyright (c) 2008-2012, Roland Lammel C<< >>, http://www.quikit.at
+Copyright (c) 2008-2016, Roland Lammel L<< >>, Lhttp://www.quikit.at
This module is free software; you can redistribute it and/or
modify it under the same terms as Perl itself. See L<perlartistic>.
-
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/MooseX-Log-Log4perl-0.46/t/01basic.t new/MooseX-Log-Log4perl-0.47/t/01basic.t
--- old/MooseX-Log-Log4perl-0.46/t/01basic.t 2012-06-27 20:05:33.000000000 +0200
+++ new/MooseX-Log-Log4perl-0.47/t/01basic.t 2015-12-08 19:07:16.000000000 +0100
@@ -23,7 +23,7 @@
{
package BasicLogTest;
- use Moose;
+ use Moo;
with 'MooseX::Log::Log4perl';
sub test_log {
@@ -42,10 +42,10 @@
{
package BasicLogTest;
- use Moose;
+ use Moo;
with 'MooseX::Log::Log4perl';
- has 'foo' => ( is => 'rw', isa => 'Str' );
+ has 'foo' => ( is => 'rw' );
}
{
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/MooseX-Log-Log4perl-0.46/t/02easy.t new/MooseX-Log-Log4perl-0.47/t/02easy.t
--- old/MooseX-Log-Log4perl-0.46/t/02easy.t 2012-06-27 20:05:33.000000000 +0200
+++ new/MooseX-Log-Log4perl-0.47/t/02easy.t 2015-12-08 19:07:16.000000000 +0100
@@ -23,7 +23,7 @@
{
package EasyLogTest;
- use Moose;
+ use Moo;
with 'MooseX::Log::Log4perl::Easy';
sub test_easy {
@@ -35,13 +35,13 @@
$self->log_error('big');
$self->log_fatal('brains');
}
-
+
sub test_log {
my ($self) = @_;
$self->log("SPECIAL")->info('BAZ');
$self->log->debug('foo');
$self->log->error('bar');
-
+
}
}
@@ -92,4 +92,4 @@
$err = '';
untie *STDERR;
-}
\ No newline at end of file
+}
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/MooseX-Log-Log4perl-0.46/t/03inheritance.t new/MooseX-Log-Log4perl-0.47/t/03inheritance.t
--- old/MooseX-Log-Log4perl-0.46/t/03inheritance.t 2012-06-27 20:45:15.000000000 +0200
+++ new/MooseX-Log-Log4perl-0.47/t/03inheritance.t 2015-12-08 19:07:16.000000000 +0100
@@ -21,7 +21,7 @@
{
package Parent;
- use Moose;
+ use Moo;
with 'MooseX::Log::Log4perl';
sub overridden { shift->log->warn('Parent overridden'); }
@@ -31,7 +31,7 @@
{
package Child;
- use Moose;
+ use Moo;
extends 'Parent';
with 'MooseX::Log::Log4perl';
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/MooseX-Log-Log4perl-0.46/t/99bench.t new/MooseX-Log-Log4perl-0.47/t/99bench.t
--- old/MooseX-Log-Log4perl-0.46/t/99bench.t 2012-06-27 20:05:33.000000000 +0200
+++ new/MooseX-Log-Log4perl-0.47/t/99bench.t 2015-12-08 21:27:57.000000000 +0100
@@ -11,6 +11,8 @@
plan skip_all => 'Author test. Set $ENV{TEST_AUTHOR} to run benchmark tests' unless $ENV{TEST_AUTHOR};
plan tests => 6;
+my $benchlimit = 85; # accept 85% performance hit due to method call overhead
+
BEGIN { $tmplogfile = 'mxll4p_benchtest.log'; }
END {
### Remove tmpfile if exists
@@ -29,7 +31,7 @@
{
package BenchMooseXLogLog4perl;
- use Moose;
+ use Moo;
with 'MooseX::Log::Log4perl';
sub testlog { shift->log->info("Just a test for logging"); }
@@ -88,17 +90,17 @@
}
my ($rate_logger, $rate_log);
$rate_logger = 100 * $bench{'MooseX-L4p logger'} / $bench{'Log4perl direct'};
- ok($rate_logger > 95, sprintf("Call rate of ->logger must be above 95%% " .
+ ok($rate_logger >= $benchlimit, sprintf("Call rate of ->logger must be above $benchlimit%% " .
"(%i / %i = %.2f %%) to Log4perl direct", $bench{'MooseX-L4p logger'}, $bench{'Log4perl direct'}, $rate_logger));
$rate_log = 100 * $bench{'MooseX-L4p log'} / $bench{'Log4perl direct'};
- ok($rate_log > 94, sprintf("Call rate of ->log must be above 94%% " .
+ ok($rate_log >= $benchlimit, sprintf("Call rate of ->log must be above $benchlimit%% " .
"(%i / %i = %.2f %%) to Log4perl direct", $bench{'MooseX-L4p logger'}, $bench{'Log4perl direct'}, $rate_log));
$rate_logger = 100 * $bench{'MooseX-L4p logger'} / $bench{'Log4perl method'};
- ok($rate_logger > 95, sprintf("Call rate of ->logger must be above 95%% " .
+ ok($rate_logger >= $benchlimit, sprintf("Call rate of ->logger must be above $benchlimit%% " .
"(%i / %i = %.2f %%) to Log4perl via method", $bench{'MooseX-L4p logger'}, $bench{'Log4perl method'}, $rate_logger));
$rate_log = 100 * $bench{'MooseX-L4p log'} / $bench{'Log4perl method'};
- ok($rate_log > 95, sprintf("Call rate of ->log must be above 95%% " .
+ ok($rate_log >= $benchlimit, sprintf("Call rate of ->log must be above $benchlimit%% " .
"(%i / %i = %.2f %%) to Log4perl via method", $bench{'MooseX-L4p logger'}, $bench{'Log4perl method'}, $rate_log));
}
++++++ cpanspec.yml ++++++
---
#description_paragraphs: 3
#description: |-
# override description from CPAN
#summary: override summary from CPAN
#no_testing: broken upstream
#sources:
# - source1
# - source2
#patches:
# foo.patch: -p1
# bar.patch:
#preamble: |-
# BuildRequires: gcc-c++
#post_prep: |-
# hunspell=`pkg-config --libs hunspell | sed -e 's,-l,,; s, *,,g'`
# sed -i -e "s,hunspell-X,$hunspell," t/00-prereq.t Makefile.PL
#post_build: |-
# rm unused.files
#post_install: |-
# sed on %{name}.files
#license: SUSE-NonFree
#skip_noarch: 1
#custom_build: |-
#./Build build flags=%{?_smp_mflags} --myflag
#custom_test: |-
#startserver && make test
#ignore_requires: Bizarre::Module