aboutsummaryrefslogtreecommitdiffhomepage
path: root/server/tests/api/videos/video-description.ts
diff options
context:
space:
mode:
authorChocobozzz <me@florianbigard.com>2021-07-16 09:04:35 +0200
committerChocobozzz <me@florianbigard.com>2021-07-20 15:27:18 +0200
commit89d241a79c262b9775c233b73cff080043ebb5e6 (patch)
treecb3b6cb431d25d891ef4e02f66c61d252d17048f /server/tests/api/videos/video-description.ts
parentd23dd9fbfc4d26026352c10f81d2795ceaf2908a (diff)
downloadPeerTube-89d241a79c262b9775c233b73cff080043ebb5e6.tar.gz
PeerTube-89d241a79c262b9775c233b73cff080043ebb5e6.tar.zst
PeerTube-89d241a79c262b9775c233b73cff080043ebb5e6.zip
Shorter server command names
Diffstat (limited to 'server/tests/api/videos/video-description.ts')
-rw-r--r--server/tests/api/videos/video-description.ts16
1 files changed, 8 insertions, 8 deletions
diff --git a/server/tests/api/videos/video-description.ts b/server/tests/api/videos/video-description.ts
index 6ac9206f5..b89247288 100644
--- a/server/tests/api/videos/video-description.ts
+++ b/server/tests/api/videos/video-description.ts
@@ -31,11 +31,11 @@ describe('Test video description', function () {
31 const attributes = { 31 const attributes = {
32 description: longDescription 32 description: longDescription
33 } 33 }
34 await servers[0].videosCommand.upload({ attributes }) 34 await servers[0].videos.upload({ attributes })
35 35
36 await waitJobs(servers) 36 await waitJobs(servers)
37 37
38 const { data } = await servers[0].videosCommand.list() 38 const { data } = await servers[0].videos.list()
39 39
40 videoId = data[0].id 40 videoId = data[0].id
41 videoUUID = data[0].uuid 41 videoUUID = data[0].uuid
@@ -43,7 +43,7 @@ describe('Test video description', function () {
43 43
44 it('Should have a truncated description on each server', async function () { 44 it('Should have a truncated description on each server', async function () {
45 for (const server of servers) { 45 for (const server of servers) {
46 const video = await server.videosCommand.get({ id: videoUUID }) 46 const video = await server.videos.get({ id: videoUUID })
47 47
48 // 30 characters * 6 -> 240 characters 48 // 30 characters * 6 -> 240 characters
49 const truncatedDescription = 'my super description for server 1'.repeat(7) + 49 const truncatedDescription = 'my super description for server 1'.repeat(7) +
@@ -55,9 +55,9 @@ describe('Test video description', function () {
55 55
56 it('Should fetch long description on each server', async function () { 56 it('Should fetch long description on each server', async function () {
57 for (const server of servers) { 57 for (const server of servers) {
58 const video = await server.videosCommand.get({ id: videoUUID }) 58 const video = await server.videos.get({ id: videoUUID })
59 59
60 const { description } = await server.videosCommand.getDescription({ descriptionPath: video.descriptionPath }) 60 const { description } = await server.videos.getDescription({ descriptionPath: video.descriptionPath })
61 expect(description).to.equal(longDescription) 61 expect(description).to.equal(longDescription)
62 } 62 }
63 }) 63 })
@@ -68,18 +68,18 @@ describe('Test video description', function () {
68 const attributes = { 68 const attributes = {
69 description: 'short description' 69 description: 'short description'
70 } 70 }
71 await servers[0].videosCommand.update({ id: videoId, attributes }) 71 await servers[0].videos.update({ id: videoId, attributes })
72 72
73 await waitJobs(servers) 73 await waitJobs(servers)
74 }) 74 })
75 75
76 it('Should have a small description on each server', async function () { 76 it('Should have a small description on each server', async function () {
77 for (const server of servers) { 77 for (const server of servers) {
78 const video = await server.videosCommand.get({ id: videoUUID }) 78 const video = await server.videos.get({ id: videoUUID })
79 79
80 expect(video.description).to.equal('short description') 80 expect(video.description).to.equal('short description')
81 81
82 const { description } = await server.videosCommand.getDescription({ descriptionPath: video.descriptionPath }) 82 const { description } = await server.videos.getDescription({ descriptionPath: video.descriptionPath })
83 expect(description).to.equal('short description') 83 expect(description).to.equal('short description')
84 } 84 }
85 }) 85 })