Lines 198-207
subtest 'is_going_to_expired' => sub {
Link Here
|
198 |
is( $patron->is_going_to_expired, 0, 'Patron should not be considered going to expire if dateexpiry is not set'); |
198 |
is( $patron->is_going_to_expired, 0, 'Patron should not be considered going to expire if dateexpiry is not set'); |
199 |
$patron->dateexpiry( '0000-00-00' )->store->discard_changes; |
199 |
$patron->dateexpiry( '0000-00-00' )->store->discard_changes; |
200 |
is( $patron->is_going_to_expired, 0, 'Patron should not be considered going to expire if dateexpiry is not 0000-00-00'); |
200 |
is( $patron->is_going_to_expired, 0, 'Patron should not be considered going to expire if dateexpiry is not 0000-00-00'); |
|
|
201 |
|
202 |
t::lib::Mocks::mock_preference('NotifyBorrowerDeparture', 0); |
201 |
$patron->dateexpiry( dt_from_string )->store->discard_changes; |
203 |
$patron->dateexpiry( dt_from_string )->store->discard_changes; |
202 |
is( $patron->is_going_to_expired, 0, 'Patron should not be considered going to expire if dateexpiry is today'); |
204 |
is( $patron->is_going_to_expired, 0, 'Patron should not be considered going to expire if dateexpiry is today'); |
203 |
|
205 |
|
204 |
t::lib::Mocks::mock_preference('NotifyBorrowerDeparture', 0); |
|
|
205 |
$patron->dateexpiry( dt_from_string )->store->discard_changes; |
206 |
$patron->dateexpiry( dt_from_string )->store->discard_changes; |
206 |
is( $patron->is_going_to_expired, 0, 'Patron should not be considered going to expire if dateexpiry is today and pref is 0'); |
207 |
is( $patron->is_going_to_expired, 0, 'Patron should not be considered going to expire if dateexpiry is today and pref is 0'); |
207 |
|
208 |
|
208 |
- |
|
|