diff options
author | Chocobozzz <me@florianbigard.com> | 2018-02-15 14:46:26 +0100 |
---|---|---|
committer | Chocobozzz <me@florianbigard.com> | 2018-02-15 15:29:07 +0100 |
commit | 2422c46b27790d94fd29a7092170cee5a1b56008 (patch) | |
tree | d5c1942ce20cadb27a551d87c789edfe92f5b105 /server/tests/utils/videos/videos.ts | |
parent | 34cbef8c6cc912143a421413bdd832c4adcc556a (diff) | |
download | PeerTube-2422c46b27790d94fd29a7092170cee5a1b56008.tar.gz PeerTube-2422c46b27790d94fd29a7092170cee5a1b56008.tar.zst PeerTube-2422c46b27790d94fd29a7092170cee5a1b56008.zip |
Implement support field in video and video channel
Diffstat (limited to 'server/tests/utils/videos/videos.ts')
-rw-r--r-- | server/tests/utils/videos/videos.ts | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/server/tests/utils/videos/videos.ts b/server/tests/utils/videos/videos.ts index 9a4af0b9f..a06078d40 100644 --- a/server/tests/utils/videos/videos.ts +++ b/server/tests/utils/videos/videos.ts | |||
@@ -248,6 +248,7 @@ async function uploadVideo (url: string, accessToken: string, videoAttributesArg | |||
248 | channelId: defaultChannelId, | 248 | channelId: defaultChannelId, |
249 | nsfw: true, | 249 | nsfw: true, |
250 | description: 'my super description', | 250 | description: 'my super description', |
251 | support: 'my super support text', | ||
251 | tags: [ 'tag' ], | 252 | tags: [ 'tag' ], |
252 | privacy: VideoPrivacy.PUBLIC, | 253 | privacy: VideoPrivacy.PUBLIC, |
253 | commentsEnabled: true, | 254 | commentsEnabled: true, |
@@ -277,6 +278,10 @@ async function uploadVideo (url: string, accessToken: string, videoAttributesArg | |||
277 | req.field('licence', attributes.licence.toString()) | 278 | req.field('licence', attributes.licence.toString()) |
278 | } | 279 | } |
279 | 280 | ||
281 | for (let i = 0; i < attributes.tags.length; i++) { | ||
282 | req.field('tags[' + i + ']', attributes.tags[i]) | ||
283 | } | ||
284 | |||
280 | if (attributes.thumbnailfile !== undefined) { | 285 | if (attributes.thumbnailfile !== undefined) { |
281 | req.attach('thumbnailfile', buildAbsoluteFixturePath(attributes.thumbnailfile)) | 286 | req.attach('thumbnailfile', buildAbsoluteFixturePath(attributes.thumbnailfile)) |
282 | } | 287 | } |
@@ -284,10 +289,6 @@ async function uploadVideo (url: string, accessToken: string, videoAttributesArg | |||
284 | req.attach('previewfile', buildAbsoluteFixturePath(attributes.previewfile)) | 289 | req.attach('previewfile', buildAbsoluteFixturePath(attributes.previewfile)) |
285 | } | 290 | } |
286 | 291 | ||
287 | for (let i = 0; i < attributes.tags.length; i++) { | ||
288 | req.field('tags[' + i + ']', attributes.tags[i]) | ||
289 | } | ||
290 | |||
291 | return req.attach('videofile', buildAbsoluteFixturePath(attributes.fixture)) | 292 | return req.attach('videofile', buildAbsoluteFixturePath(attributes.fixture)) |
292 | .expect(specialStatus) | 293 | .expect(specialStatus) |
293 | } | 294 | } |
@@ -366,6 +367,7 @@ async function completeVideoCheck ( | |||
366 | nsfw: boolean | 367 | nsfw: boolean |
367 | commentsEnabled: boolean | 368 | commentsEnabled: boolean |
368 | description: string | 369 | description: string |
370 | support: string | ||
369 | host: string | 371 | host: string |
370 | account: string | 372 | account: string |
371 | isLocal: boolean, | 373 | isLocal: boolean, |