1
0
Fork 0
mirror of https://github.com/Chocobozzz/PeerTube.git synced 2025-10-03 17:59:37 +02:00

Integrate transcription in PeerTube

This commit is contained in:
Chocobozzz 2024-06-13 09:23:12 +02:00
parent ef14cf4a5c
commit 1bfb791e05
No known key found for this signature in database
GPG key ID: 583A612D890159BE
172 changed files with 2674 additions and 945 deletions

View file

@ -32,13 +32,13 @@ export async function checkDirectoryIsEmpty (server: PeerTubeServer, directory:
expect(filtered).to.have.lengthOf(0)
}
export async function checkPeerTubeRunnerCacheIsEmpty (runner: PeerTubeRunnerProcess) {
const directoryPath = join(homedir(), '.cache', 'peertube-runner-nodejs', runner.getId(), 'transcoding')
export async function checkPeerTubeRunnerCacheIsEmpty (runner: PeerTubeRunnerProcess, subDir: 'transcoding' | 'transcription') {
const directoryPath = join(homedir(), '.cache', 'peertube-runner-nodejs', runner.getId(), subDir)
const directoryExists = await pathExists(directoryPath)
expect(directoryExists).to.be.true
const files = await readdir(directoryPath)
expect(files, 'Directory content: ' + files.join(', ')).to.have.lengthOf(0)
expect(files, `Sub-directory ${subDir} content: ${files.join(', ')}`).to.have.lengthOf(0)
}