+ expect(res.body.data[0].name).to.equal('root_channel')
+ expect(res.body.data[0].displayName).to.equal('Main root channel')
+ })
+
+ it('Should update video channel', async function () {
+ this.timeout(15000)
+
+ const videoChannelAttributes = {
+ displayName: 'video channel updated',
+ description: 'video channel description updated',
+ support: 'support updated'
+ }
+
+ await updateVideoChannel(servers[0].url, servers[0].accessToken, 'second_video_channel', videoChannelAttributes)
+
+ await waitJobs(servers)
+ })
+
+ it('Should have video channel updated', async function () {
+ for (const server of servers) {
+ const res = await getVideoChannelsList(server.url, 0, 1, '-name')
+
+ expect(res.body.total).to.equal(2)
+ expect(res.body.data).to.be.an('array')
+ expect(res.body.data).to.have.lengthOf(1)
+ expect(res.body.data[0].name).to.equal('second_video_channel')
+ expect(res.body.data[0].displayName).to.equal('video channel updated')
+ expect(res.body.data[0].description).to.equal('video channel description updated')
+ expect(res.body.data[0].support).to.equal('support updated')
+ }
+ })
+
+ it('Should not have updated the video support field', async function () {
+ for (const server of servers) {
+ const res = await getVideo(server.url, videoUUID)
+ const video: VideoDetails = res.body
+
+ expect(video.support).to.equal('video support field')
+ }