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

(-)a/t/db_dependent/Koha/SearchEngine/Elasticsearch.t (-2 / +17 lines)
Lines 318-323 subtest 'Koha::SearchEngine::Elasticsearch::marc_records_to_documents () tests' Link Here
318
            marc_type   => 'marc21',
318
            marc_type   => 'marc21',
319
            marc_field  => '245',
319
            marc_field  => '245',
320
        },
320
        },
321
        {
322
            name        => 'title_sort',
323
            type        => 'string',
324
            facet       => 0,
325
            suggestible => 0,
326
            searchable  => 0,
327
            sort        => 1,
328
            marc_type   => 'marc21',
329
            marc_field  => '246a',
330
        },
321
        {
331
        {
322
            name        => 'sum_item_price',
332
            name        => 'sum_item_price',
323
            type        => 'sum',
333
            type        => 'sum',
Lines 475-480 subtest 'Koha::SearchEngine::Elasticsearch::marc_records_to_documents () tests' Link Here
475
        MARC::Field->new( '650', '', '',  a => 'Heading',    z => 'Geohead',    v => 'Formhead' ),
485
        MARC::Field->new( '650', '', '',  a => 'Heading',    z => 'Geohead',    v => 'Formhead' ),
476
        MARC::Field->new( '650', '', '',  a => 'Heading',    x => 'Gensubhead', z => 'Geohead' ),
486
        MARC::Field->new( '650', '', '',  a => 'Heading',    x => 'Gensubhead', z => 'Geohead' ),
477
        MARC::Field->new( '999', '', '',  c => '1234567' ),
487
        MARC::Field->new( '999', '', '',  c => '1234567' ),
488
        MARC::Field->new( '246', '', '', a => '#$[Title!' ),
478
489
479
        # '  ' for testing trimming of white space in boolean value callback:
490
        # '  ' for testing trimming of white space in boolean value callback:
480
        MARC::Field->new( '952', '', '', 0 => '  ', g => '123.30', o => $callno,      l => 3 ),
491
        MARC::Field->new( '952', '', '', 0 => '  ', g => '123.30', o => $callno,      l => 3 ),
Lines 695-703 subtest 'Koha::SearchEngine::Elasticsearch::marc_records_to_documents () tests' Link Here
695
        'First document copydate field should be set correctly'
706
        'First document copydate field should be set correctly'
696
    );
707
    );
697
708
709
    is(
710
        $docs->[0]->{title_sort__sort}[0],
711
        'Title!',
712
        'First document title_sort should have initial non word characters stripped',
713
    );
714
698
    # Second record:
715
    # Second record:
699
716
700
    is( scalar @{ $docs->[1]->{author} }, 1, 'Second document author field should contain one value' );
701
    is_deeply( $docs->[1]->{author}, ['Author 2'], 'Second document author field should be set correctly' );
717
    is_deeply( $docs->[1]->{author}, ['Author 2'], 'Second document author field should be set correctly' );
702
718
703
    is(
719
    is(
704
- 

Return to bug 24720