mirror of
https://github.com/Chocobozzz/PeerTube.git
synced 2025-10-06 03:50:26 +02:00
Correctly cleanup files from object storage
This commit is contained in:
parent
849f0fd3b2
commit
508c1b1e9f
4 changed files with 42 additions and 19 deletions
|
@ -192,16 +192,6 @@ describe('Object storage for video static file privacy', function () {
|
|||
|
||||
await checkPublicFiles(publicVideoUUID)
|
||||
})
|
||||
|
||||
after(async function () {
|
||||
this.timeout(30000)
|
||||
|
||||
if (privateVideoUUID) await server.videos.remove({ id: privateVideoUUID })
|
||||
if (publicVideoUUID) await server.videos.remove({ id: publicVideoUUID })
|
||||
if (userPrivateVideoUUID) await server.videos.remove({ id: userPrivateVideoUUID })
|
||||
|
||||
await waitJobs([ server ])
|
||||
})
|
||||
})
|
||||
|
||||
describe('Live', function () {
|
||||
|
@ -331,6 +321,18 @@ describe('Object storage for video static file privacy', function () {
|
|||
})
|
||||
|
||||
after(async function () {
|
||||
this.timeout(60000)
|
||||
|
||||
const { data } = await server.videos.listAllForAdmin()
|
||||
|
||||
for (const v of data) {
|
||||
await server.videos.remove({ id: v.uuid })
|
||||
}
|
||||
|
||||
for (const v of data) {
|
||||
await server.servers.waitUntilLog('Removed files of video ' + v.url, 1, true)
|
||||
}
|
||||
|
||||
await cleanupTests([ server ])
|
||||
})
|
||||
})
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue