|
Lines 867-873
subtest 'cancellation_requestable_from_opac() tests' => sub {
Link Here
|
| 867 |
|
867 |
|
| 868 |
subtest 'cancel() tests' => sub { |
868 |
subtest 'cancel() tests' => sub { |
| 869 |
|
869 |
|
| 870 |
plan tests => 12; |
870 |
plan tests => 11; |
| 871 |
|
871 |
|
| 872 |
$schema->storage->txn_begin; |
872 |
$schema->storage->txn_begin; |
| 873 |
|
873 |
|
|
Lines 947-954
subtest 'cancel() tests' => sub {
Link Here
|
| 947 |
|
947 |
|
| 948 |
$get_prepared_letter_called = 0; |
948 |
$get_prepared_letter_called = 0; |
| 949 |
$hold->cancel({ notify_patron => 1 }); |
949 |
$hold->cancel({ notify_patron => 1 }); |
| 950 |
is( $get_prepared_letter_called, 0, 'GetPreparedLetter not called if notify_patron passed and no cancellation_reason passed' ); |
|
|
| 951 |
|
| 952 |
isnt( $hold->cancellationdate, undef, 'cancellationdate gets set to the passed value' ); |
950 |
isnt( $hold->cancellationdate, undef, 'cancellationdate gets set to the passed value' ); |
| 953 |
is( $hold->priority, 0, 'priority gets set to 0' ); |
951 |
is( $hold->priority, 0, 'priority gets set to 0' ); |
| 954 |
is( $hold->cancellation_reason, undef, 'cancellation_reason not passed' ); |
952 |
is( $hold->cancellation_reason, undef, 'cancellation_reason not passed' ); |
| 955 |
- |
|
|