From 34aa316f58f726662bc609cf99f33327bddb18c5 Mon Sep 17 00:00:00 2001 From: Chocobozzz Date: Mon, 10 Oct 2022 11:31:01 +0200 Subject: Try to fix tests --- server/tests/shared/live.ts | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) (limited to 'server/tests/shared') diff --git a/server/tests/shared/live.ts b/server/tests/shared/live.ts index aa79622cb..f165832fe 100644 --- a/server/tests/shared/live.ts +++ b/server/tests/shared/live.ts @@ -58,13 +58,16 @@ async function testVideoResolutions (options: { : originServer.url + '/static/streaming-playlists/hls' if (objectStorage) { - // Playlist file upload - await wait(500) + await originServer.live.waitUntilSegmentUpload({ playlistNumber: i, segment: segmentNum }) + await wait(1000) expect(hlsPlaylist.segmentsSha256Url).to.contain(ObjectStorageCommand.getPlaylistBaseUrl()) } - const subPlaylist = await originServer.streamingPlaylists.get({ url: `${baseUrl}/${video.uuid}/${i}.m3u8` }) + const subPlaylist = await originServer.streamingPlaylists.get({ + url: `${baseUrl}/${video.uuid}/${i}.m3u8`, + withRetry: objectStorage // With object storage, the request may fail because of inconsistent data in S3 + }) expect(subPlaylist).to.contain(segmentName) -- cgit v1.2.3