]> git.evergreen-ils.org Git - Evergreen.git/blob - Open-ILS/src/perlmods/t/16-OpenILS-WWW-AddedContent.t
LP2061136 - Stamping 1405 DB upgrade script
[Evergreen.git] / Open-ILS / src / perlmods / t / 16-OpenILS-WWW-AddedContent.t
1 #!perl -T
2
3 use Test::More tests => 9;
4
5 BEGIN {
6         use_ok( 'OpenILS::WWW::AddedContent' );
7 }
8
9 use_ok( 'OpenILS::WWW::AddedContent::Amazon' );
10 use_ok( 'OpenILS::WWW::AddedContent::ContentCafe' );
11 use_ok( 'OpenILS::WWW::AddedContent::OpenLibrary' );
12 use_ok( 'OpenILS::WWW::AddedContent::Syndetic' );
13
14 my $amazon = OpenILS::WWW::AddedContent::Amazon;
15 is($amazon->normalize_key('9791186178140'), '9791186178140', 'Amazon Added Content can handle 979 ISBNs');
16 is($amazon->normalize_key('9780735220171'), '0735220174', 'Amazon Added Content converts ISBN-13s to ISBN-10s');
17 is($amazon->normalize_key('0735220174'), '0735220174', 'Amazon Added Content leaves ISBN-10s as they are');
18 is($amazon->normalize_key('978-0735220171'), '0735220174', 'Amazon Added Content removes hyphens from ISBNs');