]> git.immae.eu Git - github/Chocobozzz/PeerTube.git/blobdiff - server/tests/api/check-params/users.ts
Move to eslint
[github/Chocobozzz/PeerTube.git] / server / tests / api / check-params / users.ts
index 5d5af284c5ea8dab12dffb8b7abf240a6b5c0608..f448bb2a6253aa61cc30fe3b96d5f78ba6f74634 100644 (file)
@@ -1,4 +1,4 @@
-/* tslint:disable:no-unused-expression */
+/* eslint-disable @typescript-eslint/no-unused-expressions,@typescript-eslint/require-await */
 
 import { omit } from 'lodash'
 import 'mocha'
@@ -50,6 +50,7 @@ describe('Test users API validators', function () {
   let serverWithRegistrationDisabled: ServerInfo
   let userAccessToken = ''
   let moderatorAccessToken = ''
+  // eslint-disable-next-line @typescript-eslint/no-unused-vars
   let channelId: number
 
   // ---------------------------------------------------------------
@@ -120,7 +121,7 @@ describe('Test users API validators', function () {
 
     {
       const res = await getMyUserInformation(server.url, server.accessToken)
-      channelId = res.body.videoChannels[ 0 ].id
+      channelId = res.body.videoChannels[0].id
     }
 
     {
@@ -529,7 +530,7 @@ describe('Test users API validators', function () {
     it('Should fail without an incorrect input file', async function () {
       const fields = {}
       const attaches = {
-        'avatarfile': join(__dirname, '..', '..', 'fixtures', 'video_short.mp4')
+        avatarfile: join(__dirname, '..', '..', 'fixtures', 'video_short.mp4')
       }
       await makeUploadRequest({ url: server.url, path: path + '/me/avatar/pick', token: server.accessToken, fields, attaches })
     })
@@ -537,7 +538,7 @@ describe('Test users API validators', function () {
     it('Should fail with a big file', async function () {
       const fields = {}
       const attaches = {
-        'avatarfile': join(__dirname, '..', '..', 'fixtures', 'avatar-big.png')
+        avatarfile: join(__dirname, '..', '..', 'fixtures', 'avatar-big.png')
       }
       await makeUploadRequest({ url: server.url, path: path + '/me/avatar/pick', token: server.accessToken, fields, attaches })
     })
@@ -545,7 +546,7 @@ describe('Test users API validators', function () {
     it('Should fail with an unauthenticated user', async function () {
       const fields = {}
       const attaches = {
-        'avatarfile': join(__dirname, '..', '..', 'fixtures', 'avatar.png')
+        avatarfile: join(__dirname, '..', '..', 'fixtures', 'avatar.png')
       }
       await makeUploadRequest({
         url: server.url,
@@ -559,7 +560,7 @@ describe('Test users API validators', function () {
     it('Should succeed with the correct params', async function () {
       const fields = {}
       const attaches = {
-        'avatarfile': join(__dirname, '..', '..', 'fixtures', 'avatar.png')
+        avatarfile: join(__dirname, '..', '..', 'fixtures', 'avatar.png')
       }
       await makeUploadRequest({
         url: server.url,