function UserRegistrationResourceTest::setUp
Same name in other branches
- 9 core/modules/user/tests/src/Unit/UserRegistrationResourceTest.php \Drupal\Tests\user\Unit\UserRegistrationResourceTest::setUp()
- 8.9.x core/modules/user/tests/src/Unit/UserRegistrationResourceTest.php \Drupal\Tests\user\Unit\UserRegistrationResourceTest::setUp()
- 10 core/modules/user/tests/src/Unit/UserRegistrationResourceTest.php \Drupal\Tests\user\Unit\UserRegistrationResourceTest::setUp()
Overrides UnitTestCase::setUp
File
-
core/
modules/ user/ tests/ src/ Unit/ UserRegistrationResourceTest.php, line 73
Class
- UserRegistrationResourceTest
- Tests User Registration REST resource.
Namespace
Drupal\Tests\user\UnitCode
protected function setUp() : void {
parent::setUp();
$this->logger = $this->prophesize(LoggerInterface::class)
->reveal();
$this->userSettings = $this->prophesize(ImmutableConfig::class);
$this->currentUser = $this->prophesize(AccountInterface::class);
$this->passwordGenerator = $this->prophesize(PasswordGeneratorInterface::class)
->reveal();
$this->testClass = new UserRegistrationResource([], 'plugin_id', '', [], $this->logger, $this->userSettings
->reveal(), $this->currentUser
->reveal(), $this->passwordGenerator);
$this->reflection = new \ReflectionClass($this->testClass);
}
Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.