mirror of
https://github.com/OrchardCMS/Orchard.git
synced 2026-02-09 09:16:41 +08:00
Refactoring anti-spam feature in comments
--HG-- branch : 1.x extra : rebase_source : c24f16db4b03f676c261aa7a959f85ac2ac0a09c
This commit is contained in:
@@ -105,20 +105,6 @@ namespace Orchard.Tests.Modules.Comments.Services {
|
||||
Assert.That(_commentService.GetCommentedContent(commentId), Is.Not.Null);
|
||||
}
|
||||
|
||||
[Test]
|
||||
public void UpdateShouldChangeComment() {
|
||||
var commentedItem = _contentManager.New("commentedItem");
|
||||
_contentManager.Create(commentedItem);
|
||||
_contentManager.Create(commentedItem, VersionOptions.Published);
|
||||
int commentId = commentedItem.As<CommentPart>().Id;
|
||||
|
||||
Assert.That(_commentService.GetComment(commentId).Record.Author, Is.Null.Or.Empty);
|
||||
|
||||
_commentService.UpdateComment(commentId, "test", "", "", "new text", CommentStatus.Pending);
|
||||
|
||||
Assert.That(_commentService.GetComment(commentId).Record.Author, Is.EqualTo("test"));
|
||||
}
|
||||
|
||||
[Test]
|
||||
public void CommentsShouldBePendingByDefault() {
|
||||
var commentedItem = _contentManager.New("commentedItem");
|
||||
|
||||
Reference in New Issue
Block a user