function FilterEqualityTest::testEqualGroupedNotExposed
Same name in other branches
- 9 core/modules/views/tests/src/Kernel/Handler/FilterEqualityTest.php \Drupal\Tests\views\Kernel\Handler\FilterEqualityTest::testEqualGroupedNotExposed()
- 8.9.x core/modules/views/tests/src/Kernel/Handler/FilterEqualityTest.php \Drupal\Tests\views\Kernel\Handler\FilterEqualityTest::testEqualGroupedNotExposed()
- 11.x core/modules/views/tests/src/Kernel/Handler/FilterEqualityTest.php \Drupal\Tests\views\Kernel\Handler\FilterEqualityTest::testEqualGroupedNotExposed()
File
-
core/
modules/ views/ tests/ src/ Kernel/ Handler/ FilterEqualityTest.php, line 120
Class
- FilterEqualityTest
- Tests the core Drupal\views\Plugin\views\filter\Equality handler.
Namespace
Drupal\Tests\views\Kernel\HandlerCode
public function testEqualGroupedNotExposed() : void {
$filters = $this->getGroupedExposedFilters();
$view = Views::getView('test_view');
$view->newDisplay('page', 'Page', 'page_1');
// Filter: Name, Operator: !=, Value: Ringo
$filters['name']['group_info']['default_group'] = 2;
$view->setDisplay('page_1');
$view->displayHandlers
->get('page_1')
->overrideOption('filters', $filters);
$view->save();
$this->executeView($view);
$resultset = [
[
'name' => 'John',
],
[
'name' => 'George',
],
[
'name' => 'Paul',
],
[
'name' => 'Meredith',
],
];
$this->assertIdenticalResultset($view, $resultset, $this->columnMap);
}
Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.