You are here

public function HierarchicalTaxonomyMenuTest::testBlockPlacement in Hierarchical Taxonomy Menu 8

Test that the block can be placed.

File

tests/src/Functional/HierarchicalTaxonomyMenuTest.php, line 61

Class

HierarchicalTaxonomyMenuTest
Tests the Hierarchical Taxonomy Menu.

Namespace

Drupal\Tests\hierarchical_taxonomy_menu\Functional

Code

public function testBlockPlacement() {
  $this
    ->drupalPlaceBlock('hierarchical_taxonomy_menu', [
    'region' => 'content',
    'label' => 'Hierarchical Taxonomy Menu',
    'id' => 'hierarchicaltaxonomymenu',
  ]);
  $this
    ->drupalGet('admin/structure/block');
  $this
    ->assertSession()
    ->pageTextContains('Hierarchical Taxonomy Menu');
  $this
    ->drupalGet('<front>');
  $this
    ->assertSession()
    ->pageTextContains('Hierarchical Taxonomy Menu');
}