73 calls to EntityReferenceFieldCreationTrait::createEntityReferenceField()

ArgumentSummaryTest::setUp in core/modules/views/tests/src/Kernel/Handler/ArgumentSummaryTest.php
CommentEntityReferenceTest::setUp in core/modules/comment/tests/src/Functional/CommentEntityReferenceTest.php
CommentValidationTest::testValidationOfCommentOfUnpublishedNode in core/modules/comment/tests/src/Kernel/CommentValidationTest.php
Tests that comments of unpublished nodes are not valid.
CommonCollectionFilterAccessTestPatternsTrait::doTestCollectionFilterAccessBasedOnPermissions in core/modules/jsonapi/tests/src/Traits/CommonCollectionFilterAccessTestPatternsTrait.php
Implements ::testCollectionFilterAccess() for pure permission-based access.
ContentEntityTest::setUp in core/modules/migrate_drupal/tests/src/Kernel/Plugin/migrate/source/ContentEntityTest.php
ContentImportTest::setUp in core/tests/Drupal/FunctionalTests/DefaultContent/ContentImportTest.php
ContentModerationTest::setUp in core/modules/media_library/tests/src/FunctionalJavascript/ContentModerationTest.php
DefaultViewsTest::setUp in core/modules/views/tests/src/Functional/DefaultViewsTest.php
Sets up the test.
DisplayEntityReferenceTest::setUp in core/modules/views/tests/src/Functional/Plugin/DisplayEntityReferenceTest.php
Sets up the test.
EarlyDateTest::setUp in core/modules/taxonomy/tests/src/Functional/EarlyDateTest.php
EntityQueryRelationshipTest::setUp in core/tests/Drupal/KernelTests/Core/Entity/EntityQueryRelationshipTest.php
EntityQueryTest::testWithTwoEntityReferenceFieldsToSameEntityType in core/tests/Drupal/KernelTests/Core/Entity/EntityQueryTest.php
Tests that EntityQuery works when querying the same entity from two fields.
EntityReferenceAutocompleteWidgetTest::testEntityReferenceAutocompleteWidget in core/tests/Drupal/FunctionalJavascriptTests/EntityReference/EntityReferenceAutocompleteWidgetTest.php
Tests that the default autocomplete widget return the correct results.
EntityReferenceAutocompleteWidgetTest::testEntityReferenceAutocompleteWidgetAttachedEntity in core/tests/Drupal/FunctionalJavascriptTests/EntityReference/EntityReferenceAutocompleteWidgetTest.php
Tests that the autocomplete widget knows about the entity its attached to.
EntityReferenceAutoCreateTest::testMultipleTargetBundles in core/modules/field/tests/src/Functional/EntityReference/EntityReferenceAutoCreateTest.php
Tests multiple target bundles.
EntityReferenceAutoCreateTest::testNoBundles in core/modules/field/tests/src/Functional/EntityReference/EntityReferenceAutoCreateTest.php
Tests autocreation for an entity that has no bundles.
EntityReferenceFieldCreationTest::testAddReferenceFieldTargetingEntityTypeWithoutId in core/modules/system/tests/src/Functional/Entity/EntityReferenceFieldCreationTest.php
Tests that entity reference fields cannot target entity types without IDs.
EntityReferenceFieldTest::setUp in core/tests/Drupal/KernelTests/Core/Entity/EntityReferenceFieldTest.php
EntityReferenceFieldTest::testReferencedEntitiesStringId in core/tests/Drupal/KernelTests/Core/Entity/EntityReferenceFieldTest.php
Tests referencing entities with string IDs.
EntityReferenceFormatterTest::setUp in core/modules/field/tests/src/Kernel/EntityReference/EntityReferenceFormatterTest.php
EntityReferenceIntegrationTest::testSupportedEntityTypesAndWidgets in core/modules/field/tests/src/Functional/EntityReference/EntityReferenceIntegrationTest.php
Tests the entity reference field with all its supported field widgets.
EntityReferenceItemTest::setUp in core/modules/field/tests/src/Kernel/EntityReference/EntityReferenceItemTest.php
Sets up the test.
EntityReferenceRelationshipTest::setUp in core/modules/field/tests/src/Kernel/EntityReference/Views/EntityReferenceRelationshipTest.php
EntityReferenceRelationshipTest::testEntityReferenceConfigEntity in core/modules/field/tests/src/Kernel/EntityReference/Views/EntityReferenceRelationshipTest.php
Test that config entities don't get relationships added.
EntityReferenceSelectionReferenceableTest::setUp in core/modules/system/tests/src/Kernel/Entity/EntityReferenceSelectionReferenceableTest.php
EntityReferenceSettingsTest::testConfigTargetBundleDeletion in core/modules/field/tests/src/Kernel/EntityReference/EntityReferenceSettingsTest.php
Tests that config bundle deletions are mirrored in field config settings.
EntityReferenceSettingsTest::testCustomTargetBundleDeletion in core/modules/field/tests/src/Kernel/EntityReference/EntityReferenceSettingsTest.php
Tests that deletions of custom bundles are mirrored in field settings.
EntityReferenceXSSTest::testEntityReferenceXSS in core/modules/field/tests/src/Functional/EntityReference/EntityReferenceXSSTest.php
Tests markup is escaped in the entity reference select and label formatter.
EntityResourceTest::setUp in core/modules/jsonapi/tests/src/Kernel/Controller/EntityResourceTest.php
EntityViewBuilderTest::testEntityViewBuilderCacheWithReferences in core/tests/Drupal/KernelTests/Core/Entity/EntityViewBuilderTest.php
Tests entity render cache with references.
EntityViewBuilderTest::testViewField in core/tests/Drupal/KernelTests/Core/Entity/EntityViewBuilderTest.php
Tests EntityViewBuilder::viewField() language awareness.
ExposedFormCheckboxesTest::testExposedIsAllOfFilter in core/modules/views/tests/src/Functional/Plugin/ExposedFormCheckboxesTest.php
Tests that "is all of" filters work with checkboxes.
FileUploadTest::setUp in core/modules/jsonapi/tests/src/Kernel/Controller/FileUploadTest.php
InternalEntitiesTest::setUp in core/modules/jsonapi/tests/src/Functional/InternalEntitiesTest.php
JsonApiDocumentTopLevelNormalizerTest::setUp in core/modules/jsonapi/tests/src/Kernel/Normalizer/JsonApiDocumentTopLevelNormalizerTest.php
JsonApiFilterRegressionTest::testEmptyRelationshipFilteringFromIssue3025372 in core/modules/jsonapi/tests/src/Functional/JsonApiFilterRegressionTest.php
Ensure filtering for entities with empty entity reference fields works.
JsonApiFunctionalTestBase::setUp in core/modules/jsonapi/tests/src/Functional/JsonApiFunctionalTestBase.php
JsonApiPatchRegressionTest::testBundlelessRelationshipMutationFromIssue2973681 in core/modules/jsonapi/tests/src/Functional/JsonApiPatchRegressionTest.php
Ensure POST and PATCH works for bundle-less relationship routes.
JsonApiPatchRegressionTest::testDanglingReferencesInAnEntityReferenceFieldFromIssue2968972 in core/modules/jsonapi/tests/src/Functional/JsonApiPatchRegressionTest.php
Cannot PATCH an entity with dangling references in an ER field.
JsonApiRegressionTest::testDanglingReferencesInAnEntityReferenceFieldFromIssue2984647 in core/modules/jsonapi/tests/src/Functional/JsonApiRegressionTest.php
Cannot GET an entity with dangling references in an ER field.
JsonApiRegressionTest::testDeepNestedIncludeMultiTargetEntityTypeFieldFromIssue2973681 in core/modules/jsonapi/tests/src/Functional/JsonApiRegressionTest.php
Ensure deep nested include works on multi target entity type field.
JsonApiRegressionTest::testDenormalizeAliasedRelationshipFromIssue2953207 in core/modules/jsonapi/tests/src/Functional/JsonApiRegressionTest.php
Ensures denormalizing relationships with aliased field names works.
JsonApiRegressionTest::testThatRoutesAreRebuiltAfterDataModelChangesFromIssue2984886 in core/modules/jsonapi/tests/src/Functional/JsonApiRegressionTest.php
Ensures that JSON:API routes are caches are dynamically rebuilt.
LayoutBuilderFieldBlockEntityReferenceCacheTagsTest::setUp in core/modules/layout_builder/tests/src/Functional/LayoutBuilderFieldBlockEntityReferenceCacheTagsTest.php
ManageFieldsFunctionalTestBase::setUp in core/modules/field_ui/tests/src/Functional/ManageFieldsFunctionalTestBase.php
MediaThumbnailFormatterTest::setUp in core/modules/media/tests/src/Kernel/MediaThumbnailFormatterTest.php
MigrationPluginListTest::testGetDefinitions in core/modules/migrate/tests/src/Kernel/Plugin/MigrationPluginListTest.php
@covers ::getDefinitions
NodeAccessBaseTableTest::setUp in core/modules/node/tests/src/Functional/NodeAccessBaseTableTest.php
NodeAccessCacheabilityWithNodeGrants::testAccessCacheabilityWithNodeGrants in core/modules/node/tests/src/Functional/NodeAccessCacheabilityWithNodeGrants.php
Tests node view access cacheability with node grants.
PagePreviewTest::setUp in core/modules/node/tests/src/Functional/PagePreviewTest.php
RelatedResourceTypesTest::setUp in core/modules/jsonapi/tests/src/Kernel/ResourceType/RelatedResourceTypesTest.php
RelatedResourceTypesTest::testGetRelatableResourceTypesFromFieldDefinition in core/modules/jsonapi/tests/src/Kernel/ResourceType/RelatedResourceTypesTest.php
Ensure a graceful failure when a field can references a missing bundle.
RelationshipNormalizerTest::setUp in core/modules/jsonapi/tests/src/Kernel/Normalizer/RelationshipNormalizerTest.php
ResourceTypeRepositoryTest::testCaching in core/modules/jsonapi/tests/src/Kernel/ResourceType/ResourceTypeRepositoryTest.php
Ensures that the ResourceTypeRepository's cache does not become stale.
RssTest::setUp in core/modules/taxonomy/tests/src/Functional/RssTest.php
SelectionTest::setUp in core/modules/field/tests/src/Functional/EntityReference/Views/SelectionTest.php
SelectionTest::setUp in core/modules/field/tests/src/Kernel/EntityReference/Views/SelectionTest.php
TaggedWithTest::setUp in core/modules/views/tests/src/Functional/Wizard/TaggedWithTest.php
Sets up the test.
TaxonomyIndexTidUiTest::testExposedFilter in core/modules/taxonomy/tests/src/Functional/Views/TaxonomyIndexTidUiTest.php
Tests exposed taxonomy filters.
TaxonomyIndexTidUiTest::testExposedGroupedFilter in core/modules/taxonomy/tests/src/Functional/Views/TaxonomyIndexTidUiTest.php
Tests exposed grouped taxonomy filters.
TaxonomyIndexTidUiTest::testFilterGrouping in core/modules/taxonomy/tests/src/Functional/Views/TaxonomyIndexTidUiTest.php
Tests using the TaxonomyIndexTid in a filter group.
TaxonomyTermViewTest::setUp in core/modules/taxonomy/tests/src/Functional/Views/TaxonomyTermViewTest.php
Sets up the test.
TaxonomyTestBase::mockStandardInstall in core/modules/taxonomy/tests/src/Functional/Views/TaxonomyTestBase.php
Provides a workaround for the inability to use the standard profile.
TaxonomyTestBase::mockStandardInstall in core/modules/taxonomy/tests/src/Kernel/Views/TaxonomyTestBase.php
Provides a workaround for the inability to use the standard profile.
TaxonomyTranslationTestTrait::setUpTermReferenceField in core/modules/taxonomy/tests/src/Functional/TaxonomyTranslationTestTrait.php
Adds term reference field for the article content type.
TemporaryJsonapiFileFieldUploaderTest::setUp in core/modules/jsonapi/tests/src/Kernel/Controller/TemporaryJsonapiFileFieldUploaderTest.php
TermIndexTest::setUp in core/modules/taxonomy/tests/src/Functional/TermIndexTest.php
TermTest::setUp in core/modules/taxonomy/tests/src/Functional/TermTest.php
TokenReplaceTest::setUp in core/modules/taxonomy/tests/src/Kernel/TokenReplaceTest.php
TranslationsTest::setUp in core/modules/media_library/tests/src/FunctionalJavascript/TranslationsTest.php
UserEntityReferenceTest::setUp in core/modules/user/tests/src/Kernel/UserEntityReferenceTest.php
ValidReferenceConstraintValidatorTest::testPreExistingItemsValidation in core/tests/Drupal/KernelTests/Core/Entity/ValidReferenceConstraintValidatorTest.php
Tests the validation of pre-existing items in an entity reference field.
WorkspaceIntegrationTest::testEntityQueryRelationship in core/modules/workspaces/tests/src/Kernel/WorkspaceIntegrationTest.php
Tests the Entity Query relationship API with workspaces.

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