Lines 25-31
use Module::Load::Conditional qw/check_install/;
Link Here
|
25 |
|
25 |
|
26 |
BEGIN { |
26 |
BEGIN { |
27 |
if ( check_install( module => 'Test::DBIx::Class' ) ) { |
27 |
if ( check_install( module => 'Test::DBIx::Class' ) ) { |
28 |
plan tests => 36; |
28 |
plan tests => 37; |
29 |
} else { |
29 |
} else { |
30 |
plan skip_all => "Need Test::DBIx::Class" |
30 |
plan skip_all => "Need Test::DBIx::Class" |
31 |
} |
31 |
} |
Lines 119-125
is( C4::Koha::GetNormalizedISBN('9781250075345 (hardcover) | 1250075343 (hardcov
Link Here
|
119 |
is( C4::Koha::GetNormalizedISBN('9781250067128 | 125006712X'), '125006712X', 'Test GetNormalizedISBN' ); |
119 |
is( C4::Koha::GetNormalizedISBN('9781250067128 | 125006712X'), '125006712X', 'Test GetNormalizedISBN' ); |
120 |
is( C4::Koha::GetNormalizedISBN('9780373211463 | 0373211465'), '0373211465', 'Test GetNormalizedISBN' ); |
120 |
is( C4::Koha::GetNormalizedISBN('9780373211463 | 0373211465'), '0373211465', 'Test GetNormalizedISBN' ); |
121 |
|
121 |
|
122 |
<<<<<<< HEAD |
|
|
123 |
is( C4::Koha::GetNormalizedUPC(), undef, 'GetNormalizedUPC should return undef if no record is passed' ); |
122 |
is( C4::Koha::GetNormalizedUPC(), undef, 'GetNormalizedUPC should return undef if no record is passed' ); |
124 |
is( C4::Koha::GetNormalizedISBN(), undef, 'GetNormalizedISBN should return undef if no record and no isbn are passed' ); |
123 |
is( C4::Koha::GetNormalizedISBN(), undef, 'GetNormalizedISBN should return undef if no record and no isbn are passed' ); |
125 |
is( C4::Koha::GetNormalizedEAN(), undef, 'GetNormalizedEAN should return undef if no record and no isbn are passed' ); |
124 |
is( C4::Koha::GetNormalizedEAN(), undef, 'GetNormalizedEAN should return undef if no record and no isbn are passed' ); |
Lines 150-156
subtest 'getFacets() tests' => sub {
Link Here
|
150 |
'location facet present with singleBranchMode off (bug 10078)' |
149 |
'location facet present with singleBranchMode off (bug 10078)' |
151 |
); |
150 |
); |
152 |
}; |
151 |
}; |
153 |
======= |
|
|
154 |
|
152 |
|
155 |
is(C4::Koha::NormalizeISSN({ issn => '0024-9319', strip_hyphen => 1 }), '00249319', 'Test NormalizeISSN with all features enabled' ); |
153 |
is(C4::Koha::NormalizeISSN({ issn => '0024-9319', strip_hyphen => 1 }), '00249319', 'Test NormalizeISSN with all features enabled' ); |
156 |
is(C4::Koha::NormalizeISSN({ issn => '0024-9319', strip_hyphen => 0 }), '0024-9319', 'Test NormalizeISSN with all features enabled' ); |
154 |
is(C4::Koha::NormalizeISSN({ issn => '0024-9319', strip_hyphen => 0 }), '0024-9319', 'Test NormalizeISSN with all features enabled' ); |
Lines 166-172
eval {
Link Here
|
166 |
ok($@ eq '', 'NormalizeISSN does not throw exception when parsing invalid ISSN'); |
164 |
ok($@ eq '', 'NormalizeISSN does not throw exception when parsing invalid ISSN'); |
167 |
|
165 |
|
168 |
@issns = GetVariationsOfISSNs('abc'); |
166 |
@issns = GetVariationsOfISSNs('abc'); |
169 |
is(scalar(@issns), 0, 'zero variations returned of invalid ISSN'); |
167 |
is($issns[0], 'abc', 'Original ISSN passed through even if invalid'); |
170 |
>>>>>>> Bug 14629 - Add aggressive ISSN matching feature equivalent to the aggressive ISBN matcher |
168 |
is(scalar(@issns), 1, 'zero additional variations returned of invalid ISSN'); |
171 |
|
169 |
|
172 |
1; |
170 |
1; |
173 |
- |
|
|