You are here

public function TestControllers::testEntityLanguage in Zircon Profile 8

Same name and namespace in other branches
  1. 8.0 core/modules/system/tests/modules/paramconverter_test/src/TestControllers.php \Drupal\paramconverter_test\TestControllers::testEntityLanguage()
1 string reference to 'TestControllers::testEntityLanguage'
paramconverter_test.routing.yml in core/modules/system/tests/modules/paramconverter_test/paramconverter_test.routing.yml
core/modules/system/tests/modules/paramconverter_test/paramconverter_test.routing.yml

File

core/modules/system/tests/modules/paramconverter_test/src/TestControllers.php, line 27
Contains \Drupal\paramconverter_test\TestControllers.

Class

TestControllers
Controller routine for testing the paramconverter.

Namespace

Drupal\paramconverter_test

Code

public function testEntityLanguage(NodeInterface $node) {
  $build = [
    '#markup' => $node
      ->label(),
  ];
  \Drupal::service('renderer')
    ->addCacheableDependency($build, $node);
  return $build;
}