From 033f2f3fdc1a9fd0f2f2b76156e9ac54e1a0d2ed Mon Sep 17 00:00:00 2001 From: Dries Buytaert Date: Thu, 28 May 2009 08:37:29 +0000 Subject: - Patch #335893 by andypost, hexmode: don't show comment information in the RSS feed when a node's comments were disabled. --- modules/comment/comment.test | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'modules/comment/comment.test') diff --git a/modules/comment/comment.test b/modules/comment/comment.test index abe6b4ae6..b7c6abb0d 100644 --- a/modules/comment/comment.test +++ b/modules/comment/comment.test @@ -618,10 +618,17 @@ class CommentRSSUnitTest extends CommentHelperCase { * Test comments as part of an RSS feed. */ function testCommentRSS() { + // Find comment in RSS feed. $this->drupalLogin($this->web_user); $comment = $this->postComment($this->node, $this->randomName(), $this->randomName()); $this->drupalGet('rss.xml'); $raw = '' . url('node/' . $this->node->nid, array('fragment' => 'comments', 'absolute' => TRUE)) . ''; $this->assertRaw($raw, t('Comments as part of RSS feed.')); + + // Hide comments from RSS feed and check presence. + $this->node->comment = COMMENT_NODE_HIDDEN; + node_save($this->node); + $this->drupalGet('rss.xml'); + $this->assertNoRaw($raw, t('Hidden comments is not a part of RSS feed.')); } } -- cgit v1.2.3