View | Details | Raw Unified | Return to bug 20499
Collapse All | Expand All

(-)a/t/db_dependent/Circulation.t (-2 / +5 lines)
Lines 1193-1199 C4::Context->dbh->do("DELETE FROM accountlines"); Link Here
1193
}
1193
}
1194
1194
1195
subtest 'CanBookBeIssued & AllowReturnToBranch' => sub {
1195
subtest 'CanBookBeIssued & AllowReturnToBranch' => sub {
1196
    plan tests => 23;
1196
    plan tests => 24;
1197
1197
1198
    my $homebranch    = $builder->build( { source => 'Branch' } );
1198
    my $homebranch    = $builder->build( { source => 'Branch' } );
1199
    my $holdingbranch = $builder->build( { source => 'Branch' } );
1199
    my $holdingbranch = $builder->build( { source => 'Branch' } );
Lines 1225-1230 subtest 'CanBookBeIssued & AllowReturnToBranch' => sub { Link Here
1225
1225
1226
    # AllowReturnToBranch == anywhere
1226
    # AllowReturnToBranch == anywhere
1227
    t::lib::Mocks::mock_preference( 'AllowReturnToBranch', 'anywhere' );
1227
    t::lib::Mocks::mock_preference( 'AllowReturnToBranch', 'anywhere' );
1228
    ## Test that unknown barcodes don't generate internal server errors
1229
    set_userenv($homebranch);
1230
    ( $error, $question, $alerts ) = CanBookBeIssued( $patron_2, 'KohaIsAwesome' );
1231
    ok( $error->{UNKNOWN_BARCODE}, '"KohaIsAwesome" is not a valid barcode as expected.' );
1228
    ## Can be issued from homebranch
1232
    ## Can be issued from homebranch
1229
    set_userenv($homebranch);
1233
    set_userenv($homebranch);
1230
    ( $error, $question, $alerts ) = CanBookBeIssued( $patron_2, $item->{barcode} );
1234
    ( $error, $question, $alerts ) = CanBookBeIssued( $patron_2, $item->{barcode} );
1231
- 

Return to bug 20499