diff options
author | Chocobozzz <me@florianbigard.com> | 2021-07-08 10:18:40 +0200 |
---|---|---|
committer | Chocobozzz <me@florianbigard.com> | 2021-07-20 15:27:17 +0200 |
commit | 4f2199144e428c16460750305f737b890c1ac322 (patch) | |
tree | a19c5c0f254ab0b32d6c8838af33a1ba260e4877 /server/tests/api/live/live-views.ts | |
parent | 2c27e70471120c92e0bc8c8114141fbb31ff98ac (diff) | |
download | PeerTube-4f2199144e428c16460750305f737b890c1ac322.tar.gz PeerTube-4f2199144e428c16460750305f737b890c1ac322.tar.zst PeerTube-4f2199144e428c16460750305f737b890c1ac322.zip |
Introduce live command
Diffstat (limited to 'server/tests/api/live/live-views.ts')
-rw-r--r-- | server/tests/api/live/live-views.ts | 8 |
1 files changed, 3 insertions, 5 deletions
diff --git a/server/tests/api/live/live-views.ts b/server/tests/api/live/live-views.ts index ca571c962..ae6af7cfd 100644 --- a/server/tests/api/live/live-views.ts +++ b/server/tests/api/live/live-views.ts | |||
@@ -6,11 +6,9 @@ import { FfmpegCommand } from 'fluent-ffmpeg' | |||
6 | import { VideoDetails, VideoPrivacy } from '@shared/models' | 6 | import { VideoDetails, VideoPrivacy } from '@shared/models' |
7 | import { | 7 | import { |
8 | cleanupTests, | 8 | cleanupTests, |
9 | createLive, | ||
10 | doubleFollow, | 9 | doubleFollow, |
11 | flushAndRunMultipleServers, | 10 | flushAndRunMultipleServers, |
12 | getVideo, | 11 | getVideo, |
13 | sendRTMPStreamInVideo, | ||
14 | ServerInfo, | 12 | ServerInfo, |
15 | setAccessTokensToServers, | 13 | setAccessTokensToServers, |
16 | setDefaultVideoChannel, | 14 | setDefaultVideoChannel, |
@@ -73,10 +71,10 @@ describe('Test live', function () { | |||
73 | privacy: VideoPrivacy.PUBLIC | 71 | privacy: VideoPrivacy.PUBLIC |
74 | } | 72 | } |
75 | 73 | ||
76 | const res = await createLive(servers[0].url, servers[0].accessToken, liveAttributes) | 74 | const live = await servers[0].liveCommand.createLive({ fields: liveAttributes }) |
77 | liveVideoId = res.body.video.uuid | 75 | liveVideoId = live.uuid |
78 | 76 | ||
79 | command = await sendRTMPStreamInVideo(servers[0].url, servers[0].accessToken, liveVideoId) | 77 | command = await servers[0].liveCommand.sendRTMPStreamInVideo({ videoId: liveVideoId }) |
80 | await waitUntilLivePublishedOnAllServers(servers, liveVideoId) | 78 | await waitUntilLivePublishedOnAllServers(servers, liveVideoId) |
81 | await waitJobs(servers) | 79 | await waitJobs(servers) |
82 | }) | 80 | }) |