aboutsummaryrefslogtreecommitdiffhomepage
path: root/server/tests/api/live/live-save-replay.ts
diff options
context:
space:
mode:
Diffstat (limited to 'server/tests/api/live/live-save-replay.ts')
-rw-r--r--server/tests/api/live/live-save-replay.ts41
1 files changed, 0 insertions, 41 deletions
diff --git a/server/tests/api/live/live-save-replay.ts b/server/tests/api/live/live-save-replay.ts
index 99d500711..7ddcb04ef 100644
--- a/server/tests/api/live/live-save-replay.ts
+++ b/server/tests/api/live/live-save-replay.ts
@@ -12,7 +12,6 @@ import {
12 createMultipleServers, 12 createMultipleServers,
13 doubleFollow, 13 doubleFollow,
14 findExternalSavedVideo, 14 findExternalSavedVideo,
15 makeRawRequest,
16 PeerTubeServer, 15 PeerTubeServer,
17 setAccessTokensToServers, 16 setAccessTokensToServers,
18 setDefaultVideoChannel, 17 setDefaultVideoChannel,
@@ -442,46 +441,6 @@ describe('Save replay setting', function () {
442 await checkVideosExist(liveVideoUUID, false, HttpStatusCode.NOT_FOUND_404) 441 await checkVideosExist(liveVideoUUID, false, HttpStatusCode.NOT_FOUND_404)
443 await checkLiveCleanup(servers[0], liveVideoUUID, []) 442 await checkLiveCleanup(servers[0], liveVideoUUID, [])
444 }) 443 })
445
446 it('Should correctly save replays with multiple sessions', async function () {
447 this.timeout(120000)
448
449 liveVideoUUID = await createLiveWrapper({ permanent: true, replay: true })
450 await waitJobs(servers)
451
452 // Streaming session #1
453 ffmpegCommand = await servers[0].live.sendRTMPStreamInVideo({ videoId: liveVideoUUID })
454 await waitUntilLivePublishedOnAllServers(servers, liveVideoUUID)
455 await stopFfmpeg(ffmpegCommand)
456 await servers[0].live.waitUntilWaiting({ videoId: liveVideoUUID })
457
458 // Streaming session #2
459 ffmpegCommand = await servers[0].live.sendRTMPStreamInVideo({ videoId: liveVideoUUID })
460 await waitUntilLivePublishedOnAllServers(servers, liveVideoUUID)
461
462 await wait(5000)
463 const video = await servers[0].videos.get({ id: liveVideoUUID })
464 expect(video.streamingPlaylists).to.have.lengthOf(1)
465 await makeRawRequest(video.streamingPlaylists[0].playlistUrl)
466
467 await stopFfmpeg(ffmpegCommand)
468 await waitUntilLiveWaitingOnAllServers(servers, liveVideoUUID)
469
470 // Wait for replays
471 await waitJobs(servers)
472
473 const { total, data: sessions } = await servers[0].live.listSessions({ videoId: liveVideoUUID })
474
475 expect(total).to.equal(2)
476 expect(sessions).to.have.lengthOf(2)
477
478 for (const session of sessions) {
479 expect(session.error).to.be.null
480 expect(session.replayVideo).to.exist
481
482 await servers[0].videos.get({ id: session.replayVideo.uuid })
483 }
484 })
485 }) 444 })
486 445
487 after(async function () { 446 after(async function () {