If you edit a comment in Drupal 8 the title of the page is "Comment permalink"

comment_title.png

In Drupal 7 this used to be "Edit"

$items['comment/%comment/edit'] = array(
    'title' => 'Edit',
    'page callback' => 'comment_edit_page',
    'page arguments' => array(1),
    'access callback' => 'comment_access',
    'access arguments' => array('edit', 1),
    'type' => MENU_LOCAL_TASK,
    'weight' => 0,
  );

There is no hook_menu in Drupal 8 because the route has been converted.

Support from Acquia helps fund testing for Drupal Acquia logo

Comments

larowlan’s picture

Component: configuration system » comment.module
larowlan’s picture

Assigned: Unassigned » larowlan
larowlan’s picture

Assigned: larowlan » Unassigned
Status: Active » Needs review
FileSize
1.84 KB
896 bytes

going for red/green

Status: Needs review » Needs work
Issue tags: -Novice, -WSSCI Conversion

The last submitted patch, comment-perma-2085435.pass_.patch, failed testing.

larowlan’s picture

Status: Needs work » Needs review
Issue tags: +Novice, +WSSCI Conversion

#3: comment-perma-2085435.fail_.patch queued for re-testing.

larowlan’s picture

Random fails on the 'fails' test.

larowlan’s picture

Fixes for preview

jibran’s picture

Status: Needs review » Reviewed & tested by the community

RTBC if green.

Status: Reviewed & tested by the community » Needs work
Issue tags: -Novice, -WSSCI Conversion

The last submitted patch, comment-perma-2085435.2.patch, failed testing.

larowlan’s picture

Status: Needs work » Needs review
Issue tags: +Novice, +WSSCI Conversion

#7: comment-perma-2085435.2.patch queued for re-testing.

jibran’s picture

Status: Needs review » Reviewed & tested by the community

Back to RTBC.

webchick’s picture

Status: Reviewed & tested by the community » Needs review
+++ b/core/modules/comment/lib/Drupal/comment/Tests/CommentInterfaceTest.php
@@ -68,6 +68,9 @@ function testCommentInterface() {
     // Test changing the comment author to "Anonymous".
     $this->drupalGet('comment/' . $comment->id() . '/edit');
+    $this->assertTitle(t('Edit comment @title | Drupal', array(
+      '@title' => $comment->subject->value,
+    )));

Hm. I realize that we normally introduce tests for regressions, but here it seems a bit weird thing to test for. Also, it really doesn't make much sense under a comment titled "Test changing the comment author to anonymous."

IMO we should drop the test, or else abstract it somehow but I can't really imagine how.

dawehner’s picture

This test function tests quite a bunch of different cases, so what about just moving the comment a little bit around?

star-szr’s picture

Issue tags: -WSSCI Conversion

Tag fix, WSSCI -> WSCCI.

star-szr’s picture

Issue tags: +WSCCI-conversion

Sorry for the noise, didn't check autocomplete.

jibran’s picture

Status: Needs review » Reviewed & tested by the community

Putting back to RTBC after #13 let's see what @webchick thinks about the patch now.

webchick’s picture

Status: Reviewed & tested by the community » Fixed

Cool, that works for me!

Committed and pushed to 8.x. Thanks!

Automatically closed -- issue fixed for 2 weeks with no activity.