public function BlockDependenciesTest::testExposedBlock in Zircon Profile 8
Same name and namespace in other branches
- 8.0 core/modules/views/src/Tests/Plugin/BlockDependenciesTest.php \Drupal\views\Tests\Plugin\BlockDependenciesTest::testExposedBlock()
Tests that exposed filter blocks have the correct dependencies.
See also
\Drupal\views\Plugin\Derivative\ViewsExposedFilterBlock::getDerivativeDefinitions()
File
- core/
modules/ views/ src/ Tests/ Plugin/ BlockDependenciesTest.php, line 38 - Contains \Drupal\views\Tests\Plugin\BlockDependenciesTest.
Class
- BlockDependenciesTest
- Tests views block config dependencies functionality.
Namespace
Drupal\views\Tests\PluginCode
public function testExposedBlock() {
$block = $this
->createBlock('views_exposed_filter_block:test_exposed_block-page_1');
$dependencies = $block
->calculateDependencies()
->getDependencies();
$expected = array(
'config' => array(
'views.view.test_exposed_block',
),
'module' => array(
'views',
),
'theme' => array(
'stark',
),
);
$this
->assertIdentical($expected, $dependencies);
}