From fa8b2abfe129777bd28197184fe95eb9b8f93fc9 Mon Sep 17 00:00:00 2001 From: Dobrica Pavlinusic Date: Mon, 12 Nov 2007 11:17:19 +0000 Subject: [PATCH] r1612@llin: dpavlin | 2007-11-12 12:17:17 +0100 fixed debug levels: now tests run with -d will display own diag messages, while -d -d will be 1st level of debug for WebPAC, and so on... git-svn-id: svn+ssh://mjesec/home/dpavlin/svn/webpac2/trunk@1037 07558da8-63fa-0310-ba24-9fe276d99e06 --- lib/WebPAC/Normalize.pm | 3 ++- t/3-normalize-marc.t | 2 ++ 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/lib/WebPAC/Normalize.pm b/lib/WebPAC/Normalize.pm index 084b3ea..e7f7e9b 100644 --- a/lib/WebPAC/Normalize.pm +++ b/lib/WebPAC/Normalize.pm @@ -27,11 +27,11 @@ use strict; #use base qw/WebPAC::Common/; use Data::Dump qw/dump/; -use Storable qw/dclone/; use Carp qw/confess/; # debugging warn(s) my $debug = 0; +_debug( $debug ); # FIXME use WebPAC::Normalize::ISBN; @@ -263,6 +263,7 @@ sub _debug { warn "debug level $l",$/ if ($l > 0); $debug = $l; $WebPAC::Normalize::MARC::debug = $debug; +warn "#### MARC::debug = ",dump($WebPAC::Normalize::MARC::debug); } =head1 Functions to create C diff --git a/t/3-normalize-marc.t b/t/3-normalize-marc.t index 0b7ea6a..825c77f 100755 --- a/t/3-normalize-marc.t +++ b/t/3-normalize-marc.t @@ -11,6 +11,8 @@ BEGIN { use_ok( 'WebPAC::Normalize::MARC' ); } +_debug( $debug - 1 ) if $debug > 1; + my $rec = { '225' => [{ 'a' => 'a-1-1', -- 2.20.1