Bugzilla – Attachment 30304 Details for
Bug 12674
GetMarcISSN should not return empty ISSN
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 12674: (regression tests) GetMarcISSN should not return empty ISSN
Bug-12674-regression-tests-GetMarcISSN-should-not-.patch (text/plain), 1.55 KB, created by
Tomás Cohen Arazi (tcohen)
on 2014-07-29 19:16:21 UTC
(
hide
)
Description:
Bug 12674: (regression tests) GetMarcISSN should not return empty ISSN
Filename:
MIME Type:
Creator:
Tomás Cohen Arazi (tcohen)
Created:
2014-07-29 19:16:21 UTC
Size:
1.55 KB
patch
obsolete
>From 5a4dcb57a8cd5d25b0d5c1f43eb129d8fd1ad070 Mon Sep 17 00:00:00 2001 >From: Tomas Cohen Arazi <tomascohen@gmail.com> >Date: Tue, 29 Jul 2014 16:09:18 -0300 >Subject: [PATCH] Bug 12674: (regression tests) GetMarcISSN should not return > empty ISSN > >Proves GetMarcISSN returns empty ISSNs in the results array. > >To reproduce: > - Run $ prove -v t/db_dependent/Biblio.t >--- > t/db_dependent/Biblio.t | 12 +++++++++--- > 1 file changed, 9 insertions(+), 3 deletions(-) > >diff --git a/t/db_dependent/Biblio.t b/t/db_dependent/Biblio.t >index 137946e..6657f4d 100755 >--- a/t/db_dependent/Biblio.t >+++ b/t/db_dependent/Biblio.t >@@ -137,6 +137,12 @@ sub run_tests { > $issns = GetMarcISSN( $marc_record, $marcflavour ); > is( scalar @$issns, 4, > 'GetMARCISSN handles records with multiple ISSN fields (count correct)'); >+ # Create an empty ISSN >+ $field = create_issn_field( "", $marcflavour ); >+ $marc_record->append_fields($field); >+ $issns = GetMarcISSN( $marc_record, $marcflavour ); >+ is( scalar @$issns, 4, >+ 'GetMARCISSN skips empty ISSN fields (Bug 12674)'); > > ## Testing GetMarcControlnumber > my $controlnumber; >@@ -246,19 +252,19 @@ sub create_issn_field { > } > > subtest 'MARC21' => sub { >- plan tests => 26; >+ plan tests => 27; > run_tests('MARC21'); > $dbh->rollback; > }; > > subtest 'UNIMARC' => sub { >- plan tests => 26; >+ plan tests => 27; > run_tests('UNIMARC'); > $dbh->rollback; > }; > > subtest 'NORMARC' => sub { >- plan tests => 26; >+ plan tests => 27; > run_tests('NORMARC'); > $dbh->rollback; > }; >-- >1.9.1
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 12674
:
30304
|
30305
|
31284
|
31285
|
31287
|
31288