function UserControllerTest::testConstructorDeprecations

@group legacy @expectedDeprecation Calling Drupal\user\Controller\UserController::__construct without the $flood parameter is deprecated in drupal:8.8.0 and is required in drupal:9.0.0. See https://www.drupal.org/node/1681832

File

core/modules/user/tests/src/Kernel/Controller/UserControllerTest.php, line 22

Class

UserControllerTest
@coversDefaultClass <a href="/api/drupal/core%21modules%21user%21src%21Controller%21UserController.php/class/UserController/8.9.x" title="Controller routines for user routes." class="local">\Drupal\user\Controller\UserController</a> @group user

Namespace

Drupal\Tests\user\Kernel\Controller

Code

public function testConstructorDeprecations() {
    $date_formatter = $this->prophesize(DateFormatterInterface::class);
    $user_storage = $this->prophesize(UserStorageInterface::class);
    $user_data = $this->prophesize(UserDataInterface::class);
    $logger = $this->prophesize(LoggerInterface::class);
    $controller = new UserController($date_formatter->reveal(), $user_storage->reveal(), $user_data->reveal(), $logger->reveal());
    $this->assertNotNull($controller);
}

Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.