diff options
author | Chocobozzz <me@florianbigard.com> | 2021-07-16 09:47:51 +0200 |
---|---|---|
committer | Chocobozzz <me@florianbigard.com> | 2021-07-20 15:27:18 +0200 |
commit | 254d3579f5338f5fd775c17d15cdfc37078bcfb4 (patch) | |
tree | eaeb13fda16c16e98cd6991d202b0ca6a4cbdb63 /server/tests/api/videos/video-channels.ts | |
parent | 89d241a79c262b9775c233b73cff080043ebb5e6 (diff) | |
download | PeerTube-254d3579f5338f5fd775c17d15cdfc37078bcfb4.tar.gz PeerTube-254d3579f5338f5fd775c17d15cdfc37078bcfb4.tar.zst PeerTube-254d3579f5338f5fd775c17d15cdfc37078bcfb4.zip |
Use an object to represent a server
Diffstat (limited to 'server/tests/api/videos/video-channels.ts')
-rw-r--r-- | server/tests/api/videos/video-channels.ts | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/server/tests/api/videos/video-channels.ts b/server/tests/api/videos/video-channels.ts index 1efef932c..140fee7fe 100644 --- a/server/tests/api/videos/video-channels.ts +++ b/server/tests/api/videos/video-channels.ts | |||
@@ -7,8 +7,8 @@ import { ACTOR_IMAGES_SIZE } from '@server/initializers/constants' | |||
7 | import { | 7 | import { |
8 | cleanupTests, | 8 | cleanupTests, |
9 | doubleFollow, | 9 | doubleFollow, |
10 | flushAndRunMultipleServers, | 10 | createMultipleServers, |
11 | ServerInfo, | 11 | PeerTubeServer, |
12 | setAccessTokensToServers, | 12 | setAccessTokensToServers, |
13 | setDefaultVideoChannel, | 13 | setDefaultVideoChannel, |
14 | testFileExistsOrNot, | 14 | testFileExistsOrNot, |
@@ -20,14 +20,14 @@ import { User, VideoChannel } from '@shared/models' | |||
20 | 20 | ||
21 | const expect = chai.expect | 21 | const expect = chai.expect |
22 | 22 | ||
23 | async function findChannel (server: ServerInfo, channelId: number) { | 23 | async function findChannel (server: PeerTubeServer, channelId: number) { |
24 | const body = await server.channels.list({ sort: '-name' }) | 24 | const body = await server.channels.list({ sort: '-name' }) |
25 | 25 | ||
26 | return body.data.find(c => c.id === channelId) | 26 | return body.data.find(c => c.id === channelId) |
27 | } | 27 | } |
28 | 28 | ||
29 | describe('Test video channels', function () { | 29 | describe('Test video channels', function () { |
30 | let servers: ServerInfo[] | 30 | let servers: PeerTubeServer[] |
31 | let userInfo: User | 31 | let userInfo: User |
32 | let secondVideoChannelId: number | 32 | let secondVideoChannelId: number |
33 | let totoChannel: number | 33 | let totoChannel: number |
@@ -40,7 +40,7 @@ describe('Test video channels', function () { | |||
40 | before(async function () { | 40 | before(async function () { |
41 | this.timeout(60000) | 41 | this.timeout(60000) |
42 | 42 | ||
43 | servers = await flushAndRunMultipleServers(2) | 43 | servers = await createMultipleServers(2) |
44 | 44 | ||
45 | await setAccessTokensToServers(servers) | 45 | await setAccessTokensToServers(servers) |
46 | await setDefaultVideoChannel(servers) | 46 | await setDefaultVideoChannel(servers) |