aboutsummaryrefslogtreecommitdiffhomepage
path: root/server/tests/api/notifications/notifications-api.ts
diff options
context:
space:
mode:
authorChocobozzz <me@florianbigard.com>2021-07-13 09:43:59 +0200
committerChocobozzz <me@florianbigard.com>2021-07-20 15:27:18 +0200
commit6c5065a011b099618681a37bd77eaa7bd3db752e (patch)
tree352252a00b25013c4b1902f6bcd9668aba295c7b /server/tests/api/notifications/notifications-api.ts
parent0d8ecb7592577f54012413a2b5a9b159cfc90399 (diff)
downloadPeerTube-6c5065a011b099618681a37bd77eaa7bd3db752e.tar.gz
PeerTube-6c5065a011b099618681a37bd77eaa7bd3db752e.tar.zst
PeerTube-6c5065a011b099618681a37bd77eaa7bd3db752e.zip
Introduce server commands
Diffstat (limited to 'server/tests/api/notifications/notifications-api.ts')
-rw-r--r--server/tests/api/notifications/notifications-api.ts11
1 files changed, 5 insertions, 6 deletions
diff --git a/server/tests/api/notifications/notifications-api.ts b/server/tests/api/notifications/notifications-api.ts
index 447492c5f..e5864f1c2 100644
--- a/server/tests/api/notifications/notifications-api.ts
+++ b/server/tests/api/notifications/notifications-api.ts
@@ -8,7 +8,6 @@ import {
8 cleanupTests, 8 cleanupTests,
9 getAllNotificationsSettings, 9 getAllNotificationsSettings,
10 getMyUserInformation, 10 getMyUserInformation,
11 immutableAssign,
12 MockSmtpServer, 11 MockSmtpServer,
13 prepareNotificationsTest, 12 prepareNotificationsTest,
14 ServerInfo, 13 ServerInfo,
@@ -118,7 +117,7 @@ describe('Test notifications API', function () {
118 const { name, uuid } = await uploadRandomVideo(server) 117 const { name, uuid } = await uploadRandomVideo(server)
119 118
120 const check = { web: true, mail: true } 119 const check = { web: true, mail: true }
121 await checkNewVideoFromSubscription(immutableAssign(baseParams, { check }), name, uuid, 'absence') 120 await checkNewVideoFromSubscription({ ...baseParams, ...check }, name, uuid, 'absence')
122 }) 121 })
123 122
124 it('Should only have web notifications', async function () { 123 it('Should only have web notifications', async function () {
@@ -139,12 +138,12 @@ describe('Test notifications API', function () {
139 138
140 { 139 {
141 const check = { mail: true, web: false } 140 const check = { mail: true, web: false }
142 await checkNewVideoFromSubscription(immutableAssign(baseParams, { check }), name, uuid, 'absence') 141 await checkNewVideoFromSubscription({ ...baseParams, ...check }, name, uuid, 'absence')
143 } 142 }
144 143
145 { 144 {
146 const check = { mail: false, web: true } 145 const check = { mail: false, web: true }
147 await checkNewVideoFromSubscription(immutableAssign(baseParams, { check }), name, uuid, 'presence') 146 await checkNewVideoFromSubscription({ ...baseParams, ...check }, name, uuid, 'presence')
148 } 147 }
149 }) 148 })
150 149
@@ -166,12 +165,12 @@ describe('Test notifications API', function () {
166 165
167 { 166 {
168 const check = { mail: false, web: true } 167 const check = { mail: false, web: true }
169 await checkNewVideoFromSubscription(immutableAssign(baseParams, { check }), name, uuid, 'absence') 168 await checkNewVideoFromSubscription({ ...baseParams, ...check }, name, uuid, 'absence')
170 } 169 }
171 170
172 { 171 {
173 const check = { mail: true, web: false } 172 const check = { mail: true, web: false }
174 await checkNewVideoFromSubscription(immutableAssign(baseParams, { check }), name, uuid, 'presence') 173 await checkNewVideoFromSubscription({ ...baseParams, ...check }, name, uuid, 'presence')
175 } 174 }
176 }) 175 })
177 176