/* eslint-disable @typescript-eslint/no-unused-expressions,@typescript-eslint/require-await */
-import 'mocha'
-import { buildUUID } from '@server/helpers/uuid'
import {
checkAbuseStateChange,
checkAutoInstanceFollowing,
checkUserRegistered,
checkVideoAutoBlacklistForModerators,
checkVideoIsPublished,
- cleanupTests,
MockInstancesIndex,
MockSmtpServer,
- PeerTubeServer,
- prepareNotificationsTest,
- wait,
- waitJobs
-} from '@shared/extra-utils'
+ prepareNotificationsTest
+} from '@server/tests/shared'
+import { wait } from '@shared/core-utils'
+import { buildUUID } from '@shared/extra-utils'
import { AbuseState, CustomConfig, UserNotification, UserRole, VideoPrivacy } from '@shared/models'
+import { cleanupTests, PeerTubeServer, waitJobs } from '@shared/server-commands'
describe('Test moderation notifications', function () {
let servers: PeerTubeServer[] = []
})
it('Should send a notification only to admin when there is a new instance follower', async function () {
- this.timeout(20000)
+ this.timeout(60000)
await servers[2].follows.follow({ hosts: [ servers[0].url ] })
})
it('Should not send a notification to moderators on new video without auto-blacklist', async function () {
- this.timeout(60000)
+ this.timeout(120000)
const name = 'video without auto-blacklist ' + buildUUID()