Lines 199-205
subtest "Test build_additional_item_fields_string" => sub {
Link Here
|
199 |
}; |
199 |
}; |
200 |
|
200 |
|
201 |
subtest "Test cr_item_field" => sub { |
201 |
subtest "Test cr_item_field" => sub { |
202 |
plan tests => 1; |
202 |
plan tests => 2; |
203 |
|
203 |
|
204 |
my $builder = t::lib::TestBuilder->new(); |
204 |
my $builder = t::lib::TestBuilder->new(); |
205 |
my $branchcode = $builder->build({ source => 'Branch' })->{branchcode}; |
205 |
my $branchcode = $builder->build({ source => 'Branch' })->{branchcode}; |
Lines 253-258
subtest "Test cr_item_field" => sub {
Link Here
|
253 |
|
253 |
|
254 |
my $id = $item_object->id; |
254 |
my $id = $item_object->id; |
255 |
ok( $response =~ m/CR$id/, "Found correct CR field in response"); |
255 |
ok( $response =~ m/CR$id/, "Found correct CR field in response"); |
|
|
256 |
|
257 |
$siprequest = ITEM_INFORMATION . 'YYYYMMDDZZZZHHMMSS' . |
258 |
FID_INST_ID . $branchcode . '|'. |
259 |
FID_ITEM_ID . $item_object->barcode . '|' . |
260 |
FID_TERMINAL_PWD . 'ignored' . '|'; |
261 |
undef $response; |
262 |
$msg = C4::SIP::Sip::MsgType->new( $siprequest, 0 ); |
263 |
|
264 |
$mockILS->mock( 'find_item', sub { |
265 |
return C4::SIP::ILS::Item->new( $item_object->barcode ); |
266 |
}); |
267 |
|
268 |
$server->{account}->{cr_item_field} = 'itype'; |
269 |
|
270 |
$msg->handle_item_information( $server ); |
271 |
|
272 |
my $itype = $item_object->itype; |
273 |
ok( $response =~ m/CR$itype/, "Found correct CR field in response"); |
256 |
}; |
274 |
}; |
257 |
|
275 |
|
258 |
subtest 'Patron info summary > 5 should not crash server' => sub { |
276 |
subtest 'Patron info summary > 5 should not crash server' => sub { |
259 |
- |
|
|