aboutsummaryrefslogtreecommitdiffhomepage
path: root/server
diff options
context:
space:
mode:
authorChocobozzz <me@florianbigard.com>2020-11-27 13:47:43 +0100
committerChocobozzz <me@florianbigard.com>2020-11-27 15:46:49 +0100
commite5a516e7029db1f07d56924049f4810110b01cfe (patch)
tree0ac27abbe94bb851c9d9be9b4fbf0fcb95e182fc /server
parent992f498e312efcde46f818ba719b50f1f958272f (diff)
downloadPeerTube-e5a516e7029db1f07d56924049f4810110b01cfe.tar.gz
PeerTube-e5a516e7029db1f07d56924049f4810110b01cfe.tar.zst
PeerTube-e5a516e7029db1f07d56924049f4810110b01cfe.zip
More robust live test
Diffstat (limited to 'server')
-rw-r--r--server/tests/api/live/live.ts8
1 files changed, 4 insertions, 4 deletions
diff --git a/server/tests/api/live/live.ts b/server/tests/api/live/live.ts
index f99e7ad46..843943bba 100644
--- a/server/tests/api/live/live.ts
+++ b/server/tests/api/live/live.ts
@@ -583,8 +583,8 @@ describe('Test live', function () {
583 await waitJobs(servers) 583 await waitJobs(servers)
584 584
585 for (const stateChanges of [ localStateChanges, remoteStateChanges ]) { 585 for (const stateChanges of [ localStateChanges, remoteStateChanges ]) {
586 expect(stateChanges).to.have.lengthOf(1) 586 expect(stateChanges).to.have.length.at.least(1)
587 expect(stateChanges[0]).to.equal(VideoState.PUBLISHED) 587 expect(stateChanges[stateChanges.length - 1]).to.equal(VideoState.PUBLISHED)
588 } 588 }
589 589
590 await stopFfmpeg(command) 590 await stopFfmpeg(command)
@@ -593,8 +593,8 @@ describe('Test live', function () {
593 await waitJobs(servers) 593 await waitJobs(servers)
594 594
595 for (const stateChanges of [ localStateChanges, remoteStateChanges ]) { 595 for (const stateChanges of [ localStateChanges, remoteStateChanges ]) {
596 expect(stateChanges).to.have.lengthOf(2) 596 expect(stateChanges).to.have.length.at.least(2)
597 expect(stateChanges[1]).to.equal(VideoState.LIVE_ENDED) 597 expect(stateChanges[stateChanges.length - 1]).to.equal(VideoState.LIVE_ENDED)
598 } 598 }
599 }) 599 })
600 600