diff options
Diffstat (limited to 'server/tests/api/videos/multiple-servers.ts')
-rw-r--r-- | server/tests/api/videos/multiple-servers.ts | 12 |
1 files changed, 10 insertions, 2 deletions
diff --git a/server/tests/api/videos/multiple-servers.ts b/server/tests/api/videos/multiple-servers.ts index 6c281e49e..1b471ba79 100644 --- a/server/tests/api/videos/multiple-servers.ts +++ b/server/tests/api/videos/multiple-servers.ts | |||
@@ -128,6 +128,7 @@ describe('Test multiple servers', function () { | |||
128 | tags: [ 'tag1p1', 'tag2p1' ], | 128 | tags: [ 'tag1p1', 'tag2p1' ], |
129 | privacy: VideoPrivacy.PUBLIC, | 129 | privacy: VideoPrivacy.PUBLIC, |
130 | commentsEnabled: true, | 130 | commentsEnabled: true, |
131 | downloadEnabled: true, | ||
131 | channel: { | 132 | channel: { |
132 | displayName: 'my channel', | 133 | displayName: 'my channel', |
133 | name: 'super_channel_name', | 134 | name: 'super_channel_name', |
@@ -199,6 +200,7 @@ describe('Test multiple servers', function () { | |||
199 | }, | 200 | }, |
200 | isLocal, | 201 | isLocal, |
201 | commentsEnabled: true, | 202 | commentsEnabled: true, |
203 | downloadEnabled: true, | ||
202 | duration: 5, | 204 | duration: 5, |
203 | tags: [ 'tag1p2', 'tag2p2', 'tag3p2' ], | 205 | tags: [ 'tag1p2', 'tag2p2', 'tag3p2' ], |
204 | privacy: VideoPrivacy.PUBLIC, | 206 | privacy: VideoPrivacy.PUBLIC, |
@@ -307,6 +309,7 @@ describe('Test multiple servers', function () { | |||
307 | isLocal, | 309 | isLocal, |
308 | duration: 5, | 310 | duration: 5, |
309 | commentsEnabled: true, | 311 | commentsEnabled: true, |
312 | downloadEnabled: true, | ||
310 | tags: [ 'tag1p3' ], | 313 | tags: [ 'tag1p3' ], |
311 | privacy: VideoPrivacy.PUBLIC, | 314 | privacy: VideoPrivacy.PUBLIC, |
312 | channel: { | 315 | channel: { |
@@ -338,6 +341,7 @@ describe('Test multiple servers', function () { | |||
338 | host: 'localhost:9003' | 341 | host: 'localhost:9003' |
339 | }, | 342 | }, |
340 | commentsEnabled: true, | 343 | commentsEnabled: true, |
344 | downloadEnabled: true, | ||
341 | isLocal, | 345 | isLocal, |
342 | duration: 5, | 346 | duration: 5, |
343 | tags: [ 'tag2p3', 'tag3p3', 'tag4p3' ], | 347 | tags: [ 'tag2p3', 'tag3p3', 'tag4p3' ], |
@@ -655,6 +659,7 @@ describe('Test multiple servers', function () { | |||
655 | isLocal, | 659 | isLocal, |
656 | duration: 5, | 660 | duration: 5, |
657 | commentsEnabled: true, | 661 | commentsEnabled: true, |
662 | downloadEnabled: true, | ||
658 | tags: [ 'tag_up_1', 'tag_up_2' ], | 663 | tags: [ 'tag_up_1', 'tag_up_2' ], |
659 | privacy: VideoPrivacy.PUBLIC, | 664 | privacy: VideoPrivacy.PUBLIC, |
660 | channel: { | 665 | channel: { |
@@ -914,11 +919,12 @@ describe('Test multiple servers', function () { | |||
914 | } | 919 | } |
915 | }) | 920 | }) |
916 | 921 | ||
917 | it('Should disable comments', async function () { | 922 | it('Should disable comments and download', async function () { |
918 | this.timeout(20000) | 923 | this.timeout(20000) |
919 | 924 | ||
920 | const attributes = { | 925 | const attributes = { |
921 | commentsEnabled: false | 926 | commentsEnabled: false, |
927 | downloadEnabled: false | ||
922 | } | 928 | } |
923 | 929 | ||
924 | await updateVideo(servers[0].url, servers[0].accessToken, videoUUID, attributes) | 930 | await updateVideo(servers[0].url, servers[0].accessToken, videoUUID, attributes) |
@@ -928,6 +934,7 @@ describe('Test multiple servers', function () { | |||
928 | for (const server of servers) { | 934 | for (const server of servers) { |
929 | const res = await getVideo(server.url, videoUUID) | 935 | const res = await getVideo(server.url, videoUUID) |
930 | expect(res.body.commentsEnabled).to.be.false | 936 | expect(res.body.commentsEnabled).to.be.false |
937 | expect(res.body.downloadEnabled).to.be.false | ||
931 | 938 | ||
932 | const text = 'my super forbidden comment' | 939 | const text = 'my super forbidden comment' |
933 | await addVideoCommentThread(server.url, server.accessToken, videoUUID, text, 409) | 940 | await addVideoCommentThread(server.url, server.accessToken, videoUUID, text, 409) |
@@ -976,6 +983,7 @@ describe('Test multiple servers', function () { | |||
976 | isLocal, | 983 | isLocal, |
977 | duration: 5, | 984 | duration: 5, |
978 | commentsEnabled: false, | 985 | commentsEnabled: false, |
986 | downloadEnabled: false, | ||
979 | tags: [ ], | 987 | tags: [ ], |
980 | privacy: VideoPrivacy.PUBLIC, | 988 | privacy: VideoPrivacy.PUBLIC, |
981 | channel: { | 989 | channel: { |