X-Git-Url: https://git.immae.eu/?a=blobdiff_plain;f=server%2Ftests%2Fapi%2Fserver%2Fauto-follows.ts;h=1519b263fb0eb54dac0c53d3b69b817a83fd800b;hb=693c6586cb896a84ff0f897b1c242bcf7bdcbaee;hp=5f48dc0ebf2c9fee5effed01d4b88d4ab7aa5ab7;hpb=338eb9d33af690db716805fd2277bf68f473b58f;p=github%2FChocobozzz%2FPeerTube.git diff --git a/server/tests/api/server/auto-follows.ts b/server/tests/api/server/auto-follows.ts index 5f48dc0eb..1519b263f 100644 --- a/server/tests/api/server/auto-follows.ts +++ b/server/tests/api/server/auto-follows.ts @@ -1,7 +1,7 @@ /* eslint-disable @typescript-eslint/no-unused-expressions,@typescript-eslint/require-await */ -import * as chai from 'chai' import 'mocha' +import * as chai from 'chai' import { acceptFollower, cleanupTests, @@ -153,9 +153,10 @@ describe('Test auto follows', function () { describe('Auto follow index', function () { const instanceIndexServer = new MockInstancesIndex() + let port: number before(async () => { - await instanceIndexServer.initialize() + port = await instanceIndexServer.initialize() }) it('Should not auto follow index if the option is not enabled', async function () { @@ -177,7 +178,7 @@ describe('Test auto follows', function () { followings: { instance: { autoFollowIndex: { - indexUrl: 'http://localhost:42100', + indexUrl: `http://localhost:${port}/api/v1/instances/hosts`, enabled: true } }