View | Details | Raw Unified | Return to bug 18104
Collapse All | Expand All

(-)a/t/db_dependent/SIP/Message.t (-2 / +10 lines)
Lines 70-76 subtest 'Testing Patron Status Request V2' => sub { Link Here
70
70
71
subtest 'Testing Patron Info Request V2' => sub {
71
subtest 'Testing Patron Info Request V2' => sub {
72
    $schema->storage->txn_begin;
72
    $schema->storage->txn_begin;
73
    plan tests => 16;
73
    plan tests => 17;
74
    $C4::SIP::Sip::protocol_version = 2;
74
    $C4::SIP::Sip::protocol_version = 2;
75
    test_request_patron_info_v2();
75
    test_request_patron_info_v2();
76
    $schema->storage->txn_rollback;
76
    $schema->storage->txn_rollback;
Lines 186-191 sub test_request_patron_info_v2 { Link Here
186
    # No check for custom fields here (unofficial PB, PC and PI)
186
    # No check for custom fields here (unofficial PB, PC and PI)
187
    check_field( $respcode, $response, FID_SCREEN_MSG, '.+', 'We have a screen msg', 'regex' );
187
    check_field( $respcode, $response, FID_SCREEN_MSG, '.+', 'We have a screen msg', 'regex' );
188
188
189
    # Test customized patron name in AE with same sip request
190
    # This implicitly tests C4::SIP::ILS::Patron->name
191
    $server->{account}->{ae_field_template} = "X[% patron.surname %]Y";
192
    $msg = C4::SIP::Sip::MsgType->new( $siprequest, 0 );
193
    undef $response;
194
    $msg->handle_patron_info( $server );
195
    $respcode = substr( $response, 0, 2 );
196
    check_field( $respcode, $response, FID_PERSONAL_NAME, 'X' . $patron2->{surname} . 'Y', 'Check customized patron name' );
197
189
    # Check empty password and verify CQ again
198
    # Check empty password and verify CQ again
190
    $siprequest = PATRON_INFO. 'engYYYYMMDDZZZZHHMMSS'.'Y         '.
199
    $siprequest = PATRON_INFO. 'engYYYYMMDDZZZZHHMMSS'.'Y         '.
191
        FID_INST_ID. $branchcode. '|'.
200
        FID_INST_ID. $branchcode. '|'.
192
- 

Return to bug 18104