aboutsummaryrefslogtreecommitdiffhomepage
path: root/server/tests/api/live/live-constraints.ts
diff options
context:
space:
mode:
Diffstat (limited to 'server/tests/api/live/live-constraints.ts')
-rw-r--r--server/tests/api/live/live-constraints.ts11
1 files changed, 9 insertions, 2 deletions
diff --git a/server/tests/api/live/live-constraints.ts b/server/tests/api/live/live-constraints.ts
index 37fd5b2a6..168241b79 100644
--- a/server/tests/api/live/live-constraints.ts
+++ b/server/tests/api/live/live-constraints.ts
@@ -173,6 +173,8 @@ describe('Test live constraints', function () {
173 173
174 await servers[0].live.waitUntilPublished({ videoId: userVideoLiveoId }) 174 await servers[0].live.waitUntilPublished({ videoId: userVideoLiveoId })
175 175
176 const baseQuota = await servers[0].users.getMyQuotaUsed({ token: userAccessToken })
177
176 await wait(3000) 178 await wait(3000)
177 179
178 const quotaUser = await servers[0].users.getMyQuotaUsed({ token: userAccessToken }) 180 const quotaUser = await servers[0].users.getMyQuotaUsed({ token: userAccessToken })
@@ -180,11 +182,16 @@ describe('Test live constraints', function () {
180 const { data } = await servers[0].users.list() 182 const { data } = await servers[0].users.list()
181 const quotaAdmin = data.find(u => u.username === 'user1') 183 const quotaAdmin = data.find(u => u.username === 'user1')
182 184
183 expect(quotaUser.videoQuotaUsed).to.equal(quotaAdmin.videoQuotaUsed) 185 expect(quotaUser.videoQuotaUsed).to.be.above(baseQuota.videoQuotaUsed)
184 expect(quotaUser.videoQuotaUsedDaily).to.equal(quotaAdmin.videoQuotaUsedDaily) 186 expect(quotaUser.videoQuotaUsedDaily).to.be.above(baseQuota.videoQuotaUsedDaily)
187
188 expect(quotaAdmin.videoQuotaUsed).to.be.above(baseQuota.videoQuotaUsed)
189 expect(quotaAdmin.videoQuotaUsedDaily).to.be.above(baseQuota.videoQuotaUsedDaily)
185 190
186 expect(quotaUser.videoQuotaUsed).to.be.above(10) 191 expect(quotaUser.videoQuotaUsed).to.be.above(10)
187 expect(quotaUser.videoQuotaUsedDaily).to.be.above(10) 192 expect(quotaUser.videoQuotaUsedDaily).to.be.above(10)
193 expect(quotaAdmin.videoQuotaUsed).to.be.above(10)
194 expect(quotaAdmin.videoQuotaUsedDaily).to.be.above(10)
188 195
189 await stopFfmpeg(ffmpegCommand) 196 await stopFfmpeg(ffmpegCommand)
190 }) 197 })