From 89ada4e26ca1df8ff0dd02acda1d1661f121a294 Mon Sep 17 00:00:00 2001 From: Chocobozzz Date: Tue, 8 Jan 2019 15:51:52 +0100 Subject: Fix socket.io websocket connection --- server/tests/api/users/index.ts | 4 ++-- server/tests/api/users/user-notifications.ts | 4 +++- server/tests/api/users/users-verification.ts | 3 ++- 3 files changed, 7 insertions(+), 4 deletions(-) (limited to 'server/tests/api/users') diff --git a/server/tests/api/users/index.ts b/server/tests/api/users/index.ts index 63e6e827a..52ba6984e 100644 --- a/server/tests/api/users/index.ts +++ b/server/tests/api/users/index.ts @@ -1,6 +1,6 @@ +import './users-verification' +import './user-notifications' import './blocklist' import './user-subscriptions' -import './user-notifications' import './users' import './users-multiple-servers' -import './users-verification' diff --git a/server/tests/api/users/user-notifications.ts b/server/tests/api/users/user-notifications.ts index ad68d8e69..5260d64cc 100644 --- a/server/tests/api/users/user-notifications.ts +++ b/server/tests/api/users/user-notifications.ts @@ -175,7 +175,7 @@ describe('Test users notifications', function () { }) it('Should send a new video notification if the user follows the local video publisher', async function () { - this.timeout(10000) + this.timeout(15000) await addUserSubscription(servers[0].url, userAccessToken, 'root_channel@localhost:9001') await waitJobs(servers) @@ -1010,6 +1010,8 @@ describe('Test users notifications', function () { }) after(async function () { + MockSmtpServer.Instance.kill() + killallServers(servers) }) }) diff --git a/server/tests/api/users/users-verification.ts b/server/tests/api/users/users-verification.ts index afc8a0059..babeda2b8 100644 --- a/server/tests/api/users/users-verification.ts +++ b/server/tests/api/users/users-verification.ts @@ -4,7 +4,7 @@ import * as chai from 'chai' import 'mocha' import { registerUser, flushTests, getUserInformation, getMyUserInformation, killallServers, - userLogin, login, runServer, ServerInfo, verifyEmail, updateCustomSubConfig + userLogin, login, runServer, ServerInfo, verifyEmail, updateCustomSubConfig, wait } from '../../../../shared/utils' import { setAccessTokensToServers } from '../../../../shared/utils/users/login' import { MockSmtpServer } from '../../../../shared/utils/miscs/email' @@ -123,6 +123,7 @@ describe('Test users account verification', function () { }) after(async function () { + MockSmtpServer.Instance.kill() killallServers([ server ]) // Keep the logs if the test failed -- cgit v1.2.3