summaryrefslogtreecommitdiffstats
path: root/tests/linkit_media_test/src/Plugin/MediaEntity/Type/TestType.php
diff options
context:
space:
mode:
Diffstat (limited to 'tests/linkit_media_test/src/Plugin/MediaEntity/Type/TestType.php')
-rw-r--r--tests/linkit_media_test/src/Plugin/MediaEntity/Type/TestType.php27
1 files changed, 27 insertions, 0 deletions
diff --git a/tests/linkit_media_test/src/Plugin/MediaEntity/Type/TestType.php b/tests/linkit_media_test/src/Plugin/MediaEntity/Type/TestType.php
new file mode 100644
index 0000000..a14b5cb
--- /dev/null
+++ b/tests/linkit_media_test/src/Plugin/MediaEntity/Type/TestType.php
@@ -0,0 +1,27 @@
+<?php
+
+namespace Drupal\linkit_media_test\Plugin\MediaEntity\Type;
+
+use Drupal\media_entity\Plugin\MediaEntity\Type\Generic;
+
+/**
+ * Provides generic media type.
+ *
+ * @MediaType(
+ * id = "test_type",
+ * label = @Translation("Test type"),
+ * description = @Translation("Test media type.")
+ * )
+ */
+class TestType extends Generic {
+
+ /**
+ * {@inheritdoc}
+ */
+ public function defaultConfiguration() {
+ return [
+ 'source_field' => 'field_media_file',
+ ];
+ }
+
+}