Bug 24200: (follow-up) Try to fix random failures from Borrower_PrevCheckout.t

2 other occurrences where missing.

Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>

Signed-off-by: Joy Nelson <joy@bywatersolutions.com>
This commit is contained in:
Jonathan Druart 2020-03-18 13:43:52 +01:00 committed by Joy Nelson
parent d5e9dc31ca
commit d4db0b96e8
1 changed files with 2 additions and 18 deletions

View File

@ -377,24 +377,8 @@ my $CBBI_patron = $builder->build({source => 'Borrower', value => { categorycode
$patron = Koha::Patrons->find( $CBBI_patron->{borrowernumber} );
# Our Items
my $new_item = $builder->build({
source => 'Item',
value => {
notforloan => 0,
withdrawn => 0,
itemlost => 0,
biblionumber => $builder->build( { source => 'Biblioitem' } )->{biblionumber},
},
});
my $prev_item = $builder->build({
source => 'Item',
value => {
notforloan => 0,
withdrawn => 0,
itemlost => 0,
biblionumber => $builder->build( { source => 'Biblioitem' } )->{biblionumber},
},
});
my $new_item = $builder->build_sample_item->unblessed;
my $prev_item = $builder->build_sample_item->unblessed;
# Second is Checked Out
BAIL_OUT("CanBookBeIssued Issue failed")
unless AddIssue($patron->unblessed, $prev_item->{barcode});