diff options
author | xjm | 2018-07-02 16:26:17 (GMT) |
---|---|---|
committer | xjm | 2018-07-02 16:26:17 (GMT) |
commit | 3564dd559ebb82692b19a79af0911f938592bfb0 (patch) | |
tree | 0af12229956474f65fadc9db1f4eca45fe4168b5 /core/modules/migrate_drupal | |
parent | 6312fcbe67cc475a4294124715cacf9f272490d9 (diff) |
Issue #2976889 by phenaproxima, xjm, chr.fritsch, samuel.mortenson, larowlan, alexpott: Add a trait to create media types in tests and replace MediaFunctionalTestCreateMediaTypeTrait
Diffstat (limited to 'core/modules/migrate_drupal')
-rw-r--r-- | core/modules/migrate_drupal/tests/src/Kernel/Plugin/migrate/source/ContentEntityTest.php | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/core/modules/migrate_drupal/tests/src/Kernel/Plugin/migrate/source/ContentEntityTest.php b/core/modules/migrate_drupal/tests/src/Kernel/Plugin/migrate/source/ContentEntityTest.php index 095de33..1bcedcf 100644 --- a/core/modules/migrate_drupal/tests/src/Kernel/Plugin/migrate/source/ContentEntityTest.php +++ b/core/modules/migrate_drupal/tests/src/Kernel/Plugin/migrate/source/ContentEntityTest.php @@ -16,7 +16,7 @@ use Drupal\node\Entity\Node; use Drupal\node\Entity\NodeType; use Drupal\taxonomy\Entity\Term; use Drupal\taxonomy\Entity\Vocabulary; -use Drupal\Tests\media\Functional\MediaFunctionalTestCreateMediaTypeTrait; +use Drupal\Tests\media\Traits\MediaTypeCreationTrait; use Drupal\user\Entity\User; /** @@ -27,7 +27,7 @@ use Drupal\user\Entity\User; class ContentEntityTest extends KernelTestBase { use EntityReferenceTestTrait; - use MediaFunctionalTestCreateMediaTypeTrait; + use MediaTypeCreationTrait; /** * {@inheritdoc} @@ -339,12 +339,11 @@ class ContentEntityTest extends KernelTestBase { public function testMediaSource() { $values = [ 'id' => 'image', - 'bundle' => 'image', 'label' => 'Image', 'source' => 'test', 'new_revision' => FALSE, ]; - $media_type = $this->createMediaType($values); + $media_type = $this->createMediaType('test', $values); $media = Media::create([ 'name' => 'Foo media', 'uid' => $this->user->id(), |