+ const liveVideoId = await createLiveWrapper(server)
+
+ await server.live.sendRTMPStreamInVideo({ videoId: liveVideoId, fixtureName: 'video_very_short_240p.mp4' })
+ await server.live.waitUntilPublished({ videoId: liveVideoId })
+ await waitJobs([ server ])
+
+ await checkLiveFPS(liveVideoId, 'above', 45)
+ })
+
+ it('Should apply the input options on live profile', async function () {
+ this.timeout(240000)
+
+ await updateConf(server, 'low-vod', 'input-options-live')
+
+ const liveVideoId = await createLiveWrapper(server)
+
+ await server.live.sendRTMPStreamInVideo({ videoId: liveVideoId, fixtureName: 'video_very_short_240p.mp4' })
+ await server.live.waitUntilPublished({ videoId: liveVideoId })
+ await waitJobs([ server ])
+
+ await checkLiveFPS(liveVideoId, 'above', 45)
+ })
+
+ it('Should apply the scale filter name on live profile', async function () {
+ this.timeout(240000)
+
+ await updateConf(server, 'low-vod', 'bad-scale-live')
+
+ const liveVideoId = await createLiveWrapper(server)
+
+ const command = await server.live.sendRTMPStreamInVideo({ videoId: liveVideoId, fixtureName: 'video_very_short_240p.mp4' })
+ await testFfmpegStreamError(command, true)
+ })
+
+ it('Should default to the default profile if the specified profile does not exist', async function () {
+ this.timeout(240000)
+
+ await server.plugins.uninstall({ npmName: 'peertube-plugin-test-transcoding-one' })
+
+ const config = await server.config.getConfig()
+
+ expect(config.transcoding.availableProfiles).to.deep.equal([ 'default' ])
+ expect(config.live.transcoding.availableProfiles).to.deep.equal([ 'default' ])
+
+ const videoUUID = (await server.videos.quickUpload({ name: 'video', fixture: 'video_very_short_240p.mp4' })).uuid
+ await waitJobs([ server ])
+
+ await checkVideoFPS(videoUUID, 'above', 20)
+ })