posts/delete cleanup

This commit is contained in:
Barış Soner Uşaklı
2018-10-30 19:41:06 -04:00
parent 0de60cfdca
commit d3e4daebec
2 changed files with 37 additions and 66 deletions

View File

@@ -73,6 +73,14 @@ describe('Post\'s', function () {
});
});
it('should return falsy if post does not exist', function (done) {
posts.getPostData(9999, function (err, postData) {
assert.ifError(err);
assert.equal(postData, null);
done();
});
});
describe('voting', function () {
it('should fail to upvote post if group does not have upvote permission', function (done) {
privileges.categories.rescind(['posts:upvote', 'posts:downvote'], cid, 'registered-users', function (err) {