You are here

public function TestPathBasedBreadcrumbBuilder::setStringTranslation in Drupal 8

Same name and namespace in other branches
  1. 9 core/modules/system/tests/src/Unit/Breadcrumbs/PathBasedBreadcrumbBuilderTest.php \Drupal\Tests\system\Unit\Breadcrumbs\TestPathBasedBreadcrumbBuilder::setStringTranslation()

Sets the string translation service to use.

Parameters

\Drupal\Core\StringTranslation\TranslationInterface $translation: The string translation service.

Return value

$this

Overrides StringTranslationTrait::setStringTranslation

File

core/modules/system/tests/src/Unit/Breadcrumbs/PathBasedBreadcrumbBuilderTest.php, line 416
Contains \Drupal\Tests\system\Unit\Breadcrumbs\PathBasedBreadcrumbBuilderTest.

Class

TestPathBasedBreadcrumbBuilder
Helper class for testing purposes only.

Namespace

Drupal\Tests\system\Unit\Breadcrumbs

Code

public function setStringTranslation(TranslationInterface $string_translation) {
  $this->stringTranslation = $string_translation;
}