Updated to Drupal 8.5. Core Media not yet in use.
[yaffs-website] / web / modules / contrib / metatag / tests / src / Functional / EnsureDevelWorks.php
diff --git a/web/modules/contrib/metatag/tests/src/Functional/EnsureDevelWorks.php b/web/modules/contrib/metatag/tests/src/Functional/EnsureDevelWorks.php
new file mode 100644 (file)
index 0000000..fa392f2
--- /dev/null
@@ -0,0 +1,58 @@
+<?php
+
+namespace Drupal\Tests\metatag\Functional;
+
+use Drupal\Tests\BrowserTestBase;
+
+/**
+ * Verify that enabling Devel don't cause the site to blow up.
+ *
+ * @group metatag
+ */
+class EnsureDevelWorks extends BrowserTestBase {
+
+  // Contains helper methods.
+  use MetatagHelperTrait;
+
+  /**
+   * {@inheritdoc}
+   */
+  public static $modules = [
+    // Modules for core functionality.
+    'node',
+    'field',
+    'field_ui',
+    'user',
+
+    // Contrib dependencies.
+    'token',
+
+    // This module.
+    'metatag',
+
+    // Use the custom route to verify the site works.
+    'metatag_test_custom_route',
+
+    // The modules to test.
+    'devel',
+  ];
+
+  /**
+   * Load the custom route, make sure something is output.
+   */
+  public function testCustomRoute() {
+    $this->drupalGet('metatag_test_custom_route');
+    $this->assertResponse(200);
+    $this->assertText('Hello world!');
+  }
+
+  /**
+   * Make sure that the system still works when some example content exists.
+   */
+  public function testNode() {
+    $node = $this->createContentTypeNode();
+    $this->drupalGet($node->toUrl());
+    $this->assertResponse(200);
+  }
+
+}