Bugzilla – Attachment 33147 Details for
Bug 11395
Batch modifications for records
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 11395: Fix return for ModifyRecordWithTemplate
Bug-11395-Fix-return-for-ModifyRecordWithTemplate.patch (text/plain), 1.85 KB, created by
Jonathan Druart
on 2014-11-03 14:09:48 UTC
(
hide
)
Description:
Bug 11395: Fix return for ModifyRecordWithTemplate
Filename:
MIME Type:
Creator:
Jonathan Druart
Created:
2014-11-03 14:09:48 UTC
Size:
1.85 KB
patch
obsolete
>From b722d303ea299beacf4f27d1da450f3436ef0c33 Mon Sep 17 00:00:00 2001 >From: Jonathan Druart <jonathan.druart@biblibre.com> >Date: Thu, 12 Dec 2013 21:14:24 +0100 >Subject: [PATCH] Bug 11395: Fix return for ModifyRecordWithTemplate > >Make sure the ModifyRecordWithTemplate routine returns undef. > >This patch also removes a warning if GetModificationTemplates is called >without parameter. > >Verify > prove t/db_dependent/MarcModificationTemplates.t >returns green. > >Signed-off-by: Brendan Gallagher <brendan@bywatersolutions.com> >--- > C4/MarcModificationTemplates.pm | 2 ++ > t/db_dependent/MarcModificationTemplates.t | 6 ++---- > 2 files changed, 4 insertions(+), 4 deletions(-) > >diff --git a/C4/MarcModificationTemplates.pm b/C4/MarcModificationTemplates.pm >index 3465f5c..f0cccda 100644 >--- a/C4/MarcModificationTemplates.pm >+++ b/C4/MarcModificationTemplates.pm >@@ -626,6 +626,8 @@ sub ModifyRecordWithTemplate { > > warn( $record->as_formatted() ) if DEBUG >= 10; > } >+ >+ return; > } > 1; > __END__ >diff --git a/t/db_dependent/MarcModificationTemplates.t b/t/db_dependent/MarcModificationTemplates.t >index c41b76a..e8bfcbc 100644 >--- a/t/db_dependent/MarcModificationTemplates.t >+++ b/t/db_dependent/MarcModificationTemplates.t >@@ -1,6 +1,6 @@ > use Modern::Perl; > >-use Test::More tests => 77; >+use Test::More tests => 78; > > use_ok("MARC::Field"); > use_ok("MARC::Record"); >@@ -208,13 +208,11 @@ is( AddModificationTemplateAction( > > my $record = new_record(); > >-ModifyRecordWithTemplate( $template_id, $record ); >+is( ModifyRecordWithTemplate( $template_id, $record ), undef, "The ModifyRecordWithTemplate returns undef" ); > > my $expected_record = expected_record(); > is_deeply( $record, $expected_record, "Record modification as expected"); > >-done_testing; >- > sub new_record { > my $record = MARC::Record->new; > $record->leader('03174nam a2200445 a 4500'); >-- >2.1.0
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
|
Splinter Review
Attachments on
bug 11395
:
23502
|
23503
|
23504
|
23505
|
23506
|
23507
|
23508
|
23592
|
24634
|
26072
|
26981
|
28978
|
28999
|
29000
|
29001
|
29002
|
29003
|
29004
|
29056
|
29509
|
29569
|
31344
|
32181
|
32182
|
32184
|
32239
|
32240
|
32241
|
32242
|
32243
|
32244
|
32245
|
32246
|
32247
|
32248
|
32249
|
33145
|
33146
|
33147
|
33148
|
33149
|
33150
|
33151
|
33152
|
33153
|
33154
|
33155
|
34393
|
34394
|
34395
|
34396
|
34397
|
34398
|
34399
|
34400
|
34401
|
34402
|
34552
|
34553
|
34554
|
34555
|
34556
|
34557
|
34558
|
34559
|
34560
|
34561
|
34562
|
35783
|
35784
|
35785
|
35786
|
35787
|
35788
|
35789
|
35790
|
35791
|
35792
|
36295
|
36296
|
36297
|
36298
|
36299
|
36300
|
36301
|
36302
|
36303
|
36304