diff --git a/Tests/spec/CalDAVPreventInvitationsSpec.js b/Tests/spec/CalDAVPreventInvitationsSpec.js index 23155b190..506c4560c 100644 --- a/Tests/spec/CalDAVPreventInvitationsSpec.js +++ b/Tests/spec/CalDAVPreventInvitationsSpec.js @@ -136,7 +136,7 @@ describe('PreventInvitations', function() { .toBe(0) await _addAttendee() await _verifyEvent() - }, config.timeout || 10000) + }) it(`Enable, refuse the invitation`, async function() { // Second, enable PreventInviation and refuse it @@ -148,7 +148,7 @@ describe('PreventInvitations', function() { .toBe(1) await _addAttendee(409) await _verifyEvent(404) - }, config.timeout || 10000) + }) it(`Enable, update whitelist, accept the invitation`, async function() { // First, add the Organiser to the Attendee's whitelist @@ -165,5 +165,5 @@ describe('PreventInvitations', function() { // Second, try again to invite, it should work await _addAttendee() await _verifyEvent() - }, config.timeout || 10000) + }) }) \ No newline at end of file diff --git a/Tests/spec/CalDAVPropertiesSpec.js b/Tests/spec/CalDAVPropertiesSpec.js index 94a4e4618..dff2d1296 100644 --- a/Tests/spec/CalDAVPropertiesSpec.js +++ b/Tests/spec/CalDAVPropertiesSpec.js @@ -24,7 +24,7 @@ describe('read and set calendar properties', function() { expect(response[0].status) .withContext(`HTTP status code of MKCALENDAR`) .toEqual(405) - }, config.timeout || 10000) + }) // CalDAVPropertiesTest @@ -40,7 +40,7 @@ describe('read and set calendar properties', function() { expect(Object.keys(prop.scheduleCalendarTransp).includes('opaque')) .withContext('schedule-calendar-transp is "opaque" on new') .toBeTrue() - }, config.timeout || 10000) + }) it("proppatch", async function() { let newValueNode @@ -69,7 +69,7 @@ describe('read and set calendar properties', function() { expect(results[0].status) .withContext(`Setting transparency to ${newValueNode} is successful`) .toBe(207) - }, config.timeout || 10000) + }) it("calendar-query", async function() { const filename = `new.ics` @@ -129,5 +129,5 @@ END:VCALENDAR` expect(utility.componentsAreEqual(response[0].props.calendarData, event)) .withContext(`Returned vCalendar matches ${filename}`) .toBe(true) - }, config.timeout || 10000) + }) }) \ No newline at end of file diff --git a/Tests/spec/CalDAVSchedulingSpec.js b/Tests/spec/CalDAVSchedulingSpec.js index ea82f7373..b2cf76abf 100644 --- a/Tests/spec/CalDAVSchedulingSpec.js +++ b/Tests/spec/CalDAVSchedulingSpec.js @@ -167,7 +167,7 @@ describe('CalDAV Scheduling', function() { expect(veventAttendee.getFirstProperty('uid').getFirstValue()) .withContext(`UID in organizer's calendar and attendees's calendar are identical`) .toBe(vevent.getFirstProperty('uid').getFirstValue()) - }, config.timeout || 10000) + }) it('Remove attendee after event creation', async function() { const icsName = 'test-remove-attendee.ics' @@ -217,7 +217,7 @@ describe('CalDAV Scheduling', function() { // 6. verify that the attendee doesn't have the event anymore await _getEvent(webdavAttendee1, attendee1Calendar, icsName, 404) - }, config.timeout || 10000) + }) it('try to overbook a resource', async function() { const icsName = 'test-no-overbook.ics' @@ -264,7 +264,7 @@ describe('CalDAV Scheduling', function() { // put the event - should trigger a 409 await _putEvent(webdav, userCalendar, obIcsName, vcalendar, 409) - }, config.timeout || 10000) + }) it('try to overbook a resource - multiplebookings=0', async function() { const icsName = 'test-can-overbook.ics' @@ -311,7 +311,7 @@ describe('CalDAV Scheduling', function() { // put the event - should be fine since we can overbook this one await _putEvent(webdav, userCalendar, obIcsName, vcalendar) - }, config.timeout || 10000) + }) it('Resource booking overlap detection - bug #1837', async function() { // There used to be some problems with recurring events and resources booking @@ -412,7 +412,7 @@ describe('CalDAV Scheduling', function() { vevent.addProperty(utility.createDateTimeProperty('dtend', nenddate)) vevent.updatePropertyWithValue('uid', 'recurring - nooverlap') await _putEvent(webdav, userCalendar, overlapRecurringIcsName, vcalendarNoOverlap, 409) - }, config.timeout || 10000) + }) it('RRULE exception invitation dance', async function() { // This workflow is based on what lightning 1.2.1 does @@ -545,7 +545,7 @@ describe('CalDAV Scheduling', function() { vcalendarOrganizer.removeSubcomponent(veventException) await _putEvent(webdav, userCalendar, icsName, vcalendarOrganizer, 204) await _getEvent(webdavAttendee1, attendee1Calendar, icsName, 404) - }, config.timeout || 10000) + }) it ('RRULE invitation delete exdate dance', async function() { // Workflow: @@ -662,7 +662,7 @@ describe('CalDAV Scheduling', function() { expect(attendee.getParameter('partstat')) .withContext('Partstat of attendee is declined for the exception') .toBe('DECLINED') - }, config.timeout || 10000) + }) it('iCal organizer is attendee - bug #1839', async function() { const icsName = 'test-organizer-is-attendee.ics' @@ -713,7 +713,7 @@ describe('CalDAV Scheduling', function() { .withContext(`Organizer is not an attendee`) .not.toBe(user.email) } - }, config.timeout || 10000) + }) it('PUT 2 events with the same UID - bug #1853', async function () { const icsName = 'test-same-uid.ics' @@ -735,7 +735,7 @@ describe('CalDAV Scheduling', function() { // PUT the same event with a new filename - should trigger a 409 await _putEvent(webdav, userCalendar, conflictIcsName, vcalendar, 409) - }, config.timeout || 10000) + }) it('invitation delegation', async function () { const icsName = 'test-delegation.ics' @@ -937,5 +937,5 @@ describe('CalDAV Scheduling', function() { vcalendarInvitationAttendee = await _getEvent(webdavAttendee1, attendee1Calendar, icsName, 404) vcalendarInvitationDelegate = await _getEvent(webdavAttendee1Delegate, attendee1DelegateCalendar, icsName, 404) - }, config.timeout || 10000) // increase timeout for this long test + }) // increase timeout for this long test }) \ No newline at end of file diff --git a/Tests/spec/CardDAVSpec.js b/Tests/spec/CardDAVSpec.js index f302113bb..398e16c4b 100644 --- a/Tests/spec/CardDAVSpec.js +++ b/Tests/spec/CardDAVSpec.js @@ -106,7 +106,7 @@ describe('CardDAV extensions', function() { expect(response[0].status) .withContext(`HTTP status code of MKCOL`) .toEqual(405) - }, config.timeout || 10000) + }) // CARDDAV:addressbook-query Report // https://datatracker.ietf.org/doc/html/rfc6352#section-8.6 @@ -170,7 +170,7 @@ describe('CardDAV extensions', function() { expect(utility.componentsAreEqual(response[0].props.addressData, cards[name])) .withContext(`Returned vCard matches ${name}`) .toBe(true) - }, config.timeout || 10000) + }) // CARDDAV:addressbook-query Report // https://datatracker.ietf.org/doc/html/rfc6352#section-8.6 @@ -236,7 +236,7 @@ describe('CardDAV extensions', function() { expect(emails) .withContext(`Returned vCard has email of ${config.attendee1_username} (${config.attendee1})`) .toContain(config.attendee1) - }, config.timeout || 10000) // increase timeout for this long test + }) // increase timeout for this long test // CARDDAV:addressbook-multiget Report // https://datatracker.ietf.org/doc/html/rfc6352#section-8.7 @@ -270,5 +270,5 @@ describe('CardDAV extensions', function() { .withContext(`Cards returned in addressbook-multiget`) .toBe(true) } - }, config.timeout || 10000) + }) }) \ No newline at end of file diff --git a/Tests/spec/ConfigSpec.js b/Tests/spec/ConfigSpec.js index 13d9955a2..82c550c0b 100644 --- a/Tests/spec/ConfigSpec.js +++ b/Tests/spec/ConfigSpec.js @@ -38,5 +38,5 @@ describe('config tests', function() { .toBeUndefined() userHash[user] = true } - }, config.timeout || 10000) + }) }) \ No newline at end of file diff --git a/Tests/spec/DAVAddressBookAclSpec.js b/Tests/spec/DAVAddressBookAclSpec.js index 22e6cb751..972003ad7 100644 --- a/Tests/spec/DAVAddressBookAclSpec.js +++ b/Tests/spec/DAVAddressBookAclSpec.js @@ -214,33 +214,33 @@ END:VCARD` it("'view' only", async function() { await _testRights({ v: true }) - }, config.timeout || 10000) + }) it("'edit' only", async function() { await _testRights({ e: true }) - }, config.timeout || 10000) + }) it("'create' only", async function() { await _testRights({ c: true }) - }, config.timeout || 10000) + }) it("'delete' only", async function() { await _testRights({ d: true }) - }, config.timeout || 10000) + }) it("'create', 'delete'", async function() { await _testRights({ c: true, d: true }) - }, config.timeout || 10000) + }) it("'view', 'delete'", async function() { await _testRights({ v: true, d: true }) - }, config.timeout || 10000) + }) it("'edit', 'create'", async function() { await _testRights({ c: true, e: true }) - }, config.timeout || 10000) + }) it("'edit', 'delete'", async function() { await _testRights({ d: true, e: true }) - }, config.timeout || 10000) + }) }) \ No newline at end of file diff --git a/Tests/spec/DAVCalendarAclSpec.js b/Tests/spec/DAVCalendarAclSpec.js index bffb1f043..c6e1e3115 100644 --- a/Tests/spec/DAVCalendarAclSpec.js +++ b/Tests/spec/DAVCalendarAclSpec.js @@ -427,30 +427,30 @@ END:VCALENDAR` it("'view all' on a specific class (PUBLIC)", async function() { await _testRights({ pu: 'v' }) - }, config.timeout || 10000) + }) it("'modify' PUBLIC, 'view all' PRIVATE, 'view d&t' confidential", async function() { await _testRights({ pu: 'm', pr: 'v', co: 'd' }) - }, config.timeout || 10000) + }) it("'create' only", async function() { await _testRights({ c: true }) - }, config.timeout || 10000) + }) it("'delete' only", async function() { await _testRights({ d: true }) - }, config.timeout || 10000) + }) it("'create', 'delete', 'view d&t' PUBLIC, 'modify' PRIVATE", async function() { await _testRights({ c: true, d: true, pu: 'd', pr: 'm' }) - }, config.timeout || 10000) + }) it("'create', 'respond to' PUBLIC", async function() { await _testRights({ c: true, pu: 'r' }) - }, config.timeout || 10000) + }) it("no right given", async function() { await _testRights({}) - }, config.timeout || 10000) + }) }) \ No newline at end of file diff --git a/Tests/spec/DAVCalendarAppleiCalSpec.js b/Tests/spec/DAVCalendarAppleiCalSpec.js index ab8a2bfd1..83d24acdc 100644 --- a/Tests/spec/DAVCalendarAppleiCalSpec.js +++ b/Tests/spec/DAVCalendarAppleiCalSpec.js @@ -135,7 +135,7 @@ describe('Apple iCal', function() { .withContext(`DAV header includes class ${davClass}`) .toBeTrue() } - }, config.timeout || 10000) + }) it(`calendar-proxy as used from iCal`, async function() { let membership, perm, users, proxyFor @@ -179,7 +179,7 @@ describe('Apple iCal', function() { expect(proxyFor).toContain(`/SOGo/dav/${owner}/`) } } - }, config.timeout || 10000) + }) it('calendar-proxy as used from SOGo', async function() { const personalResource = `/SOGo/dav/${config.username}/Calendar/personal/` @@ -233,5 +233,5 @@ describe('Apple iCal', function() { .toBe(0) await webdav_su.deleteObject(otherResource) - }, config.timeout || 10000) // increase timeout for this long test + }) // increase timeout for this long test }) \ No newline at end of file diff --git a/Tests/spec/DAVCalendarClassificationSpec.js b/Tests/spec/DAVCalendarClassificationSpec.js index 0cac33ac4..008144437 100644 --- a/Tests/spec/DAVCalendarClassificationSpec.js +++ b/Tests/spec/DAVCalendarClassificationSpec.js @@ -39,7 +39,7 @@ describe('calendar classification', function() { expect(status) .withContext('Setting an invalid classification') .toBe(403) - }, config.timeout || 10000) + }) it('setting a valid classification', async function() { for (let component of ['events', 'tasks']) { @@ -50,5 +50,5 @@ describe('calendar classification', function() { .toBe(207) } } - }, config.timeout || 10000) + }) }) \ No newline at end of file diff --git a/Tests/spec/DAVCalendarPublicAclSpec.js b/Tests/spec/DAVCalendarPublicAclSpec.js index 127d129c7..c87a261b8 100644 --- a/Tests/spec/DAVCalendarPublicAclSpec.js +++ b/Tests/spec/DAVCalendarPublicAclSpec.js @@ -154,7 +154,7 @@ describe('public access', function() { .withContext('First href must be the Calendar parent collection') .toBe(parentColl) - }, config.timeout || 10000) + }) it("user accessing (non-)shared Calendars", async function() { const parentColl = `/SOGo/dav/${config.subscriber_username}/Calendar/` @@ -180,6 +180,6 @@ describe('public access', function() { expect(href) .withContext('Unique href must be the Calendar parent collection') .toBe(parentColl) - }, config.timeout || 10000) + }) }) \ No newline at end of file diff --git a/Tests/spec/DAVCalendarSuperUserAclSpec.js b/Tests/spec/DAVCalendarSuperUserAclSpec.js index 2de845089..24206a1a3 100644 --- a/Tests/spec/DAVCalendarSuperUserAclSpec.js +++ b/Tests/spec/DAVCalendarSuperUserAclSpec.js @@ -115,6 +115,6 @@ END:VCALENDAR` // 4. Delete const response = await webdav_su.deleteObject(resource) expect(response.status).toBe(204) - }, config.timeout || 10000) + }) }) \ No newline at end of file diff --git a/Tests/spec/DAVContactsCategoriesSpec.js b/Tests/spec/DAVContactsCategoriesSpec.js index 42ae498d2..434fc5071 100644 --- a/Tests/spec/DAVContactsCategoriesSpec.js +++ b/Tests/spec/DAVContactsCategoriesSpec.js @@ -68,5 +68,5 @@ describe('contacts categories', function() { .toContain('Toto') expect(results) .toContain('Cuicui') - }, config.timeout || 10000) + }) }) \ No newline at end of file diff --git a/Tests/spec/DAVPublicAccessSpec.js b/Tests/spec/DAVPublicAccessSpec.js index 7e77a66bc..5685b4af2 100644 --- a/Tests/spec/DAVPublicAccessSpec.js +++ b/Tests/spec/DAVPublicAccessSpec.js @@ -15,21 +15,21 @@ describe('public access', function() { expect(status) .withContext('/SOGo/so/public must not be accessible') .toBe(404) - }, config.timeout || 10000) + }) it("access to /SOGo/public", async function() { const [{ status }] = await webdav_anon.options('/SOGo/public') expect(status) .withContext('/SOGo/public must not be accessible') .toBe(404) - }, config.timeout || 10000) + }) it("access to non-public resource", async function() { const [{ status }] = await webdav_anon.options(`/SOGo/dav/${config.username}`) expect(status) .withContext('DAV non-public resources should request authentication') .toBe(401) - }, config.timeout || 10000) + }) it("access to public resource", async function() { const [{ status }] = await webdav_anon.options('/SOGo/dav/public') @@ -39,5 +39,5 @@ describe('public access', function() { expect(status) .withContext('DAV public resources must be accessible') .toBe(200) - }, config.timeout || 10000) + }) }) \ No newline at end of file diff --git a/Tests/spec/HTTPCalendarSpec.js b/Tests/spec/HTTPCalendarSpec.js index 45583685a..be75f7ec8 100644 --- a/Tests/spec/HTTPCalendarSpec.js +++ b/Tests/spec/HTTPCalendarSpec.js @@ -49,6 +49,6 @@ describe('HTTP Calendar', function() { expect(response.status) .withContext(`HTTP status code when unsubscribing to a Web calendar`) .toBe(204) - }, config.timeout || 10000) + }) }) diff --git a/Tests/spec/HTTPPreferencesSpec.js b/Tests/spec/HTTPPreferencesSpec.js index e7b6b86d8..9408e50f9 100644 --- a/Tests/spec/HTTPPreferencesSpec.js +++ b/Tests/spec/HTTPPreferencesSpec.js @@ -30,12 +30,12 @@ describe('preferences', function() { it('Set/get a text preference - normal characters', async function() { await _setTextPref('defaultText') - }, config.timeout || 10000) + }) it('Set/get a text preference - weird characters - used to crash on 1.3.12', async function() { const prefText = `weird data \ ' \"; ^` await _setTextPref(prefText) - }, config.timeout || 10000) + }) it('Set/get the PreventInvitation pref', async function() { await prefs.set('PreventInvitations', 0) @@ -48,7 +48,7 @@ describe('preferences', function() { expect(isset.PreventInvitations) .withContext(`Set/get Settings/Calendar/PreventInvitations (1)`) .toEqual(1) - }, config.timeout || 10000) + }) it('Set/get the PreventInvitations Whitelist', async function() { await prefs.set('PreventInvitationsWhitelist', config.white_listed_attendee) @@ -56,5 +56,5 @@ describe('preferences', function() { expect(whitelist.PreventInvitationsWhitelist) .withContext(`Set/get Settings/Calendar/PreventInvitationsWhitelist`) .toEqual(config.white_listed_attendee) - }, config.timeout || 10000) + }) })