From f89189907bbdff6c4bc6d3460ed9ef4c49515f17 Mon Sep 17 00:00:00 2001 From: Chocobozzz Date: Tue, 23 May 2023 10:49:45 +0200 Subject: Prevent object storage mock conflicts When running tests in parallel --- server/tests/api/transcoding/update-while-transcoding.ts | 12 +++++++++--- 1 file changed, 9 insertions(+), 3 deletions(-) (limited to 'server/tests/api/transcoding/update-while-transcoding.ts') diff --git a/server/tests/api/transcoding/update-while-transcoding.ts b/server/tests/api/transcoding/update-while-transcoding.ts index f4d728118..61655f102 100644 --- a/server/tests/api/transcoding/update-while-transcoding.ts +++ b/server/tests/api/transcoding/update-while-transcoding.ts @@ -135,17 +135,23 @@ describe('Test update video privacy while transcoding', function () { describe('With object storage enabled', function () { if (areMockObjectStorageTestsDisabled()) return + const objectStorage = new ObjectStorageCommand() + before(async function () { this.timeout(120000) - const configOverride = ObjectStorageCommand.getDefaultMockConfig() - await ObjectStorageCommand.prepareDefaultMockBuckets() + const configOverride = objectStorage.getDefaultMockConfig() + await objectStorage.prepareDefaultMockBuckets() await servers[0].kill() await servers[0].run(configOverride) }) - runTestSuite(true, ObjectStorageCommand.getMockPlaylistBaseUrl()) + runTestSuite(true, objectStorage.getMockPlaylistBaseUrl()) + + after(async function () { + await objectStorage.cleanupMock() + }) }) after(async function () { -- cgit v1.2.3