Skip to content

Commit

Permalink
fix: manifest test + remove duplicate test
Browse files Browse the repository at this point in the history
  • Loading branch information
psychobunny committed Sep 29, 2020
1 parent 3fbddbe commit bf3c1c0
Showing 1 changed file with 6 additions and 15 deletions.
21 changes: 6 additions & 15 deletions test/controllers.js
Expand Up @@ -359,8 +359,8 @@ describe('Controllers', function () {
});
});

it('should load /manifest.json', function (done) {
request(nconf.get('url') + '/manifest.json', function (err, res, body) {
it('should load /manifest.webmanifest', function (done) {
request(nconf.get('url') + '/manifest.webmanifest', function (err, res, body) {
assert.ifError(err);
assert.equal(res.statusCode, 200);
assert(body);
Expand Down Expand Up @@ -633,15 +633,6 @@ describe('Controllers', function () {
});
});

it('should load manifest.json', function (done) {
request(nconf.get('url') + '/manifest.json', function (err, res, body) {
assert.ifError(err);
assert.equal(res.statusCode, 200);
assert(body);
done();
});
});

it('should load theme screenshot', function (done) {
request(nconf.get('url') + '/css/previews/nodebb-theme-persona', function (err, res, body) {
assert.ifError(err);
Expand Down Expand Up @@ -1413,7 +1404,7 @@ describe('Controllers', function () {
});

it('should not increase profile view if a guest visits a profile', (done) => {
request(nconf.get('url') + '/api/user/foo', { }, function (err, res) {
request(nconf.get('url') + '/api/user/foo', {}, function (err, res) {
assert.ifError(err);
assert.equal(res.statusCode, 200);
setTimeout(function () {
Expand Down Expand Up @@ -1751,7 +1742,7 @@ describe('Controllers', function () {
},
});

request(nconf.get('url') + '/users', { }, function (err, res) {
request(nconf.get('url') + '/users', {}, function (err, res) {
plugins.loadedHooks['filter:router.page'] = [];
assert.ifError(err);
assert.equal(res.statusCode, 403);
Expand All @@ -1769,7 +1760,7 @@ describe('Controllers', function () {
},
});

request(nconf.get('url') + '/users', { }, function (err, res, body) {
request(nconf.get('url') + '/users', {}, function (err, res, body) {
plugins.loadedHooks['filter:router.page'] = [];
assert.ifError(err);
assert.equal(res.statusCode, 403);
Expand All @@ -1790,7 +1781,7 @@ describe('Controllers', function () {
},
});

request(nconf.get('url') + '/users', { }, function (err, res, body) {
request(nconf.get('url') + '/users', {}, function (err, res, body) {
assert.ifError(err);
assert.equal(res.statusCode, 200);
assert(body);
Expand Down

0 comments on commit bf3c1c0

Please sign in to comment.