From 2c27e70471120c92e0bc8c8114141fbb31ff98ac Mon Sep 17 00:00:00 2001 From: Chocobozzz Date: Wed, 7 Jul 2021 16:40:49 +0200 Subject: Introduce subscriptions command --- server/tests/api/moderation/blocklist-notification.ts | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) (limited to 'server/tests/api/moderation/blocklist-notification.ts') diff --git a/server/tests/api/moderation/blocklist-notification.ts b/server/tests/api/moderation/blocklist-notification.ts index 99da64a2d..5b9699816 100644 --- a/server/tests/api/moderation/blocklist-notification.ts +++ b/server/tests/api/moderation/blocklist-notification.ts @@ -3,7 +3,6 @@ import 'mocha' import * as chai from 'chai' import { - addUserSubscription, addVideoCommentThread, cleanupTests, createUser, @@ -11,7 +10,6 @@ import { flushAndRunMultipleServers, getUserNotifications, markAsReadAllNotifications, - removeUserSubscription, ServerInfo, setAccessTokensToServers, uploadVideo, @@ -44,8 +42,8 @@ describe('Test blocklist', function () { async function resetState () { try { - await removeUserSubscription(servers[1].url, remoteUserToken, 'user1_channel@' + servers[0].host) - await removeUserSubscription(servers[1].url, remoteUserToken, 'user2_channel@' + servers[0].host) + await servers[1].subscriptionsCommand.remove({ token: remoteUserToken, uri: 'user1_channel@' + servers[0].host }) + await servers[1].subscriptionsCommand.remove({ token: remoteUserToken, uri: 'user2_channel@' + servers[0].host }) } catch {} await waitJobs(servers) @@ -66,8 +64,8 @@ describe('Test blocklist', function () { { - await addUserSubscription(servers[1].url, remoteUserToken, 'user1_channel@' + servers[0].host) - await addUserSubscription(servers[1].url, remoteUserToken, 'user2_channel@' + servers[0].host) + await servers[1].subscriptionsCommand.add({ token: remoteUserToken, targetUri: 'user1_channel@' + servers[0].host }) + await servers[1].subscriptionsCommand.add({ token: remoteUserToken, targetUri: 'user2_channel@' + servers[0].host }) } await waitJobs(servers) -- cgit v1.2.3