function LayoutPluginManagerTest::testGetLayoutOptions

Same name in other branches
  1. 11.x core/tests/Drupal/Tests/Core/Layout/LayoutPluginManagerTest.php \Drupal\Tests\Core\Layout\LayoutPluginManagerTest::testGetLayoutOptions()

@covers ::getLayoutOptions

Test that modules and themes can alter the list of layouts.

File

core/tests/Drupal/Tests/Core/Layout/LayoutPluginManagerTest.php, line 365

Class

LayoutPluginManagerTest
@coversDefaultClass \Drupal\Core\Layout\LayoutPluginManager @group Layout

Namespace

Drupal\Tests\Core\Layout

Code

public function testGetLayoutOptions() : void {
    $this->moduleHandler
        ->alter([
        'plugin_filter_layout',
        'plugin_filter_layout__layout',
    ], Argument::type('array'), [], 'layout')
        ->shouldBeCalled();
    $this->themeManager
        ->alter([
        'plugin_filter_layout',
        'plugin_filter_layout__layout',
    ], Argument::type('array'), [], 'layout')
        ->shouldBeCalled();
    $this->layoutPluginManager
        ->getLayoutOptions();
}

Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.