You are here

protected function ModerationInformationTest::getUser in Drupal 10

Same name and namespace in other branches
  1. 8 core/modules/content_moderation/tests/src/Unit/ModerationInformationTest.php \Drupal\Tests\content_moderation\Unit\ModerationInformationTest::getUser()
  2. 9 core/modules/content_moderation/tests/src/Unit/ModerationInformationTest.php \Drupal\Tests\content_moderation\Unit\ModerationInformationTest::getUser()

Builds a mock user.

Return value

\Drupal\Core\Session\AccountInterface The mocked user.

File

core/modules/content_moderation/tests/src/Unit/ModerationInformationTest.php, line 30

Class

ModerationInformationTest
@coversDefaultClass \Drupal\content_moderation\ModerationInformation @group content_moderation

Namespace

Drupal\Tests\content_moderation\Unit

Code

protected function getUser() {
  return $this
    ->prophesize(AccountInterface::class)
    ->reveal();
}