import {
checkDirectoryIsEmpty,
checkSegmentHash,
- checkTmpIsEmpty,
+ checkTmpIsEmpty, cleanupTests,
doubleFollow,
flushAndRunMultipleServers,
flushTests,
updateVideo,
uploadVideo,
waitJobs
-} from '../../../../shared/utils'
+} from '../../../../shared/extra-utils'
import { VideoDetails } from '../../../../shared/models/videos'
import { VideoStreamingPlaylistType } from '../../../../shared/models/videos/video-streaming-playlist.type'
import { join } from 'path'
{
for (const resolution of resolutions) {
- const res2 = await getPlaylist(`http://localhost:9001/static/playlists/hls/${videoUUID}/${resolution}.m3u8`)
+ const res2 = await getPlaylist(`http://localhost:9001/static/streaming-playlists/hls/${videoUUID}/${resolution}.m3u8`)
const subPlaylist = res2.text
expect(subPlaylist).to.contain(`${videoUUID}-${resolution}-fragmented.mp4`)
}
{
- const baseUrl = 'http://localhost:9001/static/playlists/hls'
+ const baseUrl = 'http://localhost:9001/static/streaming-playlists/hls'
for (const resolution of resolutions) {
await checkSegmentHash(baseUrl, baseUrl, videoUUID, resolution, hlsPlaylist)
it('Should have the playlists/segment deleted from the disk', async function () {
for (const server of servers) {
await checkDirectoryIsEmpty(server, 'videos')
- await checkDirectoryIsEmpty(server, join('playlists', 'hls'))
+ await checkDirectoryIsEmpty(server, join('streaming-playlists', 'hls'))
}
})
})
after(async function () {
- killallServers(servers)
-
- // Keep the logs if the test failed
- if (this['ok']) {
- await flushTests()
- }
+ await cleanupTests(servers)
})
})