protected function EntityReferenceSelectionAccessTest::setUp in Drupal 8
Same name and namespace in other branches
- 9 core/modules/system/tests/src/Functional/Entity/EntityReferenceSelection/EntityReferenceSelectionAccessTest.php \Drupal\Tests\system\Functional\Entity\EntityReferenceSelection\EntityReferenceSelectionAccessTest::setUp()
Overrides KernelTestBase::setUp
File
- core/
modules/ system/ tests/ src/ Functional/ Entity/ EntityReferenceSelection/ EntityReferenceSelectionAccessTest.php, line 55
Class
- EntityReferenceSelectionAccessTest
- Tests for the base handlers provided by Entity Reference.
Namespace
Drupal\Tests\system\Functional\Entity\EntityReferenceSelectionCode
protected function setUp() {
parent::setUp();
$this
->installSchema('system', 'sequences');
$this
->installSchema('comment', [
'comment_entity_statistics',
]);
$this
->installSchema('file', [
'file_usage',
]);
$this
->installEntitySchema('comment');
$this
->installEntitySchema('file');
$this
->installEntitySchema('media');
$this
->installEntitySchema('node');
$this
->installEntitySchema('taxonomy_term');
$this
->installEntitySchema('user');
$this
->installConfig([
'comment',
'field',
'media',
'node',
'taxonomy',
'user',
]);
// Create the anonymous and the admin users.
$anonymous_user = User::create([
'uid' => 0,
'name' => '',
]);
$anonymous_user
->save();
$admin_user = User::create([
'uid' => 1,
'name' => 'admin',
'status' => 1,
]);
$admin_user
->save();
}