diff --git a/tests/backend/specs/api/sessionsAndGroups.js b/tests/backend/specs/api/sessionsAndGroups.js index 3b5e1a912..bb3e28719 100644 --- a/tests/backend/specs/api/sessionsAndGroups.js +++ b/tests/backend/specs/api/sessionsAndGroups.js @@ -1,3 +1,5 @@ +'use strict'; + const assert = require('assert').strict; const common = require('../../common'); const supertest = require(`${__dirname}/../../../../src/node_modules/supertest`); @@ -14,6 +16,7 @@ let padID = makeid(); describe(__filename, function () { describe('API Versioning', function () { it('errors if can not connect', async function () { + this.timeout(200); await api.get('/api/') .expect(200) .expect((res) => { @@ -55,6 +58,7 @@ describe(__filename, function () { describe('API: Group creation and deletion', function () { it('createGroup', async function () { + this.timeout(100); await api.get(endPoint('createGroup')) .expect(200) .expect('Content-Type', /json/) @@ -66,6 +70,7 @@ describe(__filename, function () { }); it('listSessionsOfGroup for empty group', async function () { + this.timeout(100); await api.get(`${endPoint('listSessionsOfGroup')}&groupID=${groupID}`) .expect(200) .expect('Content-Type', /json/) @@ -76,6 +81,7 @@ describe(__filename, function () { }); it('deleteGroup', async function () { + this.timeout(100); await api.get(`${endPoint('deleteGroup')}&groupID=${groupID}`) .expect(200) .expect('Content-Type', /json/) @@ -85,6 +91,7 @@ describe(__filename, function () { }); it('createGroupIfNotExistsFor', async function () { + this.timeout(100); await api.get(`${endPoint('createGroupIfNotExistsFor')}&groupMapper=management`) .expect(200) .expect('Content-Type', /json/) @@ -97,6 +104,7 @@ describe(__filename, function () { describe('API: Author creation', function () { it('createGroup', async function () { + this.timeout(100); await api.get(endPoint('createGroup')) .expect(200) .expect('Content-Type', /json/) @@ -108,6 +116,7 @@ describe(__filename, function () { }); it('createAuthor', async function () { + this.timeout(100); await api.get(endPoint('createAuthor')) .expect(200) .expect('Content-Type', /json/) @@ -118,6 +127,7 @@ describe(__filename, function () { }); it('createAuthor with name', async function () { + this.timeout(100); await api.get(`${endPoint('createAuthor')}&name=john`) .expect(200) .expect('Content-Type', /json/) @@ -129,6 +139,7 @@ describe(__filename, function () { }); it('createAuthorIfNotExistsFor', async function () { + this.timeout(100); await api.get(`${endPoint('createAuthorIfNotExistsFor')}&authorMapper=chris`) .expect(200) .expect('Content-Type', /json/) @@ -139,6 +150,7 @@ describe(__filename, function () { }); it('getAuthorName', async function () { + this.timeout(100); await api.get(`${endPoint('getAuthorName')}&authorID=${authorID}`) .expect(200) .expect('Content-Type', /json/) @@ -151,6 +163,7 @@ describe(__filename, function () { describe('API: Sessions', function () { it('createSession', async function () { + this.timeout(100); await api.get(`${endPoint('createSession') }&authorID=${authorID}&groupID=${groupID}&validUntil=999999999999`) .expect(200) @@ -163,6 +176,7 @@ describe(__filename, function () { }); it('getSessionInfo', async function () { + this.timeout(100); await api.get(`${endPoint('getSessionInfo')}&sessionID=${sessionID}`) .expect(200) .expect('Content-Type', /json/) @@ -175,6 +189,7 @@ describe(__filename, function () { }); it('listSessionsOfGroup', async function () { + this.timeout(100); await api.get(`${endPoint('listSessionsOfGroup')}&groupID=${groupID}`) .expect(200) .expect('Content-Type', /json/) @@ -185,6 +200,7 @@ describe(__filename, function () { }); it('deleteSession', async function () { + this.timeout(100); await api.get(`${endPoint('deleteSession')}&sessionID=${sessionID}`) .expect(200) .expect('Content-Type', /json/) @@ -194,6 +210,7 @@ describe(__filename, function () { }); it('getSessionInfo of deleted session', async function () { + this.timeout(100); await api.get(`${endPoint('getSessionInfo')}&sessionID=${sessionID}`) .expect(200) .expect('Content-Type', /json/) @@ -205,6 +222,7 @@ describe(__filename, function () { describe('API: Group pad management', function () { it('listPads', async function () { + this.timeout(100); await api.get(`${endPoint('listPads')}&groupID=${groupID}`) .expect(200) .expect('Content-Type', /json/) @@ -215,6 +233,7 @@ describe(__filename, function () { }); it('createGroupPad', async function () { + this.timeout(100); await api.get(`${endPoint('createGroupPad')}&groupID=${groupID}&padName=${padID}`) .expect(200) .expect('Content-Type', /json/) @@ -225,6 +244,7 @@ describe(__filename, function () { }); it('listPads after creating a group pad', async function () { + this.timeout(100); await api.get(`${endPoint('listPads')}&groupID=${groupID}`) .expect(200) .expect('Content-Type', /json/) @@ -237,6 +257,7 @@ describe(__filename, function () { describe('API: Pad security', function () { it('getPublicStatus', async function () { + this.timeout(100); await api.get(`${endPoint('getPublicStatus')}&padID=${padID}`) .expect(200) .expect('Content-Type', /json/) @@ -247,6 +268,7 @@ describe(__filename, function () { }); it('setPublicStatus', async function () { + this.timeout(100); await api.get(`${endPoint('setPublicStatus')}&padID=${padID}&publicStatus=true`) .expect(200) .expect('Content-Type', /json/) @@ -256,6 +278,7 @@ describe(__filename, function () { }); it('getPublicStatus after changing public status', async function () { + this.timeout(100); await api.get(`${endPoint('getPublicStatus')}&padID=${padID}`) .expect(200) .expect('Content-Type', /json/) @@ -272,6 +295,7 @@ describe(__filename, function () { describe('API: Misc', function () { it('listPadsOfAuthor', async function () { + this.timeout(100); await api.get(`${endPoint('listPadsOfAuthor')}&authorID=${authorID}`) .expect(200) .expect('Content-Type', /json/)