aboutsummaryrefslogtreecommitdiffhomepage
path: root/server/tests
diff options
context:
space:
mode:
authorChocobozzz <me@florianbigard.com>2022-08-12 11:05:11 +0200
committerChocobozzz <me@florianbigard.com>2022-08-16 10:33:27 +0200
commit0e6cd1c00f71554fe7375a96db693a6983951ba6 (patch)
treebe9b049e047895c88c561202377f6c5e64ae40df /server/tests
parent045224d5eb6a41081186c4040bab1570b9d9ad65 (diff)
downloadPeerTube-0e6cd1c00f71554fe7375a96db693a6983951ba6.tar.gz
PeerTube-0e6cd1c00f71554fe7375a96db693a6983951ba6.tar.zst
PeerTube-0e6cd1c00f71554fe7375a96db693a6983951ba6.zip
Add ability to list comments on local videos
Diffstat (limited to 'server/tests')
-rw-r--r--server/tests/api/videos/video-comments.ts16
1 files changed, 16 insertions, 0 deletions
diff --git a/server/tests/api/videos/video-comments.ts b/server/tests/api/videos/video-comments.ts
index 1488ce2b5..5ab401aa4 100644
--- a/server/tests/api/videos/video-comments.ts
+++ b/server/tests/api/videos/video-comments.ts
@@ -254,6 +254,22 @@ describe('Test video comments', function () {
254 expect(total).to.equal(0) 254 expect(total).to.equal(0)
255 }) 255 })
256 256
257 it('Should filter instance comments by onLocalVideo', async function () {
258 {
259 const { total, data } = await command.listForAdmin({ onLocalVideo: false })
260
261 expect(data).to.have.lengthOf(0)
262 expect(total).to.equal(0)
263 }
264
265 {
266 const { total, data } = await command.listForAdmin({ onLocalVideo: true })
267
268 expect(data).to.not.have.lengthOf(0)
269 expect(total).to.not.equal(0)
270 }
271 })
272
257 it('Should search instance comments by account', async function () { 273 it('Should search instance comments by account', async function () {
258 const { total, data } = await command.listForAdmin({ searchAccount: 'user' }) 274 const { total, data } = await command.listForAdmin({ searchAccount: 'user' })
259 275