]> git.immae.eu Git - github/Chocobozzz/PeerTube.git/blobdiff - server/tests/api/videos/video-nsfw.ts
Merge branch 'release/4.3.0' into develop
[github/Chocobozzz/PeerTube.git] / server / tests / api / videos / video-nsfw.ts
index b5d183d6278deabca0acea74c4390a238d2846e0..65e9c8730b9a80cbd51487d4453978965569bcc8 100644 (file)
@@ -1,12 +1,9 @@
 /* eslint-disable @typescript-eslint/no-unused-expressions,@typescript-eslint/require-await */
 
-import 'mocha'
-import * as chai from 'chai'
-import { cleanupTests, createSingleServer, PeerTubeServer, setAccessTokensToServers } from '@shared/extra-utils'
+import { expect } from 'chai'
+import { cleanupTests, createSingleServer, PeerTubeServer, setAccessTokensToServers } from '@shared/server-commands'
 import { BooleanBothQuery, CustomConfig, ResultList, Video, VideosOverview } from '@shared/models'
 
-const expect = chai.expect
-
 function createOverviewRes (overview: VideosOverview) {
   const videos = overview.categories[0].videos
   return { data: videos, total: videos.length }
@@ -136,7 +133,7 @@ describe('Test video NSFW policy', function () {
     it('Should create a user having the default nsfw policy', async function () {
       const username = 'user1'
       const password = 'my super password'
-      await server.users.create({ username: username, password: password })
+      await server.users.create({ username, password })
 
       userAccessToken = await server.login.getAccessToken({ username, password })