Skip to content

Node.js based forum software built for the modern web

added test for User.blocks.is, re: #6463

Julian Lam322d8236d27d
diff --git a/test/user.js b/test/user.js
index 1b3ef100d8..bf91604514 100644
--- a/test/user.js
+++ b/test/user.js
@@ -1790,6 +1790,16 @@ describe('User', function () {
});
});
+ describe('.is()', function () {
+ it('should return a Boolean with blocked status for the queried uid', function (done) {
+ User.blocks.is(blockeeUid, 1, function (err, blocked) {
+ assert.ifError(err);
+ assert.strictEqual(blocked, true);
+ done();
+ });
+ });
+ });
+
describe('.list()', function () {
it('should return a list of blocked uids', function (done) {
User.blocks.list(1, function (err, blocked_uids) {