You are here

class CacheTestController in Zircon Profile 8

Same name and namespace in other branches
  1. 8.0 core/modules/system/tests/modules/cache_test/src/Controller/CacheTestController.php \Drupal\cache_test\Controller\CacheTestController

Controller routines for cache_test routes.

Hierarchy

Expanded class hierarchy of CacheTestController

File

core/modules/system/tests/modules/cache_test/src/Controller/CacheTestController.php, line 15
Contains \Drupal\cache_test\Controller\CacheTestController.

Namespace

Drupal\cache_test\Controller
View source
class CacheTestController {

  /**
   * Early renders a URL to test bubbleable metadata bubbling.
   */
  public function urlBubbling() {
    $url = Url::fromRoute('<current>')
      ->setAbsolute();
    return [
      '#markup' => 'This URL is early-rendered: ' . $url
        ->toString() . '. Yet, its bubbleable metadata should be bubbled.',
    ];
  }

}

Members

Namesort descending Modifiers Type Description Overrides
CacheTestController::urlBubbling public function Early renders a URL to test bubbleable metadata bubbling.