You are here

110 string references to current_user in Drupal 10

AccountSwitcherTest::testAccountSwitching in core/tests/Drupal/KernelTests/Core/Session/AccountSwitcherTest.php
AllowedValuesConstraintValidator::create in core/lib/Drupal/Core/Validation/Plugin/Validation/Constraint/AllowedValuesConstraintValidator.php
Instantiates a new instance of this class.
ArgumentDefaultTest::testArgumentDefaultNoOptions in core/modules/views/tests/src/Functional/Plugin/ArgumentDefaultTest.php
Tests the use of a default argument plugin that provides no options.
BlockContentBlock::create in core/modules/block_content/src/Plugin/Block/BlockContentBlock.php
BlockManagerTest::setUp in core/tests/Drupal/Tests/Core/Block/BlockManagerTest.php
Broken::create in core/lib/Drupal/Core/Block/Plugin/Block/Broken.php
CancelUser::create in core/modules/user/src/Plugin/Action/CancelUser.php
ChooseBlockController::create in core/modules/layout_builder/src/Controller/ChooseBlockController.php
Instantiates a new instance of this class.
CKEditor5MediaController::create in core/modules/ckeditor5/src/Controller/CKEditor5MediaController.php
Instantiates a new instance of this class.
CommentActionsTest::testCommentDefaultConfigActions in core/modules/comment/tests/src/Kernel/CommentActionsTest.php
Tests comment module's default config actions.
CommentDefaultFormatter::create in core/modules/comment/src/Plugin/Field/FieldFormatter/CommentDefaultFormatter.php
Creates an instance of the plugin.
CommentDefaultFormatterCacheTagsTest::setUp in core/modules/comment/tests/src/Kernel/CommentDefaultFormatterCacheTagsTest.php
CommentForm::create in core/modules/comment/src/CommentForm.php
Instantiates a new instance of this class.
CommentIntegrationTest::testCommentDefaultOwner in core/modules/comment/tests/src/Kernel/CommentIntegrationTest.php
Tests the default owner of comment entities.
CommentLockTest::testLocks in core/modules/comment/tests/src/Unit/Entity/CommentLockTest.php
Tests the lock behavior.
CommentStorage::createInstance in core/modules/comment/src/CommentStorage.php
Instantiates a new instance of this entity handler.
CommentViewBuilder::createInstance in core/modules/comment/src/CommentViewBuilder.php
Instantiates a new instance of this entity handler.
ConfigTranslationController::create in core/modules/config_translation/src/Controller/ConfigTranslationController.php
Instantiates a new instance of this class.
ContentTranslationHandler::createInstance in core/modules/content_translation/src/ContentTranslationHandler.php
ControllerBase::currentUser in core/lib/Drupal/Core/Controller/ControllerBase.php
Returns the current user.
CopyTest::testEntityStorageException in core/modules/file/tests/src/Kernel/CopyTest.php
Tests for entity storage exception.
CurrentUserContext::getRuntimeContexts in core/modules/user/src/ContextProvider/CurrentUserContext.php
Gets runtime context values for the given context IDs.
CurrentUserContextTest::testGetAvailableContexts in core/modules/user/tests/src/Kernel/ContextProvider/CurrentUserContextTest.php
@covers ::getAvailableContexts
DbLogFormInjectionTest::setUp in core/modules/dblog/tests/src/Kernel/DbLogFormInjectionTest.php
DbUpdateController::create in core/modules/system/src/Controller/DbUpdateController.php
Instantiates a new instance of this class.
DefaultSelection::create in core/lib/Drupal/Core/Entity/Plugin/EntityReferenceSelection/DefaultSelection.php
Creates an instance of the plugin.
DeleteAction::create in core/lib/Drupal/Core/Action/Plugin/Action/DeleteAction.php
DeleteActionTest::setUp in core/tests/Drupal/KernelTests/Core/Action/DeleteActionTest.php
DeleteMultipleForm::create in core/lib/Drupal/Core/Entity/Form/DeleteMultipleForm.php
Instantiates a new instance of this class.
DemoUmamiProfileTest::drupalLoginWithPassword in core/profiles/demo_umami/tests/src/Functional/DemoUmamiProfileTest.php
Logs in a user using the Mink controlled browser using a password.
Drupal::currentUser in core/lib/Drupal.php
Gets the current active user.
DrupalDateTimeTest::testDateTimezone in core/modules/system/tests/src/Functional/Datetime/DrupalDateTimeTest.php
Tests that DrupalDateTime can detect the right timezone to use.
DrupalKernel::initializeContainer in core/lib/Drupal/Core/DrupalKernel.php
Initializes the service container.
DrupalTest::testCurrentUser in core/tests/Drupal/Tests/Core/DrupalTest.php
Tests the currentUser() method.
EntityAutocompleteElementFormTest::setUp in core/tests/Drupal/KernelTests/Core/Entity/Element/EntityAutocompleteElementFormTest.php
EntityTranslationTest::doTestEntityLanguageMethods in core/tests/Drupal/KernelTests/Core/Entity/EntityTranslationTest.php
Executes the entity language method tests for the given entity type.
EntityTypeInfo::create in core/modules/content_moderation/src/EntityTypeInfo.php
EntryPoint::create in core/modules/jsonapi/src/Controller/EntryPoint.php
Instantiates a new instance of this class.
ExternalFormUrlTest::setUp in core/tests/Drupal/KernelTests/Core/Form/ExternalFormUrlTest.php
FieldFieldTest::setUp in core/modules/views/tests/src/Kernel/Handler/FieldFieldTest.php
FileItemValidationTest::setUp in core/modules/file/tests/src/Kernel/FileItemValidationTest.php
FileRepositoryTest::testEntityStorageException in core/modules/file/tests/src/Kernel/FileRepositoryTest.php
Tests for entity storage exception.
FileUploadResource::create in core/modules/file/src/Plugin/rest/resource/FileUploadResource.php
Creates an instance of the plugin.
FormActionXssTest::setUp in core/tests/Drupal/KernelTests/Core/Form/FormActionXssTest.php
FormBuilder::currentUser in core/lib/Drupal/Core/Form/FormBuilder.php
Gets the current active user.
FormBuilderTest::testFormTokenCacheability in core/tests/Drupal/Tests/Core/Form/FormBuilderTest.php
@covers ::prepareForm
ForumController::create in core/modules/forum/src/Controller/ForumController.php
Instantiates a new instance of this class.
HandlerFilterCurrentUserTest::setUp in core/modules/user/tests/src/Kernel/Views/HandlerFilterCurrentUserTest.php
HelpSearch::create in core/modules/help_topics/src/Plugin/Search/HelpSearch.php
ImageFormatter::create in core/modules/image/src/Plugin/Field/FieldFormatter/ImageFormatter.php
Creates an instance of the plugin.
InlineBlock::create in core/modules/layout_builder/src/Plugin/Block/InlineBlock.php
LanguageServiceProvider::register in core/modules/language/src/LanguageServiceProvider.php
LayoutBuilderIntegration::create in core/modules/quickedit/src/LayoutBuilderIntegration.php
LinkAccessConstraintValidator::create in core/modules/link/src/Plugin/Validation/Constraint/LinkAccessConstraintValidator.php
Instantiates a new instance of this class.
ListingEmpty::create in core/modules/block_content/src/Plugin/views/area/ListingEmpty.php
LocaleLookupTest::setUp in core/modules/locale/tests/src/Unit/LocaleLookupTest.php
LocaleLookupTest::testGetCid in core/modules/locale/tests/src/Unit/LocaleLookupTest.php
@covers ::getCid
LoggerChannelFactory::get in core/lib/Drupal/Core/Logger/LoggerChannelFactory.php
LoginLogoutMenuLink::create in core/modules/user/src/Plugin/Menu/LoginLogoutMenuLink.php
MediaEmbedFilterDisabledIntegrationsTest::setUp in core/modules/quickedit/tests/src/Kernel/MediaEmbedFilterDisabledIntegrationsTest.php
MediaEmbedFilterDisabledIntegrationsTest::setUp in core/modules/media/tests/src/Kernel/MediaEmbedFilterDisabledIntegrationsTest.php
MediaEmbedFilterTest::testAccessUnpublished in core/modules/media/tests/src/Kernel/MediaEmbedFilterTest.php
Tests that entity access is respected by embedding an unpublished entity.
MediaEmbedFilterTestBase::setUp in core/modules/media/tests/src/Kernel/MediaEmbedFilterTestBase.php
MediaKernelTestBase::setUp in core/modules/media/tests/src/Kernel/MediaKernelTestBase.php
MediaLibraryWidget::create in core/modules/media_library/src/Plugin/Field/FieldWidget/MediaLibraryWidget.php
Creates an instance of the plugin.
MediaThumbnailFormatter::create in core/modules/media/src/Plugin/Field/FieldFormatter/MediaThumbnailFormatter.php
Creates an instance of the plugin.
MigrateEntityContentValidationTest::testEntityOwnerValidation in core/modules/migrate/tests/src/Kernel/MigrateEntityContentValidationTest.php
Tests validation for entities that are instances of EntityOwnerInterface.
ModerationStateConstraintValidator::create in core/modules/content_moderation/src/Plugin/Validation/Constraint/ModerationStateConstraintValidator.php
Instantiates a new instance of this class.
ModerationStateFieldItemListTest::testModerationStateSampleValues in core/modules/content_moderation/tests/src/Kernel/ModerationStateFieldItemListTest.php
Test generating sample values for entities with a moderation state.
ModerationStateWidget::create in core/modules/content_moderation/src/Plugin/Field/FieldWidget/ModerationStateWidget.php
Creates an instance of the plugin.
ModulesListForm::create in core/modules/system/src/Form/ModulesListForm.php
Instantiates a new instance of this class.
MoveTest::testEntityStorageException in core/modules/file/tests/src/Kernel/MoveTest.php
Tests for entity storage exception.
NodeFieldOverridesTest::setUp in core/modules/node/tests/src/Kernel/NodeFieldOverridesTest.php
NodeForm::create in core/modules/node/src/NodeForm.php
Instantiates a new instance of this class.
NodeOwnerTest::testOwner in core/modules/node/tests/src/Kernel/NodeOwnerTest.php
Tests node owner functionality.
NodeSearch::create in core/modules/node/src/Plugin/Search/NodeSearch.php
NodeViewController::create in core/modules/node/src/Controller/NodeViewController.php
Instantiates a new instance of this class.
OverridesSectionStorage::create in core/modules/layout_builder/src/Plugin/SectionStorage/OverridesSectionStorage.php
PathElementFormTest::setUp in core/tests/Drupal/KernelTests/Core/Element/PathElementFormTest.php
Sets up the test.
ProtectedUserFieldConstraintValidator::create in core/modules/user/src/Plugin/Validation/Constraint/ProtectedUserFieldConstraintValidator.php
Instantiates a new instance of this class.
QuickEditLoadingTest::testDisplayOptions in core/modules/quickedit/tests/src/Kernel/QuickEditLoadingTest.php
Tests that Quick Edit doesn't make fields rendered with display options editable.
ResourceTestBase::setUp in core/modules/jsonapi/tests/src/Functional/ResourceTestBase.php
ResponsiveImageFormatter::create in core/modules/responsive_image/src/Plugin/Field/FieldFormatter/ResponsiveImageFormatter.php
Creates an instance of the plugin.
SectionRenderTest::setUp in core/modules/layout_builder/tests/src/Unit/SectionRenderTest.php
SyslogTest::testSyslogWriting in core/modules/syslog/tests/src/Kernel/SyslogTest.php
@covers ::log
SystemBrandingOffCanvasForm::create in core/modules/system/src/Form/SystemBrandingOffCanvasForm.php
Instantiates a new instance of this class.
SystemMenuBlockTest::setUp in core/modules/system/tests/src/Kernel/Block/SystemMenuBlockTest.php
SystemTestController::create in core/modules/system/tests/modules/system_test/src/Controller/SystemTestController.php
Instantiates a new instance of this class.
TaxonomyFieldVidTest::setUp in core/modules/taxonomy/tests/src/Kernel/Views/TaxonomyFieldVidTest.php
TaxonomyIndexTid::create in core/modules/taxonomy/src/Plugin/views/filter/TaxonomyIndexTid.php
TextFormatElementFormTest::setUp in core/modules/filter/tests/src/Kernel/TextFormatElementFormTest.php
Sets up the test.
TokenTest::setUp in core/tests/Drupal/Tests/Core/Utility/TokenTest.php
TokenTest::testReplaceWithBubbleableMetadataObject in core/tests/Drupal/Tests/Core/Utility/TokenTest.php
@covers ::replace
TokenTest::testReplaceWithHookTokensAlterWithBubbleableMetadata in core/tests/Drupal/Tests/Core/Utility/TokenTest.php
@covers ::replace @covers ::replace
TokenTest::testReplaceWithHookTokensWithBubbleableMetadata in core/tests/Drupal/Tests/Core/Utility/TokenTest.php
@covers ::replace
UiHelperTrait::drupalLogin in core/tests/Drupal/Tests/UiHelperTrait.php
Logs in a user using the Mink controlled browser.
UpdateKernel::handleAccess in core/lib/Drupal/Core/Update/UpdateKernel.php
Checks if the current user has rights to access updates page.
UserAccountFormPasswordResetTest::setUp in core/modules/user/tests/src/Kernel/UserAccountFormPasswordResetTest.php
UserAuthenticationController::login in core/modules/user/src/Controller/UserAuthenticationController.php
Logs in a user.
UserLoginHttpTest::doTestLogin in core/modules/user/tests/src/Functional/UserLoginHttpTest.php
Do login testing for a given serialization format.
UserMailRequiredValidatorTest::createValidator in core/modules/user/tests/src/Unit/Plugin/Validation/Constraint/UserMailRequiredValidatorTest.php
Creates a validator instance.
UserRegistrationResource::create in core/modules/user/src/Plugin/rest/resource/UserRegistrationResource.php
Creates an instance of the plugin.
UserSearch::create in core/modules/user/src/Plugin/Search/UserSearch.php
UserSelection::create in core/modules/user/src/Plugin/EntityReferenceSelection/UserSelection.php
UserTrackerTab::create in core/modules/tracker/src/Plugin/Menu/UserTrackerTab.php
views.view.test_plugin_argument_default_current_user.yml in core/modules/user/tests/modules/user_test_views/test_views/views.view.test_plugin_argument_default_current_user.yml
core/modules/user/tests/modules/user_test_views/test_views/views.view.test_plugin_argument_default_current_user.yml
ViewsBlockBase::create in core/modules/views/src/Plugin/Block/ViewsBlockBase.php
ViewsSelection::create in core/modules/views/src/Plugin/EntityReferenceSelection/ViewsSelection.php
ViewUIObjectTest::testIsLocked in core/modules/views_ui/tests/src/Unit/ViewUIObjectTest.php
Tests the isLocked method.
VocabularyListBuilder::createInstance in core/modules/taxonomy/src/VocabularyListBuilder.php
Instantiates a new instance of this entity handler.