Browse Source

Bug 27907: Add unit test

Signed-off-by: Christopher Kellermeyer - Altadena Library District <ckellermeyer@altadenalibrary.org>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
master
Kyle Hall 7 months ago
committed by Jonathan Druart
parent
commit
2e613fa7bc
  1. 11
      t/db_dependent/SIP/Transaction.t

11
t/db_dependent/SIP/Transaction.t

@ -525,7 +525,7 @@ subtest checkin_withdrawn => sub {
};
subtest item_circulation_status => sub {
plan tests => 5;
plan tests => 6;
my $library = $builder->build_object( { class => 'Koha::Libraries' } );
my $library2 = $builder->build_object( { class => 'Koha::Libraries' } );
@ -583,9 +583,18 @@ subtest item_circulation_status => sub {
is( $status, '12', "Item circulation status is lost" );
$item->itemlost(0)->store();
my $location = $item->location;
$item->location("CART")->store();
$sip_item = C4::SIP::ILS::Item->new( $item->barcode );
$status = $sip_item->sip_circulation_status;
is( $status, '09', "Item circulation status is waiting to be re-shelved" );
$item->location($location)->store();
my $nfl = $item->notforloan;
$item->notforloan(-1)->store();
$sip_item = C4::SIP::ILS::Item->new( $item->barcode );
$status = $sip_item->sip_circulation_status;
is( $status, '02', "Item circulation status is on order" );
$item->notforloan($nfl)->store();
};
$schema->storage->txn_rollback;

Loading…
Cancel
Save