From caacae093d2114f6c46f68aa0deb48d40999b3ce Mon Sep 17 00:00:00 2001 From: barisusakli Date: Tue, 20 Dec 2016 14:05:15 +0300 Subject: [PATCH] fix tests --- test/controllers-admin.js | 8 ++++++++ test/socket.io.js | 2 +- 2 files changed, 9 insertions(+), 1 deletion(-) diff --git a/test/controllers-admin.js b/test/controllers-admin.js index 487e4ed0fb..44c1a7438a 100644 --- a/test/controllers-admin.js +++ b/test/controllers-admin.js @@ -437,6 +437,14 @@ describe('Admin Controllers', function () { }); + it('should load /posts/flags', function (done) { + request(nconf.get('url') + '/api/posts/flags', {jar: jar, json: true}, function (err, res, body) { + assert.ifError(err); + assert(body); + done(); + }); + }) + after(function (done) { db.emptydb(done); }); diff --git a/test/socket.io.js b/test/socket.io.js index 807b371048..b28361cc19 100644 --- a/test/socket.io.js +++ b/test/socket.io.js @@ -395,7 +395,7 @@ describe('socket.io', function () { assert(data.hasOwnProperty('socketCount')); assert(data.hasOwnProperty('topics')); assert(data.hasOwnProperty('users')); - assert.equal(data.topics['1'].title, 'test topic title') + assert.equal(data.topics['1'].title, 'test topic title'); done(); }); }, 1000);