You are here

protected function FootermapBlockTest::getPlugin in footermap: a footer site map 8

Create an instance of the footermap block.plugin.

@returns \Drupal\footermap\Plugin\Block\FootermapBlock A block plugin instance.

6 calls to FootermapBlockTest::getPlugin()
FootermapBlockTest::testAccess in tests/src/Unit/Plugin/Block/FootermapBlockTest.php
Asserts the access callback for block access based on anonymous user.
FootermapBlockTest::testBlockForm in tests/src/Unit/Plugin/Block/FootermapBlockTest.php
Asserts the block configuration form.
FootermapBlockTest::testBuild in tests/src/Unit/Plugin/Block/FootermapBlockTest.php
Asserts that site map is built.
FootermapBlockTest::testDefaultConfiguration in tests/src/Unit/Plugin/Block/FootermapBlockTest.php
Asserts that default configuration matches expected values.
FootermapBlockTest::testGetCacheContexts in tests/src/Unit/Plugin/Block/FootermapBlockTest.php
Asserts the cache contexts are returned.

... See full list

File

tests/src/Unit/Plugin/Block/FootermapBlockTest.php, line 273

Class

FootermapBlockTest
Test footermap block methods.

Namespace

Drupal\Tests\footermap\Unit\Plugin\Block

Code

protected function getPlugin() {
  $configuration = [
    'label' => 'Footermap',
    'display_label' => TRUE,
  ];
  $plugin_id = 'footermap';
  $plugin_definition = [
    'plugin_id' => $plugin_id,
    'provider' => 'footermap',
  ];
  return FootermapBlock::create($this->container, $configuration, $plugin_id, $plugin_definition);
}