class EntityKernelTestBaseTest in Drupal 10
Same name and namespace in other branches
- 8 core/tests/Drupal/KernelTests/Core/Entity/EntityKernelTestBaseTest.php \Drupal\KernelTests\Core\Entity\EntityKernelTestBaseTest
- 9 core/tests/Drupal/KernelTests/Core/Entity/EntityKernelTestBaseTest.php \Drupal\KernelTests\Core\Entity\EntityKernelTestBaseTest
@covers \Drupal\KernelTests\Core\Entity\EntityKernelTestBase
@group Entity
Hierarchy
- class \Drupal\KernelTests\KernelTestBase extends \PHPUnit\Framework\TestCase implements ServiceProviderInterface uses \Drupal\Tests\PhpUnitCompatibilityTrait, \Symfony\Bridge\PhpUnit\ExpectDeprecationTrait, AssertContentTrait, ConfigTestTrait, ExtensionListTestTrait, RandomGeneratorTrait, TestRequirementsTrait, PhpUnitWarnings
- class \Drupal\KernelTests\Core\Entity\EntityKernelTestBase uses UserCreationTrait
- class \Drupal\KernelTests\Core\Entity\EntityKernelTestBaseTest
- class \Drupal\KernelTests\Core\Entity\EntityKernelTestBase uses UserCreationTrait
Expanded class hierarchy of EntityKernelTestBaseTest
File
- core/
tests/ Drupal/ KernelTests/ Core/ Entity/ EntityKernelTestBaseTest.php, line 10
Namespace
Drupal\KernelTests\Core\EntityView source
class EntityKernelTestBaseTest extends EntityKernelTestBase {
/**
* {@inheritdoc}
*/
protected function setUp() : void {
parent::setUp();
$this
->createUser();
}
/**
* Tests that the current user is set up correctly.
*/
public function testSetUpCurrentUser() {
$account = $this
->setUpCurrentUser();
$current_user = \Drupal::currentUser();
$this
->assertSame($account
->id(), $current_user
->id());
}
}