diff options
Diffstat (limited to 'server/tests/plugins')
-rw-r--r-- | server/tests/plugins/filter-hooks.ts | 8 | ||||
-rw-r--r-- | server/tests/plugins/plugin-helpers.ts | 1 | ||||
-rw-r--r-- | server/tests/plugins/plugin-transcoding.ts | 20 |
3 files changed, 15 insertions, 14 deletions
diff --git a/server/tests/plugins/filter-hooks.ts b/server/tests/plugins/filter-hooks.ts index ac958c5f5..1d6bb6cf4 100644 --- a/server/tests/plugins/filter-hooks.ts +++ b/server/tests/plugins/filter-hooks.ts | |||
@@ -38,6 +38,7 @@ import { | |||
38 | import { cleanupTests, flushAndRunMultipleServers, ServerInfo, waitUntilLog } from '../../../shared/extra-utils/server/servers' | 38 | import { cleanupTests, flushAndRunMultipleServers, ServerInfo, waitUntilLog } from '../../../shared/extra-utils/server/servers' |
39 | import { getGoodVideoUrl, getMyVideoImports, importVideo } from '../../../shared/extra-utils/videos/video-imports' | 39 | import { getGoodVideoUrl, getMyVideoImports, importVideo } from '../../../shared/extra-utils/videos/video-imports' |
40 | import { | 40 | import { |
41 | VideoCommentThreadTree, | ||
41 | VideoDetails, | 42 | VideoDetails, |
42 | VideoImport, | 43 | VideoImport, |
43 | VideoImportState, | 44 | VideoImportState, |
@@ -45,7 +46,6 @@ import { | |||
45 | VideoPlaylistPrivacy, | 46 | VideoPlaylistPrivacy, |
46 | VideoPrivacy | 47 | VideoPrivacy |
47 | } from '../../../shared/models/videos' | 48 | } from '../../../shared/models/videos' |
48 | import { VideoCommentThreadTree } from '../../../shared/models/videos/video-comment.model' | ||
49 | 49 | ||
50 | const expect = chai.expect | 50 | const expect = chai.expect |
51 | 51 | ||
@@ -55,7 +55,7 @@ describe('Test plugin filter hooks', function () { | |||
55 | let threadId: number | 55 | let threadId: number |
56 | 56 | ||
57 | before(async function () { | 57 | before(async function () { |
58 | this.timeout(30000) | 58 | this.timeout(60000) |
59 | 59 | ||
60 | servers = await flushAndRunMultipleServers(2) | 60 | servers = await flushAndRunMultipleServers(2) |
61 | await setAccessTokensToServers(servers) | 61 | await setAccessTokensToServers(servers) |
@@ -326,7 +326,7 @@ describe('Test plugin filter hooks', function () { | |||
326 | }) | 326 | }) |
327 | 327 | ||
328 | it('Should blacklist on remote upload', async function () { | 328 | it('Should blacklist on remote upload', async function () { |
329 | this.timeout(45000) | 329 | this.timeout(60000) |
330 | 330 | ||
331 | const res = await uploadVideo(servers[1].url, servers[1].accessToken, { name: 'remote please blacklist me' }) | 331 | const res = await uploadVideo(servers[1].url, servers[1].accessToken, { name: 'remote please blacklist me' }) |
332 | await waitJobs(servers) | 332 | await waitJobs(servers) |
@@ -335,7 +335,7 @@ describe('Test plugin filter hooks', function () { | |||
335 | }) | 335 | }) |
336 | 336 | ||
337 | it('Should blacklist on remote update', async function () { | 337 | it('Should blacklist on remote update', async function () { |
338 | this.timeout(45000) | 338 | this.timeout(60000) |
339 | 339 | ||
340 | const res = await uploadVideo(servers[1].url, servers[1].accessToken, { name: 'video' }) | 340 | const res = await uploadVideo(servers[1].url, servers[1].accessToken, { name: 'video' }) |
341 | await waitJobs(servers) | 341 | await waitJobs(servers) |
diff --git a/server/tests/plugins/plugin-helpers.ts b/server/tests/plugins/plugin-helpers.ts index 20020ec41..f72de8229 100644 --- a/server/tests/plugins/plugin-helpers.ts +++ b/server/tests/plugins/plugin-helpers.ts | |||
@@ -133,6 +133,7 @@ describe('Test plugin helpers', function () { | |||
133 | }) | 133 | }) |
134 | 134 | ||
135 | expect(res.body.username).to.equal('root') | 135 | expect(res.body.username).to.equal('root') |
136 | expect(res.body.displayName).to.equal('root') | ||
136 | expect(res.body.isAdmin).to.be.true | 137 | expect(res.body.isAdmin).to.be.true |
137 | expect(res.body.isModerator).to.be.false | 138 | expect(res.body.isModerator).to.be.false |
138 | expect(res.body.isUser).to.be.false | 139 | expect(res.body.isUser).to.be.false |
diff --git a/server/tests/plugins/plugin-transcoding.ts b/server/tests/plugins/plugin-transcoding.ts index c834b6985..eefb2294d 100644 --- a/server/tests/plugins/plugin-transcoding.ts +++ b/server/tests/plugins/plugin-transcoding.ts | |||
@@ -125,7 +125,7 @@ describe('Test transcoding plugins', function () { | |||
125 | }) | 125 | }) |
126 | 126 | ||
127 | it('Should not use the plugin profile if not chosen by the admin', async function () { | 127 | it('Should not use the plugin profile if not chosen by the admin', async function () { |
128 | this.timeout(120000) | 128 | this.timeout(240000) |
129 | 129 | ||
130 | const videoUUID = (await uploadVideoAndGetId({ server, videoName: 'video' })).uuid | 130 | const videoUUID = (await uploadVideoAndGetId({ server, videoName: 'video' })).uuid |
131 | await waitJobs([ server ]) | 131 | await waitJobs([ server ]) |
@@ -134,7 +134,7 @@ describe('Test transcoding plugins', function () { | |||
134 | }) | 134 | }) |
135 | 135 | ||
136 | it('Should use the vod profile', async function () { | 136 | it('Should use the vod profile', async function () { |
137 | this.timeout(120000) | 137 | this.timeout(240000) |
138 | 138 | ||
139 | await updateConf(server, 'low-vod', 'default') | 139 | await updateConf(server, 'low-vod', 'default') |
140 | 140 | ||
@@ -145,7 +145,7 @@ describe('Test transcoding plugins', function () { | |||
145 | }) | 145 | }) |
146 | 146 | ||
147 | it('Should apply input options in vod profile', async function () { | 147 | it('Should apply input options in vod profile', async function () { |
148 | this.timeout(120000) | 148 | this.timeout(240000) |
149 | 149 | ||
150 | await updateConf(server, 'input-options-vod', 'default') | 150 | await updateConf(server, 'input-options-vod', 'default') |
151 | 151 | ||
@@ -156,7 +156,7 @@ describe('Test transcoding plugins', function () { | |||
156 | }) | 156 | }) |
157 | 157 | ||
158 | it('Should apply the scale filter in vod profile', async function () { | 158 | it('Should apply the scale filter in vod profile', async function () { |
159 | this.timeout(120000) | 159 | this.timeout(240000) |
160 | 160 | ||
161 | await updateConf(server, 'bad-scale-vod', 'default') | 161 | await updateConf(server, 'bad-scale-vod', 'default') |
162 | 162 | ||
@@ -172,7 +172,7 @@ describe('Test transcoding plugins', function () { | |||
172 | }) | 172 | }) |
173 | 173 | ||
174 | it('Should not use the plugin profile if not chosen by the admin', async function () { | 174 | it('Should not use the plugin profile if not chosen by the admin', async function () { |
175 | this.timeout(120000) | 175 | this.timeout(240000) |
176 | 176 | ||
177 | const liveVideoId = await createLiveWrapper(server) | 177 | const liveVideoId = await createLiveWrapper(server) |
178 | 178 | ||
@@ -184,7 +184,7 @@ describe('Test transcoding plugins', function () { | |||
184 | }) | 184 | }) |
185 | 185 | ||
186 | it('Should use the live profile', async function () { | 186 | it('Should use the live profile', async function () { |
187 | this.timeout(120000) | 187 | this.timeout(240000) |
188 | 188 | ||
189 | await updateConf(server, 'low-vod', 'low-live') | 189 | await updateConf(server, 'low-vod', 'low-live') |
190 | 190 | ||
@@ -198,7 +198,7 @@ describe('Test transcoding plugins', function () { | |||
198 | }) | 198 | }) |
199 | 199 | ||
200 | it('Should apply the input options on live profile', async function () { | 200 | it('Should apply the input options on live profile', async function () { |
201 | this.timeout(120000) | 201 | this.timeout(240000) |
202 | 202 | ||
203 | await updateConf(server, 'low-vod', 'input-options-live') | 203 | await updateConf(server, 'low-vod', 'input-options-live') |
204 | 204 | ||
@@ -212,7 +212,7 @@ describe('Test transcoding plugins', function () { | |||
212 | }) | 212 | }) |
213 | 213 | ||
214 | it('Should apply the scale filter name on live profile', async function () { | 214 | it('Should apply the scale filter name on live profile', async function () { |
215 | this.timeout(120000) | 215 | this.timeout(240000) |
216 | 216 | ||
217 | await updateConf(server, 'low-vod', 'bad-scale-live') | 217 | await updateConf(server, 'low-vod', 'bad-scale-live') |
218 | 218 | ||
@@ -223,7 +223,7 @@ describe('Test transcoding plugins', function () { | |||
223 | }) | 223 | }) |
224 | 224 | ||
225 | it('Should default to the default profile if the specified profile does not exist', async function () { | 225 | it('Should default to the default profile if the specified profile does not exist', async function () { |
226 | this.timeout(120000) | 226 | this.timeout(240000) |
227 | 227 | ||
228 | await uninstallPlugin({ url: server.url, accessToken: server.accessToken, npmName: 'peertube-plugin-test-transcoding-one' }) | 228 | await uninstallPlugin({ url: server.url, accessToken: server.accessToken, npmName: 'peertube-plugin-test-transcoding-one' }) |
229 | 229 | ||
@@ -268,7 +268,7 @@ describe('Test transcoding plugins', function () { | |||
268 | }) | 268 | }) |
269 | 269 | ||
270 | it('Should use the new live encoders', async function () { | 270 | it('Should use the new live encoders', async function () { |
271 | this.timeout(120000) | 271 | this.timeout(240000) |
272 | 272 | ||
273 | const liveVideoId = await createLiveWrapper(server) | 273 | const liveVideoId = await createLiveWrapper(server) |
274 | 274 | ||