Yaffs site version 1.1
[yaffs-website] / web / modules / contrib / metatag / src / Tests / MetatagStringTest.php
index 9c5beb9d21d2608f79641dcfc0d8b3fcf4759258..385e29a893ce3c9753d3699efe2e29a552a15b67 100644 (file)
@@ -58,8 +58,9 @@ class MetatagStringTest extends WebTestBase {
     $this->drupalCreateContentType(['type' => 'page', 'display_submitted' => FALSE]);
 
     // Add a Metatag field to the content type.
-    $this->drupalGet("admin/structure/types");
-    $this->drupalGet("admin/structure/types/manage/page/fields/add-field");
+    $this->drupalGet('admin/structure/types');
+    $this->assertResponse(200);
+    $this->drupalGet('admin/structure/types/manage/page/fields/add-field');
     $this->assertResponse(200);
     $edit = [
       'label' => 'Metatag',
@@ -118,11 +119,13 @@ class MetatagStringTest extends WebTestBase {
     $desc_encodeded = htmlentities($desc_encoded, ENT_QUOTES);
 
     // Update the Global defaults and test them.
+    $this->drupalGet('admin/config/search/metatag/front');
+    $this->assertResponse(200);
     $values = [
       'title' => $title_original,
       'description' => $desc_original,
     ];
-    $this->drupalPostForm('admin/config/search/metatag/front', $values, 'Save');
+    $this->drupalPostForm(NULL, $values, 'Save');
     $this->assertResponse(200);
 
     $metatag_defaults = \Drupal::config('metatag.metatag_defaults.front');
@@ -144,12 +147,13 @@ class MetatagStringTest extends WebTestBase {
     // token value should be correctly translated.
 
     // Create a node.
-    $this->drupalGet("node/add/page");
+    $this->drupalGet('node/add/page');
+    $this->assertResponse(200);
     $edit = [
       'title[0][value]' => $title_original,
       'body[0][value]' => $desc_original,
     ];
-    $this->drupalPostForm("node/add/page", $edit, t('Save and publish'));
+    $this->drupalPostForm(NULL, $edit, t('Save and publish'));
 
     $this->config('system.site')->set('page.front', '/node/1')->save();