2
0
Fork 0
mirror of https://github.com/discourse/discourse.git synced 2025-09-05 08:59:27 +08:00

improving flag handling, links and delete button

This commit is contained in:
Sam Saffron 2013-02-07 16:00:40 +11:00
parent c7461622a9
commit 7b123e12dd
5 changed files with 34 additions and 8 deletions

View file

@ -63,15 +63,10 @@ describe Post do
post = Fabricate(:post)
user = Fabricate(:coding_horror)
PostAction.act(user, post, PostActionType.Types[:off_topic])
PostAction.act(post.user, post, PostActionType.Types[:spam])
post.reload
post.is_flagged?.should == true
PostAction.remove_act(post.user, post, PostActionType.Types[:spam])
post.reload
post.is_flagged?.should == true
PostAction.remove_act(user, post, PostActionType.Types[:off_topic])
post.reload
post.is_flagged?.should == false