Fix tmp tests

This commit is contained in:
Chocobozzz 2021-02-02 13:45:58 +01:00
parent aaedadd538
commit d1a2ce5ef3
No known key found for this signature in database
GPG Key ID: 583A612D890159BE

View File

@ -272,8 +272,12 @@ async function reRunServer (server: ServerInfo, configOverride?: any) {
return server
}
function checkTmpIsEmpty (server: ServerInfo) {
return checkDirectoryIsEmpty(server, 'tmp', [ 'plugins-global.css' ])
async function checkTmpIsEmpty (server: ServerInfo) {
await checkDirectoryIsEmpty(server, 'tmp', [ 'plugins-global.css', 'hls' ])
if (await pathExists(join('test' + server.internalServerNumber, 'tmp', 'hls'))) {
await checkDirectoryIsEmpty(server, 'tmp/hls')
}
}
async function checkDirectoryIsEmpty (server: ServerInfo, directory: string, exceptions: string[] = []) {