+
+ it('Should run action:live.video.state.updated', async function () {
+ this.timeout(60000)
+
+ const attributes = {
+ name: 'live',
+ privacy: VideoPrivacy.PUBLIC,
+ channelId: servers[0].store.channel.id
+ }
+
+ const { uuid: liveVideoId } = await servers[0].live.create({ fields: attributes })
+ const ffmpegCommand = await servers[0].live.sendRTMPStreamInVideo({ videoId: liveVideoId })
+ await servers[0].live.waitUntilPublished({ videoId: liveVideoId })
+ await waitJobs(servers)
+
+ await checkHook('action:live.video.state.updated', true, 1)
+
+ await stopFfmpeg(ffmpegCommand)
+ await servers[0].live.waitUntilEnded({ videoId: liveVideoId })
+ await waitJobs(servers)
+
+ await checkHook('action:live.video.state.updated', true, 2)
+ })