From 5d3c5f27977bf8d690a606c65a0f8ce11f4341ed Mon Sep 17 00:00:00 2001 From: Chocobozzz Date: Fri, 19 Nov 2021 08:25:07 +0100 Subject: [PATCH] Fix typo --- server/tests/api/check-params/video-files.ts | 2 +- server/tests/api/notifications/user-notifications.ts | 6 +++--- shared/extra-utils/users/notifications-command.ts | 2 +- shared/extra-utils/users/notifications.ts | 2 +- 4 files changed, 6 insertions(+), 6 deletions(-) diff --git a/server/tests/api/check-params/video-files.ts b/server/tests/api/check-params/video-files.ts index 61936d562..3ccdf5f49 100644 --- a/server/tests/api/check-params/video-files.ts +++ b/server/tests/api/check-params/video-files.ts @@ -20,7 +20,7 @@ describe('Test videos files', function () { // --------------------------------------------------------------- before(async function () { - this.timeout(150_000) + this.timeout(300_000) servers = await createMultipleServers(2) await setAccessTokensToServers(servers) diff --git a/server/tests/api/notifications/user-notifications.ts b/server/tests/api/notifications/user-notifications.ts index e53ab2aa5..468efdf35 100644 --- a/server/tests/api/notifications/user-notifications.ts +++ b/server/tests/api/notifications/user-notifications.ts @@ -61,7 +61,7 @@ describe('Test user notifications', function () { await uploadRandomVideoOnServers(servers, 1) - const notification = await servers[0].notifications.getLastest({ token: userAccessToken }) + const notification = await servers[0].notifications.getLatest({ token: userAccessToken }) expect(notification).to.be.undefined expect(emails).to.have.lengthOf(0) @@ -237,12 +237,12 @@ describe('Test user notifications', function () { }) it('Should not send a notification if the wait transcoding is false', async function () { - this.timeout(50000) + this.timeout(100_000) await uploadRandomVideoOnServers(servers, 2, { waitTranscoding: false }) await waitJobs(servers) - const notification = await servers[0].notifications.getLastest({ token: userAccessToken }) + const notification = await servers[0].notifications.getLatest({ token: userAccessToken }) if (notification) { expect(notification.type).to.not.equal(UserNotificationType.MY_VIDEO_PUBLISHED) } diff --git a/shared/extra-utils/users/notifications-command.ts b/shared/extra-utils/users/notifications-command.ts index 2d79a3747..692420b8b 100644 --- a/shared/extra-utils/users/notifications-command.ts +++ b/shared/extra-utils/users/notifications-command.ts @@ -71,7 +71,7 @@ export class NotificationsCommand extends AbstractCommand { }) } - async getLastest (options: OverrideCommandOptions = {}) { + async getLatest (options: OverrideCommandOptions = {}) { const { total, data } = await this.list({ ...options, start: 0, diff --git a/shared/extra-utils/users/notifications.ts b/shared/extra-utils/users/notifications.ts index 7db4bfd3f..07ccb0f8d 100644 --- a/shared/extra-utils/users/notifications.ts +++ b/shared/extra-utils/users/notifications.ts @@ -727,7 +727,7 @@ async function checkNotification (options: CheckerBaseParams & { const check = options.check || { web: true, mail: true } if (check.web) { - const notification = await server.notifications.getLastest({ token: token }) + const notification = await server.notifications.getLatest({ token: token }) if (notification || checkType !== 'absence') { notificationChecker(notification, checkType)