Lines 1697-1705
subtest 'item_groups() tests' => sub {
Link Here
|
1697 |
$schema->storage->txn_rollback; |
1697 |
$schema->storage->txn_rollback; |
1698 |
}; |
1698 |
}; |
1699 |
|
1699 |
|
1700 |
subtest 'normalized_isbn' => sub { |
1700 |
subtest 'normalized_isbn() tests' => sub { |
|
|
1701 |
|
1701 |
plan tests => 1; |
1702 |
plan tests => 1; |
1702 |
|
1703 |
|
|
|
1704 |
$schema->storage->txn_begin; |
1705 |
|
1703 |
# We will move the tests from GetNormalizedISBN here when it will get replaced |
1706 |
# We will move the tests from GetNormalizedISBN here when it will get replaced |
1704 |
my $biblio = $builder->build_sample_biblio(); |
1707 |
my $biblio = $builder->build_sample_biblio(); |
1705 |
$biblio->biblioitem->set( { isbn => '9781250067128 | 125006712X' } )->store; |
1708 |
$biblio->biblioitem->set( { isbn => '9781250067128 | 125006712X' } )->store; |
Lines 1707-1717
subtest 'normalized_isbn' => sub {
Link Here
|
1707 |
$biblio->normalized_isbn, C4::Koha::GetNormalizedISBN( $biblio->biblioitem->isbn ), |
1710 |
$biblio->normalized_isbn, C4::Koha::GetNormalizedISBN( $biblio->biblioitem->isbn ), |
1708 |
'normalized_isbn is a wrapper around C4::Koha::GetNormalizedISBN' |
1711 |
'normalized_isbn is a wrapper around C4::Koha::GetNormalizedISBN' |
1709 |
); |
1712 |
); |
|
|
1713 |
|
1714 |
$schema->storage->txn_rollback; |
1710 |
}; |
1715 |
}; |
1711 |
|
1716 |
|
1712 |
subtest 'normalized_upc' => sub { |
1717 |
subtest 'normalized_upc() tests' => sub { |
|
|
1718 |
|
1713 |
plan tests => 1; |
1719 |
plan tests => 1; |
1714 |
|
1720 |
|
|
|
1721 |
$schema->storage->txn_begin; |
1722 |
|
1715 |
# We will move the tests from GetNormalizedUPC here when it will get replaced |
1723 |
# We will move the tests from GetNormalizedUPC here when it will get replaced |
1716 |
# Note that only a single test exist and it's not really meaningful... |
1724 |
# Note that only a single test exist and it's not really meaningful... |
1717 |
my $biblio = $builder->build_sample_biblio(); |
1725 |
my $biblio = $builder->build_sample_biblio(); |
Lines 1719-1729
subtest 'normalized_upc' => sub {
Link Here
|
1719 |
$biblio->normalized_upc, C4::Koha::GetNormalizedUPC( $biblio->metadata->record ), |
1727 |
$biblio->normalized_upc, C4::Koha::GetNormalizedUPC( $biblio->metadata->record ), |
1720 |
'normalized_upc is a wrapper around C4::Koha::GetNormalizedUPC' |
1728 |
'normalized_upc is a wrapper around C4::Koha::GetNormalizedUPC' |
1721 |
); |
1729 |
); |
|
|
1730 |
|
1731 |
$schema->storage->txn_rollback; |
1722 |
}; |
1732 |
}; |
1723 |
|
1733 |
|
1724 |
subtest 'normalized_oclc' => sub { |
1734 |
subtest 'normalized_oclc() tests' => sub { |
|
|
1735 |
|
1725 |
plan tests => 1; |
1736 |
plan tests => 1; |
1726 |
|
1737 |
|
|
|
1738 |
$schema->storage->txn_begin; |
1739 |
|
1727 |
# We will move the tests from GetNormalizedOCLC here when it will get replaced |
1740 |
# We will move the tests from GetNormalizedOCLC here when it will get replaced |
1728 |
# Note that only a single test exist and it's not really meaningful... |
1741 |
# Note that only a single test exist and it's not really meaningful... |
1729 |
my $biblio = $builder->build_sample_biblio(); |
1742 |
my $biblio = $builder->build_sample_biblio(); |
Lines 1731-1736
subtest 'normalized_oclc' => sub {
Link Here
|
1731 |
$biblio->normalized_oclc, C4::Koha::GetNormalizedOCLCNumber( $biblio->metadata->record ), |
1744 |
$biblio->normalized_oclc, C4::Koha::GetNormalizedOCLCNumber( $biblio->metadata->record ), |
1732 |
'normalized_oclc is a wrapper around C4::Koha::GetNormalizedOCLCNumber' |
1745 |
'normalized_oclc is a wrapper around C4::Koha::GetNormalizedOCLCNumber' |
1733 |
); |
1746 |
); |
|
|
1747 |
|
1748 |
$schema->storage->txn_rollback; |
1734 |
}; |
1749 |
}; |
1735 |
|
1750 |
|
1736 |
subtest 'opac_suppressed() tests' => sub { |
1751 |
subtest 'opac_suppressed() tests' => sub { |
Lines 1781-1786
subtest 'opac_summary_html' => sub {
Link Here
|
1781 |
|
1796 |
|
1782 |
plan tests => 2; |
1797 |
plan tests => 2; |
1783 |
|
1798 |
|
|
|
1799 |
$schema->storage->txn_begin; |
1800 |
|
1784 |
my $author = 'my author'; |
1801 |
my $author = 'my author'; |
1785 |
my $title = 'my title'; |
1802 |
my $title = 'my title'; |
1786 |
my $isbn = '9781250067128 | 125006712X'; |
1803 |
my $isbn = '9781250067128 | 125006712X'; |
Lines 1799-1804
subtest 'opac_summary_html' => sub {
Link Here
|
1799 |
sprintf( 'Replace %s, %s, %s AND %s please', $author, $title, $biblio->normalized_isbn, $biblio->biblionumber ), |
1816 |
sprintf( 'Replace %s, %s, %s AND %s please', $author, $title, $biblio->normalized_isbn, $biblio->biblionumber ), |
1800 |
'opac_summary_html replaces the different patterns' |
1817 |
'opac_summary_html replaces the different patterns' |
1801 |
); |
1818 |
); |
|
|
1819 |
|
1820 |
$schema->storage->txn_rollback; |
1802 |
}; |
1821 |
}; |
1803 |
|
1822 |
|
1804 |
subtest 'can_be_edited() tests' => sub { |
1823 |
subtest 'can_be_edited() tests' => sub { |
1805 |
- |
|
|