Lines 92-106
C4::Context->set_userenv($patron->{borrowernumber}, $patron->{userid}, 'usercnum
Link Here
|
92 |
|
92 |
|
93 |
subtest 'no rules exist' => sub { |
93 |
subtest 'no rules exist' => sub { |
94 |
plan tests => 2; |
94 |
plan tests => 2; |
95 |
is( |
95 |
is_deeply( |
96 |
C4::Circulation::TooMany( $patron, $biblio->{biblionumber}, $item ), |
96 |
C4::Circulation::TooMany( $patron, $biblio->{biblionumber}, $item ), |
97 |
undef, |
97 |
{ reason => 'NO_RULE_DEFINED', max_allowed => 0 }, |
98 |
'CO should be allowed, in any cases' |
98 |
'CO should not be allowed, in any cases' |
99 |
); |
99 |
); |
100 |
is( |
100 |
is_deeply( |
101 |
C4::Circulation::TooMany( $patron, $biblio->{biblionumber}, $item, { onsite_checkout => 1 } ), |
101 |
C4::Circulation::TooMany( $patron, $biblio->{biblionumber}, $item, { onsite_checkout => 1 } ), |
102 |
undef, |
102 |
{ reason => 'NO_RULE_DEFINED', max_allowed => 0 }, |
103 |
'OSCO should be allowed, in any cases' |
103 |
'OSCO should not be allowed, in any cases' |
104 |
); |
104 |
); |
105 |
}; |
105 |
}; |
106 |
|
106 |
|
107 |
- |
|
|