aboutsummaryrefslogtreecommitdiffhomepage
path: root/shared/extra-utils
diff options
context:
space:
mode:
Diffstat (limited to 'shared/extra-utils')
-rw-r--r--shared/extra-utils/videos/videos.ts5
1 files changed, 3 insertions, 2 deletions
diff --git a/shared/extra-utils/videos/videos.ts b/shared/extra-utils/videos/videos.ts
index 98a568a02..a3a276188 100644
--- a/shared/extra-utils/videos/videos.ts
+++ b/shared/extra-utils/videos/videos.ts
@@ -4,10 +4,11 @@ import { expect } from 'chai'
4import { createReadStream, pathExists, readdir, readFile, stat } from 'fs-extra' 4import { createReadStream, pathExists, readdir, readFile, stat } from 'fs-extra'
5import got, { Response as GotResponse } from 'got/dist/source' 5import got, { Response as GotResponse } from 'got/dist/source'
6import * as parseTorrent from 'parse-torrent' 6import * as parseTorrent from 'parse-torrent'
7import { extname, join } from 'path' 7import { join } from 'path'
8import * as request from 'supertest' 8import * as request from 'supertest'
9import { v4 as uuidv4 } from 'uuid' 9import { v4 as uuidv4 } from 'uuid'
10import validator from 'validator' 10import validator from 'validator'
11import { getLowercaseExtension } from '@server/helpers/core-utils'
11import { HttpStatusCode } from '@shared/core-utils' 12import { HttpStatusCode } from '@shared/core-utils'
12import { VideosCommonQuery } from '@shared/models' 13import { VideosCommonQuery } from '@shared/models'
13import { loadLanguages, VIDEO_CATEGORIES, VIDEO_LANGUAGES, VIDEO_LICENCES, VIDEO_PRIVACIES } from '../../../server/initializers/constants' 14import { loadLanguages, VIDEO_CATEGORIES, VIDEO_LANGUAGES, VIDEO_LICENCES, VIDEO_PRIVACIES } from '../../../server/initializers/constants'
@@ -738,7 +739,7 @@ async function completeVideoCheck (
738 const file = videoDetails.files.find(f => f.resolution.id === attributeFile.resolution) 739 const file = videoDetails.files.find(f => f.resolution.id === attributeFile.resolution)
739 expect(file).not.to.be.undefined 740 expect(file).not.to.be.undefined
740 741
741 let extension = extname(attributes.fixture) 742 let extension = getLowercaseExtension(attributes.fixture)
742 // Transcoding enabled: extension will always be .mp4 743 // Transcoding enabled: extension will always be .mp4
743 if (attributes.files.length > 1) extension = '.mp4' 744 if (attributes.files.length > 1) extension = '.mp4'
744 745