You are here

protected function TermTranslationBreadcrumbTest::getLeafTerm in Zircon Profile 8

Same name and namespace in other branches
  1. 8.0 core/modules/taxonomy/src/Tests/TermTranslationBreadcrumbTest.php \Drupal\taxonomy\Tests\TermTranslationBreadcrumbTest::getLeafTerm()

Get the final (leaf) term in the hierarchy.

Return value

\Drupal\taxonomy\Entity\Term The final term in the hierarchy.

1 call to TermTranslationBreadcrumbTest::getLeafTerm()
TermTranslationBreadcrumbTest::testTranslatedBreadcrumbs in core/modules/taxonomy/src/Tests/TermTranslationBreadcrumbTest.php
Test translated breadcrumbs.

File

core/modules/taxonomy/src/Tests/TermTranslationBreadcrumbTest.php, line 122
Contains \Drupal\taxonomy\Tests\TermTranslationBreadcrumbTest.

Class

TermTranslationBreadcrumbTest
Tests for proper breadcrumb translation.

Namespace

Drupal\taxonomy\Tests

Code

protected function getLeafTerm() {
  return $this->terms[count($this->termTranslationMap) - 1];
}