diff core/modules/comment/tests/src/Functional/CommentTitleTest.php @ 18:af1871eacc83

Update to Drupal core 8.7.1
author Chris Cannam
date Thu, 09 May 2019 15:33:08 +0100
parents 129ea1e6d783
children
line wrap: on
line diff
--- a/core/modules/comment/tests/src/Functional/CommentTitleTest.php	Thu Feb 28 13:21:36 2019 +0000
+++ b/core/modules/comment/tests/src/Functional/CommentTitleTest.php	Thu May 09 15:33:08 2019 +0100
@@ -37,12 +37,12 @@
     $this->assertNull($comment->mail->value);
 
     // Confirm that the comment was created.
-    $regex = '/<a id="comment-' . $comment->id() . '"(.*?)';
+    $regex = '/<article(.*?)id="comment-' . $comment->id() . '"(.*?)';
     $regex .= $comment->comment_body->value . '(.*?)';
     $regex .= '/s';
     $this->assertPattern($regex, 'Comment is created successfully');
     // Tests that markup is not generated for the comment without header.
-    $this->assertNoPattern('|<h3[^>]*></h3>|', 'Comment title H3 element not found when title is an empty string.');
+    $this->assertSession()->responseNotMatches('|<h3[^>]*></h3>|', 'Comment title H3 element not found when title is an empty string.');
   }
 
   /**