aboutsummaryrefslogtreecommitdiffhomepage
path: root/server/tests
diff options
context:
space:
mode:
Diffstat (limited to 'server/tests')
-rw-r--r--server/tests/api/videos/video-playlists.ts15
1 files changed, 14 insertions, 1 deletions
diff --git a/server/tests/api/videos/video-playlists.ts b/server/tests/api/videos/video-playlists.ts
index e4d817ff8..fd5e4c4be 100644
--- a/server/tests/api/videos/video-playlists.ts
+++ b/server/tests/api/videos/video-playlists.ts
@@ -36,7 +36,8 @@ import {
36 uploadVideo, 36 uploadVideo,
37 uploadVideoAndGetId, 37 uploadVideoAndGetId,
38 userLogin, 38 userLogin,
39 waitJobs 39 waitJobs,
40 generateUserAccessToken
40} from '../../../../shared/extra-utils' 41} from '../../../../shared/extra-utils'
41import { VideoPlaylistPrivacy } from '../../../../shared/models/videos/playlist/video-playlist-privacy.model' 42import { VideoPlaylistPrivacy } from '../../../../shared/models/videos/playlist/video-playlist-privacy.model'
42import { VideoPlaylist } from '../../../../shared/models/videos/playlist/video-playlist.model' 43import { VideoPlaylist } from '../../../../shared/models/videos/playlist/video-playlist.model'
@@ -138,6 +139,18 @@ describe('Test video playlists', function () {
138 } 139 }
139 }) 140 })
140 141
142 it('Should get private playlist for a classic user', async function () {
143 const token = await generateUserAccessToken(servers[0], 'toto')
144
145 const res = await getAccountPlaylistsListWithToken(servers[0].url, token, 'toto', 0, 5)
146
147 expect(res.body.total).to.equal(1)
148 expect(res.body.data).to.have.lengthOf(1)
149
150 const playlistId = res.body.data[0].id
151 await getPlaylistVideos(servers[0].url, token, playlistId, 0, 5)
152 })
153
141 it('Should create a playlist on server 1 and have the playlist on server 2 and 3', async function () { 154 it('Should create a playlist on server 1 and have the playlist on server 2 and 3', async function () {
142 this.timeout(30000) 155 this.timeout(30000)
143 156