Bugzilla – Attachment 28777 Details for
Bug 12343
TransformKohaToMarc() is adding MARC subfields in random order
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 12343: Add regression test for TransformKohaToMarc
Bug-12343-Add-regression-test-for-TransformKohaToM.patch (text/plain), 1.44 KB, created by
Jonathan Druart
on 2014-06-11 11:37:42 UTC
(
hide
)
Description:
Bug 12343: Add regression test for TransformKohaToMarc
Filename:
MIME Type:
Creator:
Jonathan Druart
Created:
2014-06-11 11:37:42 UTC
Size:
1.44 KB
patch
obsolete
>From e79499f453d27cc767222a0aaf93b345f043bfb9 Mon Sep 17 00:00:00 2001 >From: Jonathan Druart <jonathan.druart@biblibre.com> >Date: Wed, 11 Jun 2014 13:31:55 +0200 >Subject: [PATCH] Bug 12343: Add regression test for TransformKohaToMarc > >Signed-off-by: Jonathan Druart <jonathan.druart@biblibre.com> >--- > t/Biblio/TransformKohaToMarc.t | 31 +++++++++++++++++++++++++++++++ > 1 file changed, 31 insertions(+) > create mode 100644 t/Biblio/TransformKohaToMarc.t > >diff --git a/t/Biblio/TransformKohaToMarc.t b/t/Biblio/TransformKohaToMarc.t >new file mode 100644 >index 0000000..15eb71a >--- /dev/null >+++ b/t/Biblio/TransformKohaToMarc.t >@@ -0,0 +1,31 @@ >+use Modern::Perl; >+use Test::More tests => 1; >+use MARC::Record; >+ >+use t::lib::Mocks; >+use C4::Biblio; >+ >+t::lib::Mocks::mock_preference('marcflavour', 'MARC21'); >+ >+my $record = C4::Biblio::TransformKohaToMarc({ >+ "biblioitems.illus" => "Other physical details", # 300$b >+ "biblioitems.pages" => "Extent", # 300$a >+ "biblioitems.size" => "Dimensions", # 300$c >+}); >+ >+my @subfields = $record->field('300')->subfields(); >+is_deeply( \@subfields, [ >+ [ >+ 'a', >+ 'Extent' >+ ], >+ [ >+ 'b', >+ 'Other physical details' >+ ], >+ [ >+ 'c', >+ 'Dimensions' >+ ] >+ ], >+'TransformKohaToMarc should returns sorted subfields (regression test for bug 12343)' ); >-- >2.0.0.rc2
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 12343
:
28631
|
28719
|
28776
| 28777 |
28778