public function BreadcrumbIntegrationTest::testGroupingIntegration in Facets 8
Tests Breadcrumb integration with grouping.
File
- tests/
src/ Functional/ BreadcrumbIntegrationTest.php, line 55
Class
- BreadcrumbIntegrationTest
- Tests the overall functionality of the Facets admin UI.
Namespace
Drupal\Tests\facets\FunctionalCode
public function testGroupingIntegration() {
$this
->editFacetConfig();
$id = 'keywords';
$this
->createFacet('Keywords', $id, 'keywords');
$this
->resetAll();
$this
->drupalGet('admin/config/search/facets/' . $id . '/edit');
$id = 'type';
$this
->createFacet('Type', $id);
$this
->resetAll();
$this
->drupalGet('admin/config/search/facets/' . $id . '/edit');
$this
->drupalPostForm(NULL, [
'facet_settings[weight]' => '1',
], 'Save');
// Test with a default filter key.
$this
->editFacetConfig([
'filter_key' => 'f',
]);
$this
->breadcrumbTest();
// Test with an empty filter key.
$this
->editFacetConfig([
'filter_key' => '',
]);
$this
->breadcrumbTest();
// Test with a specific filter key.
$this
->editFacetConfig([
'filter_key' => 'my_filter_key',
]);
$this
->breadcrumbTest();
}