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

(-)a/t/db_dependent/Koha_Elasticsearch.t (-8 / +4 lines)
Lines 28-36 use Koha::SearchEngine::Elasticsearch; Link Here
28
my $schema = Koha::Database->schema;
28
my $schema = Koha::Database->schema;
29
my $builder = t::lib::TestBuilder->new;
29
my $builder = t::lib::TestBuilder->new;
30
30
31
subtest 'get_facetable_fields() tests' => sub {
31
subtest 'get_facet_fields() tests' => sub {
32
32
33
    plan tests => 15;
33
    plan tests => 13;
34
34
35
    $schema->storage->txn_begin;
35
    $schema->storage->txn_begin;
36
36
Lines 109-116 subtest 'get_facetable_fields() tests' => sub { Link Here
109
        }
109
        }
110
    });
110
    });
111
111
112
    my @faceted_fields = Koha::SearchEngine::Elasticsearch->get_facetable_fields();
112
    my @faceted_fields = Koha::SearchEngine::Elasticsearch->get_facet_fields();
113
    is(scalar(@faceted_fields), 7);
113
    is(scalar(@faceted_fields), 6);
114
114
115
    is($faceted_fields[0]->name, 'holdingbranch');
115
    is($faceted_fields[0]->name, 'holdingbranch');
116
    is($faceted_fields[0]->facet_order, 1);
116
    is($faceted_fields[0]->facet_order, 1);
Lines 124-132 subtest 'get_facetable_fields() tests' => sub { Link Here
124
    is($faceted_fields[4]->facet_order, 5);
124
    is($faceted_fields[4]->facet_order, 5);
125
    is($faceted_fields[5]->name, 'subject');
125
    is($faceted_fields[5]->name, 'subject');
126
    is($faceted_fields[5]->facet_order, 6);
126
    is($faceted_fields[5]->facet_order, 6);
127
    is($faceted_fields[6]->name, 'author');
128
    ok(!$faceted_fields[6]->facet_order);
129
130
127
131
    $schema->storage->txn_rollback;
128
    $schema->storage->txn_rollback;
132
};
129
};
133
- 

Return to bug 35138