Lines 285-291
sub run_tests {
Link Here
|
285 |
is( $data->{ title }, $title, |
285 |
is( $data->{ title }, $title, |
286 |
'ModBiblio correctly added the title field, and GetBiblioData.'); |
286 |
'ModBiblio correctly added the title field, and GetBiblioData.'); |
287 |
is( $data->{ isbn }, $isbn, '(ModBiblio) ISBN is still there after ModBiblio.'); |
287 |
is( $data->{ isbn }, $isbn, '(ModBiblio) ISBN is still there after ModBiblio.'); |
288 |
$marc = $biblio->metadata->record; |
288 |
$marc = $biblio->get_from_storage->metadata->record; |
289 |
my ( $title_field, $title_subfield ) = get_title_field(); |
289 |
my ( $title_field, $title_subfield ) = get_title_field(); |
290 |
is( $marc->subfield( $title_field, $title_subfield ), $title, ); |
290 |
is( $marc->subfield( $title_field, $title_subfield ), $title, ); |
291 |
|
291 |
|
Lines 424-431
sub run_tests {
Link Here
|
424 |
"GetMarcPrice returns the correct value"); |
424 |
"GetMarcPrice returns the correct value"); |
425 |
my $newincbiblioitemnumber=$biblioitemnumber+1; |
425 |
my $newincbiblioitemnumber=$biblioitemnumber+1; |
426 |
$dbh->do("UPDATE biblioitems SET biblioitemnumber = ? WHERE biblionumber = ?;", undef, $newincbiblioitemnumber, $biblionumber ); |
426 |
$dbh->do("UPDATE biblioitems SET biblioitemnumber = ? WHERE biblionumber = ?;", undef, $newincbiblioitemnumber, $biblionumber ); |
427 |
my $updatedrecord = $biblio->metadata->record; |
|
|
428 |
my $frameworkcode = GetFrameworkCode($biblionumber); |
427 |
my $frameworkcode = GetFrameworkCode($biblionumber); |
|
|
428 |
my $updatedrecord = $biblio->metadata->record; |
429 |
C4::Biblio::_koha_marc_update_bib_ids($updatedrecord, $frameworkcode, $biblionumber, $newincbiblioitemnumber); |
429 |
my ( $biblioitem_tag, $biblioitem_subfield ) = GetMarcFromKohaField( "biblioitems.biblioitemnumber" ); |
430 |
my ( $biblioitem_tag, $biblioitem_subfield ) = GetMarcFromKohaField( "biblioitems.biblioitemnumber" ); |
430 |
die qq{No biblioitemnumber tag for framework "$frameworkcode"} unless $biblioitem_tag; |
431 |
die qq{No biblioitemnumber tag for framework "$frameworkcode"} unless $biblioitem_tag; |
431 |
my $biblioitemnumbertotest; |
432 |
my $biblioitemnumbertotest; |
Lines 712-718
subtest 'MarcFieldForCreatorAndModifier' => sub {
Link Here
|
712 |
$c4_context->mock('userenv', sub { return { number => 321, firstname => 'Jane', surname => 'Doe'}; }); |
713 |
$c4_context->mock('userenv', sub { return { number => 321, firstname => 'Jane', surname => 'Doe'}; }); |
713 |
C4::Biblio::ModBiblio($record, $biblionumber, ''); |
714 |
C4::Biblio::ModBiblio($record, $biblionumber, ''); |
714 |
|
715 |
|
715 |
$record = $biblio->metadata->record; |
716 |
$record = $biblio->get_from_storage->metadata->record; |
716 |
is($record->subfield('998', 'a'), 123, '998$a = 123'); |
717 |
is($record->subfield('998', 'a'), 123, '998$a = 123'); |
717 |
is($record->subfield('998', 'b'), 'John Doe', '998$b = John Doe'); |
718 |
is($record->subfield('998', 'b'), 'John Doe', '998$b = John Doe'); |
718 |
is($record->subfield('998', 'c'), 321, '998$c = 321'); |
719 |
is($record->subfield('998', 'c'), 321, '998$c = 321'); |