function EntityReferenceFieldDefaultValueTest::setUp
Same name in other branches
- 9 core/modules/field/tests/src/Functional/EntityReference/EntityReferenceFieldDefaultValueTest.php \Drupal\Tests\field\Functional\EntityReference\EntityReferenceFieldDefaultValueTest::setUp()
- 10 core/modules/field/tests/src/Functional/EntityReference/EntityReferenceFieldDefaultValueTest.php \Drupal\Tests\field\Functional\EntityReference\EntityReferenceFieldDefaultValueTest::setUp()
- 11.x core/modules/field/tests/src/Functional/EntityReference/EntityReferenceFieldDefaultValueTest.php \Drupal\Tests\field\Functional\EntityReference\EntityReferenceFieldDefaultValueTest::setUp()
Overrides BrowserTestBase::setUp
File
-
core/
modules/ field/ tests/ src/ Functional/ EntityReference/ EntityReferenceFieldDefaultValueTest.php, line 39
Class
- EntityReferenceFieldDefaultValueTest
- Tests entity reference field default values storage in CMI.
Namespace
Drupal\Tests\field\Functional\EntityReferenceCode
protected function setUp() {
parent::setUp();
// Create default content type.
$this->drupalCreateContentType([
'type' => 'reference_content',
]);
$this->drupalCreateContentType([
'type' => 'referenced_content',
]);
// Create admin user.
$this->adminUser = $this->drupalCreateUser([
'access content',
'administer content types',
'administer node fields',
'administer node form display',
'bypass node access',
]);
$this->drupalLogin($this->adminUser);
}
Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.