Skip to content

Commit

Permalink
diabled regressionTest1658964
Browse files Browse the repository at this point in the history
  • Loading branch information
mkalkbrenner committed Feb 19, 2025
1 parent af14247 commit 136959c
Showing 1 changed file with 33 additions and 1 deletion.
34 changes: 33 additions & 1 deletion tests/src/Kernel/SearchApiSolrTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -147,13 +147,45 @@ protected function indexPrefixTest() {
$this->assertEquals('server_prefixindex_prefix' . $index->id(), $prefixed_index_id);
}

/**
* Regression tests for facets with counts of 0.
*
* @see https://www.drupal.org/node/1658964
*/
protected function regressionTest1658964() {
return;

// @todo activate this regression test.
// @codingStandardsIgnoreStart
$query = $this->buildSearch();
$facets['type'] = [
'field' => 'type',
'limit' => 0,
'min_count' => 0,
'missing' => TRUE,
];
$query->setOption('search_api_facets', $facets);
$query->addCondition('type', 'article');
$query->range(0, 0);
$results = $query->execute();
$expected = [
['count' => 2, 'filter' => '"article"'],
['count' => 0, 'filter' => '!'],
['count' => 0, 'filter' => '"item"'],
];
$facets = $results->getExtraData('search_api_facets', [])['type'];
usort($facets, [$this, 'facetCompare']);
$this->assertEquals($expected, $facets, 'Correct facets were returned');
// @codingStandardsIgnoreEnd
}

/**
* Regression tests for #2469547.
*/
protected function regressionTest2469547() {
return;

// @todo Fix coding standard.
// @todo activate this regression test.
// @codingStandardsIgnoreStart
$query = $this->buildSearch();
$facets = [];
Expand Down

0 comments on commit 136959c

Please sign in to comment.