From 254d3579f5338f5fd775c17d15cdfc37078bcfb4 Mon Sep 17 00:00:00 2001 From: Chocobozzz Date: Fri, 16 Jul 2021 09:47:51 +0200 Subject: Use an object to represent a server --- server/tests/api/activitypub/refresher.ts | 11 +++++------ 1 file changed, 5 insertions(+), 6 deletions(-) (limited to 'server/tests/api/activitypub/refresher.ts') diff --git a/server/tests/api/activitypub/refresher.ts b/server/tests/api/activitypub/refresher.ts index d2f71e857..bbec0d309 100644 --- a/server/tests/api/activitypub/refresher.ts +++ b/server/tests/api/activitypub/refresher.ts @@ -5,10 +5,9 @@ import { HttpStatusCode } from '@shared/core-utils' import { cleanupTests, doubleFollow, - flushAndRunMultipleServers, + createMultipleServers, killallServers, - reRunServer, - ServerInfo, + PeerTubeServer, setAccessTokensToServers, setDefaultVideoChannel, wait, @@ -17,7 +16,7 @@ import { import { VideoPlaylistPrivacy } from '@shared/models' describe('Test AP refresher', function () { - let servers: ServerInfo[] = [] + let servers: PeerTubeServer[] = [] let videoUUID1: string let videoUUID2: string let videoUUID3: string @@ -27,7 +26,7 @@ describe('Test AP refresher', function () { before(async function () { this.timeout(60000) - servers = await flushAndRunMultipleServers(2, { transcoding: { enabled: false } }) + servers = await createMultipleServers(2, { transcoding: { enabled: false } }) // Get the access tokens await setAccessTokensToServers(servers) @@ -95,7 +94,7 @@ describe('Test AP refresher', function () { // The refresh should fail await waitJobs([ servers[0] ]) - await reRunServer(servers[1]) + await servers[1].run() await servers[0].videos.get({ id: videoUUID3 }) }) -- cgit v1.2.3