]> git.immae.eu Git - github/Chocobozzz/PeerTube.git/blobdiff - server/tests/api/videos/single-server.ts
Add ability to update some configuration keys
[github/Chocobozzz/PeerTube.git] / server / tests / api / videos / single-server.ts
index 2a3126f3258df29ace508ab6c18d00dc458ff18f..ca20f39a096b82a01f48c67ed9bb42f952e3442f 100644 (file)
@@ -5,9 +5,10 @@ import { keyBy } from 'lodash'
 import 'mocha'
 import { join } from 'path'
 import { VideoPrivacy } from '../../../../shared/models/videos'
+import { readdirPromise } from '../../../helpers/core-utils'
 import {
   completeVideoCheck, flushTests, getVideo, getVideoCategories, getVideoLanguages, getVideoLicences, getVideoPrivacies,
-  getVideosList, getVideosListPagination, getVideosListSort, killallServers, rateVideo, readdirPromise, removeVideo, runServer, searchVideo,
+  getVideosList, getVideosListPagination, getVideosListSort, killallServers, rateVideo, removeVideo, runServer, searchVideo,
   searchVideoWithPagination, searchVideoWithSort, ServerInfo, setAccessTokensToServers, testVideoImage, updateVideo, uploadVideo, viewVideo
 } from '../../utils'
 
@@ -32,6 +33,7 @@ describe('Test a single server', function () {
     duration: 5,
     tags: [ 'tag1', 'tag2', 'tag3' ],
     privacy: VideoPrivacy.PUBLIC,
+    commentsEnabled: true,
     channel: {
       name: 'Default root channel',
       description: '',
@@ -51,7 +53,7 @@ describe('Test a single server', function () {
     category: 4,
     licence: 2,
     language: 5,
-    nsfw: true,
+    nsfw: false,
     description: 'my super description updated',
     host: 'localhost:9001',
     account: 'root',
@@ -59,6 +61,7 @@ describe('Test a single server', function () {
     tags: [ 'tagup1', 'tagup2' ],
     privacy: VideoPrivacy.PUBLIC,
     duration: 5,
+    commentsEnabled: false,
     channel: {
       name: 'Default root channel',
       description: '',
@@ -475,6 +478,7 @@ describe('Test a single server', function () {
       language: 5,
       nsfw: false,
       description: 'my super description updated',
+      commentsEnabled: false,
       tags: [ 'tagup1', 'tagup2' ]
     }
     await updateVideo(server.url, server.accessToken, videoId, attributes)