Bugzilla – Attachment 3835 Details for
Bug 5683
link_bibs_to_authorities.pl can corrupt records
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Follow-up patch (2 of 2)
bug_5683_follow-up-2.patch (text/plain), 1.94 KB, created by
Jared Camins-Esakov
on 2011-04-08 12:05:49 UTC
(
hide
)
Description:
Follow-up patch (2 of 2)
Filename:
MIME Type:
Creator:
Jared Camins-Esakov
Created:
2011-04-08 12:05:49 UTC
Size:
1.94 KB
patch
obsolete
>From 2ad74954e674c0ebfff62a62f0cdb3e8eca3fe89 Mon Sep 17 00:00:00 2001 >From: Jared Camins-Esakov <jcamins@bywatersolutions.com> >Date: Wed, 6 Apr 2011 10:07:29 -0400 >Subject: [PATCH 2/2] Add unit tests to ensure bug 5683 doesn't reappear >Content-Type: text/plain; charset="UTF-8" > > >Signed-off-by: Jared Camins-Esakov <jcamins@bywatersolutions.com> >--- > t/db_dependent/Biblio.t | 36 +++++++++++++++++++++++++++++++++++- > 1 files changed, 35 insertions(+), 1 deletions(-) > >diff --git a/t/db_dependent/Biblio.t b/t/db_dependent/Biblio.t >index 6012f5f..dd827f0 100755 >--- a/t/db_dependent/Biblio.t >+++ b/t/db_dependent/Biblio.t >@@ -5,7 +5,7 @@ > > use strict; > use warnings; >-use Test::More tests => 6; >+use Test::More tests => 9; > use MARC::Record; > use C4::Biblio; > >@@ -34,6 +34,40 @@ my $itemdata = &GetBiblioItemData($biblioitemnumber); > is($itemdata->{title},$title,'First test of GetBiblioItemData to get same result of previous two GetBiblioData tests.'); > is($itemdata->{isbn},$isbn,'Second test checking it returns the correct isbn.'); > >+my $success = 0; >+$field = MARC::Field->new( >+ 655, ' ', ' ', >+ 'a' => 'Auction catalogs', >+ '9' => '1' >+ ); >+eval { >+ $marc_record->append_fields($field); >+ $success = ModBiblio($marc_record,$biblionumber,''); >+} or do { >+ diag($@); >+ $success = 0; >+}; >+ok($success, "ModBiblio handles authority-linked 655"); >+ >+eval { >+ $field->delete_subfields('a'); >+ $marc_record->append_fields($field); >+ $success = ModBiblio($marc_record,$biblionumber,''); >+} or do { >+ diag($@); >+ $success = 0; >+}; >+ok($success, "ModBiblio handles 655 with authority link but no heading"); >+ >+eval { >+ $field->delete_subfields('9'); >+ $marc_record->append_fields($field); >+ $success = ModBiblio($marc_record,$biblionumber,''); >+} or do { >+ diag($@); >+ $success = 0; >+}; >+ok($success, "ModBiblio handles 655 with no subfields"); > > # clean up after ourselves > DelBiblio($biblionumber); >-- >1.7.2.3 >
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 5683
:
3053
|
3834
|
3835
|
4093
|
4094