diff options
Diffstat (limited to 'server')
-rw-r--r-- | server/tests/api/check-params/users.ts | 6 | ||||
-rw-r--r-- | server/tests/api/check-params/videos.ts | 32 | ||||
-rw-r--r-- | server/tests/api/videos/multiple-servers.ts | 2 | ||||
-rw-r--r-- | server/tests/cli/create-import-video-file-job.ts | 4 | ||||
-rw-r--r-- | server/tests/fixtures/avatar-big.png (renamed from server/tests/api/fixtures/avatar-big.png) | bin | 146585 -> 146585 bytes | |||
-rw-r--r-- | server/tests/fixtures/avatar-resized.png (renamed from server/tests/api/fixtures/avatar-resized.png) | bin | 1727 -> 1727 bytes | |||
-rw-r--r-- | server/tests/fixtures/avatar.png (renamed from server/tests/api/fixtures/avatar.png) | bin | 1674 -> 1674 bytes | |||
-rw-r--r-- | server/tests/fixtures/avatar2-resized.png (renamed from server/tests/api/fixtures/avatar2-resized.png) | bin | 1725 -> 1725 bytes | |||
-rw-r--r-- | server/tests/fixtures/avatar2.png (renamed from server/tests/api/fixtures/avatar2.png) | bin | 4850 -> 4850 bytes | |||
-rw-r--r-- | server/tests/fixtures/preview.jpg (renamed from server/tests/api/fixtures/preview.jpg) | bin | 4215 -> 4215 bytes | |||
-rw-r--r-- | server/tests/fixtures/thumbnail.jpg (renamed from server/tests/api/fixtures/thumbnail.jpg) | bin | 1457 -> 1457 bytes | |||
-rw-r--r-- | server/tests/fixtures/video_60fps_short.mp4 (renamed from server/tests/api/fixtures/video_60fps_short.mp4) | bin | 33968 -> 33968 bytes | |||
-rw-r--r-- | server/tests/fixtures/video_short-480.webm (renamed from server/tests/api/fixtures/video_short-480.webm) | bin | 69217 -> 69217 bytes | |||
-rw-r--r-- | server/tests/fixtures/video_short.mp4 (renamed from server/tests/api/fixtures/video_short.mp4) | bin | 38783 -> 38783 bytes | |||
-rw-r--r-- | server/tests/fixtures/video_short.mp4.jpg (renamed from server/tests/api/fixtures/video_short.mp4.jpg) | bin | 2618 -> 2618 bytes | |||
-rw-r--r-- | server/tests/fixtures/video_short.ogv (renamed from server/tests/api/fixtures/video_short.ogv) | bin | 140849 -> 140849 bytes | |||
-rw-r--r-- | server/tests/fixtures/video_short.ogv.jpg (renamed from server/tests/api/fixtures/video_short.ogv.jpg) | bin | 2618 -> 2618 bytes | |||
-rw-r--r-- | server/tests/fixtures/video_short.webm (renamed from server/tests/api/fixtures/video_short.webm) | bin | 218910 -> 218910 bytes | |||
-rw-r--r-- | server/tests/fixtures/video_short.webm.jpg (renamed from server/tests/api/fixtures/video_short.webm.jpg) | bin | 2615 -> 2615 bytes | |||
-rw-r--r-- | server/tests/fixtures/video_short1-preview.webm.jpg (renamed from server/tests/api/fixtures/video_short1-preview.webm.jpg) | bin | 10181 -> 10181 bytes | |||
-rw-r--r-- | server/tests/fixtures/video_short1.webm (renamed from server/tests/api/fixtures/video_short1.webm) | bin | 572456 -> 572456 bytes | |||
-rw-r--r-- | server/tests/fixtures/video_short1.webm.jpg (renamed from server/tests/api/fixtures/video_short1.webm.jpg) | bin | 2901 -> 2901 bytes | |||
-rw-r--r-- | server/tests/fixtures/video_short2.webm (renamed from server/tests/api/fixtures/video_short2.webm) | bin | 942961 -> 942961 bytes | |||
-rw-r--r-- | server/tests/fixtures/video_short2.webm.jpg (renamed from server/tests/api/fixtures/video_short2.webm.jpg) | bin | 3185 -> 3185 bytes | |||
-rw-r--r-- | server/tests/fixtures/video_short3.webm (renamed from server/tests/api/fixtures/video_short3.webm) | bin | 292677 -> 292677 bytes | |||
-rw-r--r-- | server/tests/fixtures/video_short3.webm.jpg (renamed from server/tests/api/fixtures/video_short3.webm.jpg) | bin | 2886 -> 2886 bytes | |||
-rw-r--r-- | server/tests/fixtures/video_short_fake.webm (renamed from server/tests/api/fixtures/video_short_fake.webm) | 0 | ||||
-rw-r--r-- | server/tests/utils/miscs/miscs.ts | 4 | ||||
-rw-r--r-- | server/tests/utils/requests/requests.ts | 2 | ||||
-rw-r--r-- | server/tests/utils/users/users.ts | 2 | ||||
-rw-r--r-- | server/tests/utils/videos/videos.ts | 2 |
31 files changed, 26 insertions, 28 deletions
diff --git a/server/tests/api/check-params/users.ts b/server/tests/api/check-params/users.ts index e8a6ffd19..dba57778d 100644 --- a/server/tests/api/check-params/users.ts +++ b/server/tests/api/check-params/users.ts | |||
@@ -279,7 +279,7 @@ describe('Test users API validators', function () { | |||
279 | it('Should fail without an incorrect input file', async function () { | 279 | it('Should fail without an incorrect input file', async function () { |
280 | const fields = {} | 280 | const fields = {} |
281 | const attaches = { | 281 | const attaches = { |
282 | 'avatarfile': join(__dirname, '..', 'fixtures', 'video_short.mp4') | 282 | 'avatarfile': join(__dirname, '..', '..', 'fixtures', 'video_short.mp4') |
283 | } | 283 | } |
284 | await makeUploadRequest({ url: server.url, path: path + '/me/avatar/pick', token: server.accessToken, fields, attaches }) | 284 | await makeUploadRequest({ url: server.url, path: path + '/me/avatar/pick', token: server.accessToken, fields, attaches }) |
285 | }) | 285 | }) |
@@ -287,7 +287,7 @@ describe('Test users API validators', function () { | |||
287 | it('Should fail with a big file', async function () { | 287 | it('Should fail with a big file', async function () { |
288 | const fields = {} | 288 | const fields = {} |
289 | const attaches = { | 289 | const attaches = { |
290 | 'avatarfile': join(__dirname, '..', 'fixtures', 'avatar-big.png') | 290 | 'avatarfile': join(__dirname, '..', '..', 'fixtures', 'avatar-big.png') |
291 | } | 291 | } |
292 | await makeUploadRequest({ url: server.url, path: path + '/me/avatar/pick', token: server.accessToken, fields, attaches }) | 292 | await makeUploadRequest({ url: server.url, path: path + '/me/avatar/pick', token: server.accessToken, fields, attaches }) |
293 | }) | 293 | }) |
@@ -295,7 +295,7 @@ describe('Test users API validators', function () { | |||
295 | it('Should succeed with the correct params', async function () { | 295 | it('Should succeed with the correct params', async function () { |
296 | const fields = {} | 296 | const fields = {} |
297 | const attaches = { | 297 | const attaches = { |
298 | 'avatarfile': join(__dirname, '..', 'fixtures', 'avatar.png') | 298 | 'avatarfile': join(__dirname, '..', '..', 'fixtures', 'avatar.png') |
299 | } | 299 | } |
300 | await makeUploadRequest({ | 300 | await makeUploadRequest({ |
301 | url: server.url, | 301 | url: server.url, |
diff --git a/server/tests/api/check-params/videos.ts b/server/tests/api/check-params/videos.ts index 7b40b91e7..bc6c7fc46 100644 --- a/server/tests/api/check-params/videos.ts +++ b/server/tests/api/check-params/videos.ts | |||
@@ -163,7 +163,7 @@ describe('Test videos API validator', function () { | |||
163 | describe('When adding a video', function () { | 163 | describe('When adding a video', function () { |
164 | let baseCorrectParams | 164 | let baseCorrectParams |
165 | const baseCorrectAttaches = { | 165 | const baseCorrectAttaches = { |
166 | 'videofile': join(__dirname, '..', 'fixtures', 'video_short.webm') | 166 | 'videofile': join(__dirname, '..', '..', 'fixtures', 'video_short.webm') |
167 | } | 167 | } |
168 | 168 | ||
169 | before(function () { | 169 | before(function () { |
@@ -313,7 +313,7 @@ describe('Test videos API validator', function () { | |||
313 | it('Should fail without an incorrect input file', async function () { | 313 | it('Should fail without an incorrect input file', async function () { |
314 | const fields = baseCorrectParams | 314 | const fields = baseCorrectParams |
315 | const attaches = { | 315 | const attaches = { |
316 | 'videofile': join(__dirname, '..', 'fixtures', 'video_short_fake.webm') | 316 | 'videofile': join(__dirname, '..', '..', 'fixtures', 'video_short_fake.webm') |
317 | } | 317 | } |
318 | await makeUploadRequest({ url: server.url, path: path + '/upload', token: server.accessToken, fields, attaches }) | 318 | await makeUploadRequest({ url: server.url, path: path + '/upload', token: server.accessToken, fields, attaches }) |
319 | }) | 319 | }) |
@@ -321,8 +321,8 @@ describe('Test videos API validator', function () { | |||
321 | it('Should fail with an incorrect thumbnail file', async function () { | 321 | it('Should fail with an incorrect thumbnail file', async function () { |
322 | const fields = baseCorrectParams | 322 | const fields = baseCorrectParams |
323 | const attaches = { | 323 | const attaches = { |
324 | 'thumbnailfile': join(__dirname, '..', 'fixtures', 'avatar.png'), | 324 | 'thumbnailfile': join(__dirname, '..', '..', 'fixtures', 'avatar.png'), |
325 | 'videofile': join(__dirname, '..', 'fixtures', 'video_short_fake.webm') | 325 | 'videofile': join(__dirname, '..', '..', 'fixtures', 'video_short_fake.webm') |
326 | } | 326 | } |
327 | 327 | ||
328 | await makeUploadRequest({ url: server.url, path: path + '/upload', token: server.accessToken, fields, attaches }) | 328 | await makeUploadRequest({ url: server.url, path: path + '/upload', token: server.accessToken, fields, attaches }) |
@@ -331,8 +331,8 @@ describe('Test videos API validator', function () { | |||
331 | it('Should fail with a big thumbnail file', async function () { | 331 | it('Should fail with a big thumbnail file', async function () { |
332 | const fields = baseCorrectParams | 332 | const fields = baseCorrectParams |
333 | const attaches = { | 333 | const attaches = { |
334 | 'thumbnailfile': join(__dirname, '..', 'fixtures', 'avatar-big.png'), | 334 | 'thumbnailfile': join(__dirname, '..', '..', 'fixtures', 'avatar-big.png'), |
335 | 'videofile': join(__dirname, '..', 'fixtures', 'video_short_fake.webm') | 335 | 'videofile': join(__dirname, '..', '..', 'fixtures', 'video_short_fake.webm') |
336 | } | 336 | } |
337 | 337 | ||
338 | await makeUploadRequest({ url: server.url, path: path + '/upload', token: server.accessToken, fields, attaches }) | 338 | await makeUploadRequest({ url: server.url, path: path + '/upload', token: server.accessToken, fields, attaches }) |
@@ -341,8 +341,8 @@ describe('Test videos API validator', function () { | |||
341 | it('Should fail with an incorrect preview file', async function () { | 341 | it('Should fail with an incorrect preview file', async function () { |
342 | const fields = baseCorrectParams | 342 | const fields = baseCorrectParams |
343 | const attaches = { | 343 | const attaches = { |
344 | 'previewfile': join(__dirname, '..', 'fixtures', 'avatar.png'), | 344 | 'previewfile': join(__dirname, '..', '..', 'fixtures', 'avatar.png'), |
345 | 'videofile': join(__dirname, '..', 'fixtures', 'video_short_fake.webm') | 345 | 'videofile': join(__dirname, '..', '..', 'fixtures', 'video_short_fake.webm') |
346 | } | 346 | } |
347 | 347 | ||
348 | await makeUploadRequest({ url: server.url, path: path + '/upload', token: server.accessToken, fields, attaches }) | 348 | await makeUploadRequest({ url: server.url, path: path + '/upload', token: server.accessToken, fields, attaches }) |
@@ -351,8 +351,8 @@ describe('Test videos API validator', function () { | |||
351 | it('Should fail with a big preview file', async function () { | 351 | it('Should fail with a big preview file', async function () { |
352 | const fields = baseCorrectParams | 352 | const fields = baseCorrectParams |
353 | const attaches = { | 353 | const attaches = { |
354 | 'previewfile': join(__dirname, '..', 'fixtures', 'avatar-big.png'), | 354 | 'previewfile': join(__dirname, '..', '..', 'fixtures', 'avatar-big.png'), |
355 | 'videofile': join(__dirname, '..', 'fixtures', 'video_short_fake.webm') | 355 | 'videofile': join(__dirname, '..', '..', 'fixtures', 'video_short_fake.webm') |
356 | } | 356 | } |
357 | 357 | ||
358 | await makeUploadRequest({ url: server.url, path: path + '/upload', token: server.accessToken, fields, attaches }) | 358 | await makeUploadRequest({ url: server.url, path: path + '/upload', token: server.accessToken, fields, attaches }) |
@@ -377,7 +377,7 @@ describe('Test videos API validator', function () { | |||
377 | 377 | ||
378 | { | 378 | { |
379 | const attaches = immutableAssign(baseCorrectAttaches, { | 379 | const attaches = immutableAssign(baseCorrectAttaches, { |
380 | videofile: join(__dirname, '..', 'fixtures', 'video_short.mp4') | 380 | videofile: join(__dirname, '..', '..', 'fixtures', 'video_short.mp4') |
381 | }) | 381 | }) |
382 | 382 | ||
383 | await makeUploadRequest({ | 383 | await makeUploadRequest({ |
@@ -392,7 +392,7 @@ describe('Test videos API validator', function () { | |||
392 | 392 | ||
393 | { | 393 | { |
394 | const attaches = immutableAssign(baseCorrectAttaches, { | 394 | const attaches = immutableAssign(baseCorrectAttaches, { |
395 | videofile: join(__dirname, '..', 'fixtures', 'video_short.ogv') | 395 | videofile: join(__dirname, '..', '..', 'fixtures', 'video_short.ogv') |
396 | }) | 396 | }) |
397 | 397 | ||
398 | await makeUploadRequest({ | 398 | await makeUploadRequest({ |
@@ -510,7 +510,7 @@ describe('Test videos API validator', function () { | |||
510 | it('Should fail with an incorrect thumbnail file', async function () { | 510 | it('Should fail with an incorrect thumbnail file', async function () { |
511 | const fields = baseCorrectParams | 511 | const fields = baseCorrectParams |
512 | const attaches = { | 512 | const attaches = { |
513 | 'thumbnailfile': join(__dirname, '..', 'fixtures', 'avatar.png') | 513 | 'thumbnailfile': join(__dirname, '..', '..', 'fixtures', 'avatar.png') |
514 | } | 514 | } |
515 | 515 | ||
516 | await makeUploadRequest({ | 516 | await makeUploadRequest({ |
@@ -526,7 +526,7 @@ describe('Test videos API validator', function () { | |||
526 | it('Should fail with a big thumbnail file', async function () { | 526 | it('Should fail with a big thumbnail file', async function () { |
527 | const fields = baseCorrectParams | 527 | const fields = baseCorrectParams |
528 | const attaches = { | 528 | const attaches = { |
529 | 'thumbnailfile': join(__dirname, '..', 'fixtures', 'avatar-big.png') | 529 | 'thumbnailfile': join(__dirname, '..', '..', 'fixtures', 'avatar-big.png') |
530 | } | 530 | } |
531 | 531 | ||
532 | await makeUploadRequest({ | 532 | await makeUploadRequest({ |
@@ -542,7 +542,7 @@ describe('Test videos API validator', function () { | |||
542 | it('Should fail with an incorrect preview file', async function () { | 542 | it('Should fail with an incorrect preview file', async function () { |
543 | const fields = baseCorrectParams | 543 | const fields = baseCorrectParams |
544 | const attaches = { | 544 | const attaches = { |
545 | 'previewfile': join(__dirname, '..', 'fixtures', 'avatar.png') | 545 | 'previewfile': join(__dirname, '..', '..', 'fixtures', 'avatar.png') |
546 | } | 546 | } |
547 | 547 | ||
548 | await makeUploadRequest({ | 548 | await makeUploadRequest({ |
@@ -558,7 +558,7 @@ describe('Test videos API validator', function () { | |||
558 | it('Should fail with a big preview file', async function () { | 558 | it('Should fail with a big preview file', async function () { |
559 | const fields = baseCorrectParams | 559 | const fields = baseCorrectParams |
560 | const attaches = { | 560 | const attaches = { |
561 | 'previewfile': join(__dirname, '..', 'fixtures', 'avatar-big.png') | 561 | 'previewfile': join(__dirname, '..', '..', 'fixtures', 'avatar-big.png') |
562 | } | 562 | } |
563 | 563 | ||
564 | await makeUploadRequest({ | 564 | await makeUploadRequest({ |
diff --git a/server/tests/api/videos/multiple-servers.ts b/server/tests/api/videos/multiple-servers.ts index fc7c0cb21..5f9a76621 100644 --- a/server/tests/api/videos/multiple-servers.ts +++ b/server/tests/api/videos/multiple-servers.ts | |||
@@ -938,7 +938,7 @@ describe('Test multiple servers', function () { | |||
938 | .field('channelId', '1') | 938 | .field('channelId', '1') |
939 | .field('commentsEnabled', 'true') | 939 | .field('commentsEnabled', 'true') |
940 | 940 | ||
941 | const filePath = join(__dirname, '..', '..', 'api', 'fixtures', 'video_short.webm') | 941 | const filePath = join(__dirname, '..', '..', 'fixtures', 'video_short.webm') |
942 | 942 | ||
943 | await req.attach('videofile', filePath) | 943 | await req.attach('videofile', filePath) |
944 | .expect(200) | 944 | .expect(200) |
diff --git a/server/tests/cli/create-import-video-file-job.ts b/server/tests/cli/create-import-video-file-job.ts index 251088882..372c7e517 100644 --- a/server/tests/cli/create-import-video-file-job.ts +++ b/server/tests/cli/create-import-video-file-job.ts | |||
@@ -59,7 +59,7 @@ describe('Test create import video jobs', function () { | |||
59 | 59 | ||
60 | it('Should run a import job on video 1 with a lower resolution', async function () { | 60 | it('Should run a import job on video 1 with a lower resolution', async function () { |
61 | const env = getEnvCli(servers[0]) | 61 | const env = getEnvCli(servers[0]) |
62 | await execCLI(`${env} npm run create-import-video-file-job -- -v ${video1UUID} -i server/tests/api/fixtures/video_short-480.webm`) | 62 | await execCLI(`${env} npm run create-import-video-file-job -- -v ${video1UUID} -i server/tests/fixtures/video_short-480.webm`) |
63 | 63 | ||
64 | await wait(30000) | 64 | await wait(30000) |
65 | 65 | ||
@@ -83,7 +83,7 @@ describe('Test create import video jobs', function () { | |||
83 | 83 | ||
84 | it('Should run a import job on video 2 with the same resolution', async function () { | 84 | it('Should run a import job on video 2 with the same resolution', async function () { |
85 | const env = getEnvCli(servers[1]) | 85 | const env = getEnvCli(servers[1]) |
86 | await execCLI(`${env} npm run create-import-video-file-job -- -v ${video2UUID} -i server/tests/api/fixtures/video_short.ogv`) | 86 | await execCLI(`${env} npm run create-import-video-file-job -- -v ${video2UUID} -i server/tests/fixtures/video_short.ogv`) |
87 | 87 | ||
88 | await wait(30000) | 88 | await wait(30000) |
89 | 89 | ||
diff --git a/server/tests/api/fixtures/avatar-big.png b/server/tests/fixtures/avatar-big.png index e593e40da..e593e40da 100644 --- a/server/tests/api/fixtures/avatar-big.png +++ b/server/tests/fixtures/avatar-big.png | |||
Binary files differ | |||
diff --git a/server/tests/api/fixtures/avatar-resized.png b/server/tests/fixtures/avatar-resized.png index 9d84151f8..9d84151f8 100644 --- a/server/tests/api/fixtures/avatar-resized.png +++ b/server/tests/fixtures/avatar-resized.png | |||
Binary files differ | |||
diff --git a/server/tests/api/fixtures/avatar.png b/server/tests/fixtures/avatar.png index 4b7fd2c0a..4b7fd2c0a 100644 --- a/server/tests/api/fixtures/avatar.png +++ b/server/tests/fixtures/avatar.png | |||
Binary files differ | |||
diff --git a/server/tests/api/fixtures/avatar2-resized.png b/server/tests/fixtures/avatar2-resized.png index 44149facb..44149facb 100644 --- a/server/tests/api/fixtures/avatar2-resized.png +++ b/server/tests/fixtures/avatar2-resized.png | |||
Binary files differ | |||
diff --git a/server/tests/api/fixtures/avatar2.png b/server/tests/fixtures/avatar2.png index dae702190..dae702190 100644 --- a/server/tests/api/fixtures/avatar2.png +++ b/server/tests/fixtures/avatar2.png | |||
Binary files differ | |||
diff --git a/server/tests/api/fixtures/preview.jpg b/server/tests/fixtures/preview.jpg index c40ece838..c40ece838 100644 --- a/server/tests/api/fixtures/preview.jpg +++ b/server/tests/fixtures/preview.jpg | |||
Binary files differ | |||
diff --git a/server/tests/api/fixtures/thumbnail.jpg b/server/tests/fixtures/thumbnail.jpg index cc3af8a4a..cc3af8a4a 100644 --- a/server/tests/api/fixtures/thumbnail.jpg +++ b/server/tests/fixtures/thumbnail.jpg | |||
Binary files differ | |||
diff --git a/server/tests/api/fixtures/video_60fps_short.mp4 b/server/tests/fixtures/video_60fps_short.mp4 index ff0593cf3..ff0593cf3 100644 --- a/server/tests/api/fixtures/video_60fps_short.mp4 +++ b/server/tests/fixtures/video_60fps_short.mp4 | |||
Binary files differ | |||
diff --git a/server/tests/api/fixtures/video_short-480.webm b/server/tests/fixtures/video_short-480.webm index 3145105e1..3145105e1 100644 --- a/server/tests/api/fixtures/video_short-480.webm +++ b/server/tests/fixtures/video_short-480.webm | |||
Binary files differ | |||
diff --git a/server/tests/api/fixtures/video_short.mp4 b/server/tests/fixtures/video_short.mp4 index 35678362b..35678362b 100644 --- a/server/tests/api/fixtures/video_short.mp4 +++ b/server/tests/fixtures/video_short.mp4 | |||
Binary files differ | |||
diff --git a/server/tests/api/fixtures/video_short.mp4.jpg b/server/tests/fixtures/video_short.mp4.jpg index 48790ffec..48790ffec 100644 --- a/server/tests/api/fixtures/video_short.mp4.jpg +++ b/server/tests/fixtures/video_short.mp4.jpg | |||
Binary files differ | |||
diff --git a/server/tests/api/fixtures/video_short.ogv b/server/tests/fixtures/video_short.ogv index 9e253da82..9e253da82 100644 --- a/server/tests/api/fixtures/video_short.ogv +++ b/server/tests/fixtures/video_short.ogv | |||
Binary files differ | |||
diff --git a/server/tests/api/fixtures/video_short.ogv.jpg b/server/tests/fixtures/video_short.ogv.jpg index c4c1d00e5..c4c1d00e5 100644 --- a/server/tests/api/fixtures/video_short.ogv.jpg +++ b/server/tests/fixtures/video_short.ogv.jpg | |||
Binary files differ | |||
diff --git a/server/tests/api/fixtures/video_short.webm b/server/tests/fixtures/video_short.webm index bf4b0ab6c..bf4b0ab6c 100644 --- a/server/tests/api/fixtures/video_short.webm +++ b/server/tests/fixtures/video_short.webm | |||
Binary files differ | |||
diff --git a/server/tests/api/fixtures/video_short.webm.jpg b/server/tests/fixtures/video_short.webm.jpg index b0dffd099..b0dffd099 100644 --- a/server/tests/api/fixtures/video_short.webm.jpg +++ b/server/tests/fixtures/video_short.webm.jpg | |||
Binary files differ | |||
diff --git a/server/tests/api/fixtures/video_short1-preview.webm.jpg b/server/tests/fixtures/video_short1-preview.webm.jpg index d2a068b78..d2a068b78 100644 --- a/server/tests/api/fixtures/video_short1-preview.webm.jpg +++ b/server/tests/fixtures/video_short1-preview.webm.jpg | |||
Binary files differ | |||
diff --git a/server/tests/api/fixtures/video_short1.webm b/server/tests/fixtures/video_short1.webm index 70ac0c644..70ac0c644 100644 --- a/server/tests/api/fixtures/video_short1.webm +++ b/server/tests/fixtures/video_short1.webm | |||
Binary files differ | |||
diff --git a/server/tests/api/fixtures/video_short1.webm.jpg b/server/tests/fixtures/video_short1.webm.jpg index 2db21975c..2db21975c 100644 --- a/server/tests/api/fixtures/video_short1.webm.jpg +++ b/server/tests/fixtures/video_short1.webm.jpg | |||
Binary files differ | |||
diff --git a/server/tests/api/fixtures/video_short2.webm b/server/tests/fixtures/video_short2.webm index 13d72dff7..13d72dff7 100644 --- a/server/tests/api/fixtures/video_short2.webm +++ b/server/tests/fixtures/video_short2.webm | |||
Binary files differ | |||
diff --git a/server/tests/api/fixtures/video_short2.webm.jpg b/server/tests/fixtures/video_short2.webm.jpg index ed5952e04..ed5952e04 100644 --- a/server/tests/api/fixtures/video_short2.webm.jpg +++ b/server/tests/fixtures/video_short2.webm.jpg | |||
Binary files differ | |||
diff --git a/server/tests/api/fixtures/video_short3.webm b/server/tests/fixtures/video_short3.webm index cde5dcd58..cde5dcd58 100644 --- a/server/tests/api/fixtures/video_short3.webm +++ b/server/tests/fixtures/video_short3.webm | |||
Binary files differ | |||
diff --git a/server/tests/api/fixtures/video_short3.webm.jpg b/server/tests/fixtures/video_short3.webm.jpg index b7c41cc1a..b7c41cc1a 100644 --- a/server/tests/api/fixtures/video_short3.webm.jpg +++ b/server/tests/fixtures/video_short3.webm.jpg | |||
Binary files differ | |||
diff --git a/server/tests/api/fixtures/video_short_fake.webm b/server/tests/fixtures/video_short_fake.webm index d85290ae5..d85290ae5 100644 --- a/server/tests/api/fixtures/video_short_fake.webm +++ b/server/tests/fixtures/video_short_fake.webm | |||
diff --git a/server/tests/utils/miscs/miscs.ts b/server/tests/utils/miscs/miscs.ts index 53cb67baf..5e46004a7 100644 --- a/server/tests/utils/miscs/miscs.ts +++ b/server/tests/utils/miscs/miscs.ts | |||
@@ -46,7 +46,7 @@ async function testImage (url: string, imageName: string, imagePath: string, ext | |||
46 | 46 | ||
47 | const body = res.body | 47 | const body = res.body |
48 | 48 | ||
49 | const data = await readFileBufferPromise(join(__dirname, '..', '..', 'api', 'fixtures', imageName + extension)) | 49 | const data = await readFileBufferPromise(join(__dirname, '..', '..', 'fixtures', imageName + extension)) |
50 | const minLength = body.length - ((20 * body.length) / 100) | 50 | const minLength = body.length - ((20 * body.length) / 100) |
51 | const maxLength = body.length + ((20 * body.length) / 100) | 51 | const maxLength = body.length + ((20 * body.length) / 100) |
52 | 52 | ||
@@ -63,7 +63,7 @@ function buildAbsoluteFixturePath (path: string) { | |||
63 | return path | 63 | return path |
64 | } | 64 | } |
65 | 65 | ||
66 | return join(__dirname, '..', '..', 'api', 'fixtures', path) | 66 | return join(__dirname, '..', '..', 'fixtures', path) |
67 | } | 67 | } |
68 | 68 | ||
69 | // --------------------------------------------------------------------------- | 69 | // --------------------------------------------------------------------------- |
diff --git a/server/tests/utils/requests/requests.ts b/server/tests/utils/requests/requests.ts index a9b1dff9a..b6195089d 100644 --- a/server/tests/utils/requests/requests.ts +++ b/server/tests/utils/requests/requests.ts | |||
@@ -1,5 +1,5 @@ | |||
1 | import * as request from 'supertest' | 1 | import * as request from 'supertest' |
2 | import { buildAbsoluteFixturePath } from '../' | 2 | import { buildAbsoluteFixturePath } from '../miscs/miscs' |
3 | 3 | ||
4 | function makeGetRequest (options: { | 4 | function makeGetRequest (options: { |
5 | url: string, | 5 | url: string, |
diff --git a/server/tests/utils/users/users.ts b/server/tests/utils/users/users.ts index d31e57a25..34d50f7ad 100644 --- a/server/tests/utils/users/users.ts +++ b/server/tests/utils/users/users.ts | |||
@@ -164,7 +164,7 @@ function updateMyAvatar (options: { | |||
164 | if (isAbsolute(options.fixture)) { | 164 | if (isAbsolute(options.fixture)) { |
165 | filePath = options.fixture | 165 | filePath = options.fixture |
166 | } else { | 166 | } else { |
167 | filePath = join(__dirname, '..', '..', 'api', 'fixtures', options.fixture) | 167 | filePath = join(__dirname, '..', '..', 'fixtures', options.fixture) |
168 | } | 168 | } |
169 | 169 | ||
170 | return makeUploadRequest({ | 170 | return makeUploadRequest({ |
diff --git a/server/tests/utils/videos/videos.ts b/server/tests/utils/videos/videos.ts index 746b5ca6b..ab0ce12ec 100644 --- a/server/tests/utils/videos/videos.ts +++ b/server/tests/utils/videos/videos.ts | |||
@@ -502,8 +502,6 @@ async function completeVideoCheck ( | |||
502 | expect(dateIsValid(video.updatedAt)).to.be.true | 502 | expect(dateIsValid(video.updatedAt)).to.be.true |
503 | 503 | ||
504 | if (attributes.publishedAt) { | 504 | if (attributes.publishedAt) { |
505 | console.log(attributes.publishedAt) | ||
506 | console.log(video.publishedAt) | ||
507 | expect(video.publishedAt).to.equal(attributes.publishedAt) | 505 | expect(video.publishedAt).to.equal(attributes.publishedAt) |
508 | } | 506 | } |
509 | 507 | ||