3 namespace Drupal\Tests\user\Kernel\Migrate;
5 use Drupal\field\Entity\FieldStorageConfig;
6 use Drupal\field\FieldStorageConfigInterface;
7 use Drupal\Tests\migrate_drupal\Kernel\d7\MigrateDrupal7TestBase;
10 * User picture field migration.
14 class MigrateUserPictureFieldTest extends MigrateDrupal7TestBase {
16 public static $modules = ['image', 'file'];
21 protected function setUp() {
23 $this->executeMigration('user_picture_field');
27 * Test the user picture field migration.
29 public function testUserPictureField() {
30 /** @var \Drupal\field\FieldStorageConfigInterface $field_storage */
31 $field_storage = FieldStorageConfig::load('user.user_picture');
32 $this->assertTrue($field_storage instanceof FieldStorageConfigInterface);
33 $this->assertIdentical('user.user_picture', $field_storage->id());
34 $this->assertIdentical('image', $field_storage->getType());
35 $this->assertIdentical('user', $field_storage->getTargetEntityTypeId());