You are here

protected function AdminUserTrait::createAdminUser in Video Embed Field 8

Same name and namespace in other branches
  1. 8.2 tests/src/Functional/AdminUserTrait.php \Drupal\Tests\video_embed_field\Functional\AdminUserTrait::createAdminUser()

Create an admin user.

Return value

\Drupal\user\UserInterface A user with all permissions.

7 calls to AdminUserTrait::createAdminUser()
BundleTest::testMediaBundleCreation in modules/video_embed_media/tests/src/Functional/BundleTest.php
Test the dialog form.
FieldConfigurationTest::testFieldConfiguration in tests/src/Functional/FieldConfigurationTest.php
Test the field configuration form.
FormatterConfigurationTest::setUp in tests/src/Functional/FormatterConfigurationTest.php
InstallationTest::setUp in tests/src/Functional/InstallationTest.php
TextFormatConfigurationTest::setUp in modules/video_embed_wysiwyg/tests/src/Functional/TextFormatConfigurationTest.php

... See full list

File

tests/src/Functional/AdminUserTrait.php, line 20

Class

AdminUserTrait
Create admin users.

Namespace

Drupal\Tests\video_embed_field\Functional

Code

protected function createAdminUser() {
  return $this
    ->drupalCreateUser(array_keys($this->container
    ->get('user.permissions')
    ->getPermissions()));
}