Lines 72-78
is( $ils->test_cardnumber_compare( 'A1234', 'b1234' ),
Link Here
|
72 |
q{}, 'borrower bc test identifies difference' ); |
72 |
q{}, 'borrower bc test identifies difference' ); |
73 |
|
73 |
|
74 |
subtest cancel_hold => sub { |
74 |
subtest cancel_hold => sub { |
75 |
plan tests => 5; |
75 |
plan tests => 6; |
76 |
|
76 |
|
77 |
my $library = $builder->build_object ({ class => 'Koha::Libraries' }); |
77 |
my $library = $builder->build_object ({ class => 'Koha::Libraries' }); |
78 |
my $patron = $builder->build_object( |
78 |
my $patron = $builder->build_object( |
Lines 117-124
subtest cancel_hold => sub {
Link Here
|
117 |
|
117 |
|
118 |
my $ils = C4::SIP::ILS->new({ id => $library->branchcode }); |
118 |
my $ils = C4::SIP::ILS->new({ id => $library->branchcode }); |
119 |
my $sip_patron = C4::SIP::ILS::Patron->new( $patron->cardnumber ); |
119 |
my $sip_patron = C4::SIP::ILS::Patron->new( $patron->cardnumber ); |
120 |
my $transaction = $ils->cancel_hold($patron->cardnumber,undef,$item->barcode,undef); |
120 |
my $transaction = $ils->cancel_hold($patron->cardnumber,"",$item->barcode,undef); |
121 |
|
121 |
|
|
|
122 |
isnt( $transaction->{screen_msg}, 'Invalid patron password.', "Empty password succeeds" ); |
122 |
is( $transaction->{screen_msg},"Hold Cancelled.","We get a success message when hold cancelled"); |
123 |
is( $transaction->{screen_msg},"Hold Cancelled.","We get a success message when hold cancelled"); |
123 |
|
124 |
|
124 |
is( $item->biblio->holds->count(), 0, "Bib has 0 holds remaining"); |
125 |
is( $item->biblio->holds->count(), 0, "Bib has 0 holds remaining"); |
125 |
- |
|
|