aboutsummaryrefslogtreecommitdiffhomepage
path: root/server/tests/external-plugins/auto-mute.ts
diff options
context:
space:
mode:
authorChocobozzz <me@florianbigard.com>2021-07-07 16:02:46 +0200
committerChocobozzz <me@florianbigard.com>2021-07-20 15:27:17 +0200
commit5f8bd4cbb178290da7d8f81e996f19f0eccc8e4c (patch)
tree02d056121540652b0867fc2ef56699138afe6271 /server/tests/external-plugins/auto-mute.ts
parent9fff08cf83f34339df7ed4ac770e1dee536adf9d (diff)
downloadPeerTube-5f8bd4cbb178290da7d8f81e996f19f0eccc8e4c.tar.gz
PeerTube-5f8bd4cbb178290da7d8f81e996f19f0eccc8e4c.tar.zst
PeerTube-5f8bd4cbb178290da7d8f81e996f19f0eccc8e4c.zip
Introduce blocklist command
Diffstat (limited to 'server/tests/external-plugins/auto-mute.ts')
-rw-r--r--server/tests/external-plugins/auto-mute.ts9
1 files changed, 3 insertions, 6 deletions
diff --git a/server/tests/external-plugins/auto-mute.ts b/server/tests/external-plugins/auto-mute.ts
index 8fcf94452..f86c83808 100644
--- a/server/tests/external-plugins/auto-mute.ts
+++ b/server/tests/external-plugins/auto-mute.ts
@@ -4,8 +4,6 @@ import 'mocha'
4import { expect } from 'chai' 4import { expect } from 'chai'
5import { HttpStatusCode } from '@shared/core-utils' 5import { HttpStatusCode } from '@shared/core-utils'
6import { 6import {
7 addAccountToServerBlocklist,
8 addServerToAccountBlocklist,
9 cleanupTests, 7 cleanupTests,
10 doubleFollow, 8 doubleFollow,
11 flushAndRunMultipleServers, 9 flushAndRunMultipleServers,
@@ -13,7 +11,6 @@ import {
13 killallServers, 11 killallServers,
14 makeGetRequest, 12 makeGetRequest,
15 MockBlocklist, 13 MockBlocklist,
16 removeAccountFromServerBlocklist,
17 reRunServer, 14 reRunServer,
18 ServerInfo, 15 ServerInfo,
19 setAccessTokensToServers, 16 setAccessTokensToServers,
@@ -147,7 +144,7 @@ describe('Official plugin auto-mute', function () {
147 expect(res.body.total).to.equal(1) 144 expect(res.body.total).to.equal(1)
148 } 145 }
149 146
150 await removeAccountFromServerBlocklist(servers[0].url, servers[0].accessToken, account) 147 await servers[0].blocklistCommand.removeFromServerBlocklist({ account })
151 148
152 { 149 {
153 const res = await getVideosList(servers[0].url) 150 const res = await getVideosList(servers[0].url)
@@ -201,8 +198,8 @@ describe('Official plugin auto-mute', function () {
201 } 198 }
202 }) 199 })
203 200
204 await addAccountToServerBlocklist(servers[0].url, servers[0].accessToken, 'root@localhost:' + servers[1].port) 201 await servers[0].blocklistCommand.addToServerBlocklist({ account: 'root@localhost:' + servers[1].port })
205 await addServerToAccountBlocklist(servers[0].url, servers[0].accessToken, 'localhost:' + servers[1].port) 202 await servers[0].blocklistCommand.addToMyBlocklist({ server: 'localhost:' + servers[1].port })
206 203
207 const res = await makeGetRequest({ 204 const res = await makeGetRequest({
208 url: servers[0].url, 205 url: servers[0].url,