Bugzilla – Attachment 76290 Details for
Bug 20972
If ISBN has 10 numbers only the first 9 numbers are used
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Add a test case for this to Ediorder.t
0001-Bug-20972-Added-a-testcase-for-bug-20972.patch (text/plain), 1.29 KB, created by
Colin Campbell
on 2018-06-22 14:15:10 UTC
(
hide
)
Description:
Add a test case for this to Ediorder.t
Filename:
MIME Type:
Creator:
Colin Campbell
Created:
2018-06-22 14:15:10 UTC
Size:
1.29 KB
patch
obsolete
>From db868ca2a0d213be346ca002923f36ad94435fa8 Mon Sep 17 00:00:00 2001 >From: Colin Campbell <colin.campbell@ptfs-europe.com> >Date: Fri, 22 Jun 2018 15:02:01 +0100 >Subject: [PATCH] Bug 20972 Added a testcase for bug 20972 > >Ensure all 10 characters of ISBN are preserved > >And that ISBNs and EANs are correctly identidied in the PIA segment >--- > t/Ediorder.t | 13 ++++++++++++- > 1 file changed, 12 insertions(+), 1 deletion(-) > >diff --git a/t/Ediorder.t b/t/Ediorder.t >index 5332f0c5ae..50926a9127 100755 >--- a/t/Ediorder.t >+++ b/t/Ediorder.t >@@ -3,7 +3,7 @@ use strict; > use warnings; > use FindBin qw( $Bin ); > >-use Test::More tests => 6; >+use Test::More tests => 8; > > BEGIN { use_ok('Koha::Edifact::Order') } > >@@ -54,3 +54,14 @@ $data_to_encode .= '??'; > @segs = Koha::Edifact::Order::imd_segment( $code, $data_to_encode ); > cmp_ok( $segs[1], 'eq', q{IMD+L+010+:::CCCCCCCCCC??'}, > 'IMD segment deals with quoted character at end' ); >+ >+my $isbn = '3540556753'; >+my $ean = '9783540556756'; >+ >+my $seg = Koha::Edifact::Order::additional_product_id($isbn); >+cmp_ok( $seg, 'eq', q{PIA+5+3540556753:IB'}, >+ 'isbn correctly encoded in PIA segment' ); >+ >+$seg = Koha::Edifact::Order::additional_product_id($ean); >+cmp_ok( $seg, 'eq', q{PIA+5+9783540556756:EN'}, >+ 'ean correctly encoded in PIA segment' ); >-- >2.17.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 20972
:
76225
|
76281
|
76290
|
76303
|
76304