aboutsummaryrefslogtreecommitdiffhomepage
path: root/server/tests/api/notifications/admin-notifications.ts
diff options
context:
space:
mode:
authorChocobozzz <me@florianbigard.com>2021-07-27 09:07:38 +0200
committerChocobozzz <me@florianbigard.com>2021-07-27 17:10:52 +0200
commit29837f8885eb37fa300e4b80c90a6d03ab337084 (patch)
treea7a066c6604c9adec4cb21c1bd1965c5bf253b03 /server/tests/api/notifications/admin-notifications.ts
parent5d0095fde19d803bead7cbad0452bd09f3351adc (diff)
downloadPeerTube-29837f8885eb37fa300e4b80c90a6d03ab337084.tar.gz
PeerTube-29837f8885eb37fa300e4b80c90a6d03ab337084.tar.zst
PeerTube-29837f8885eb37fa300e4b80c90a6d03ab337084.zip
Add ability to search by host in server
Diffstat (limited to 'server/tests/api/notifications/admin-notifications.ts')
-rw-r--r--server/tests/api/notifications/admin-notifications.ts10
1 files changed, 5 insertions, 5 deletions
diff --git a/server/tests/api/notifications/admin-notifications.ts b/server/tests/api/notifications/admin-notifications.ts
index b36ba11a9..c00d4e257 100644
--- a/server/tests/api/notifications/admin-notifications.ts
+++ b/server/tests/api/notifications/admin-notifications.ts
@@ -70,7 +70,7 @@ describe('Test admin notifications', function () {
70 joinPeerTubeServer.setLatestVersion('1.4.2') 70 joinPeerTubeServer.setLatestVersion('1.4.2')
71 71
72 await wait(3000) 72 await wait(3000)
73 await checkNewPeerTubeVersion(baseParams, '1.4.2', 'absence') 73 await checkNewPeerTubeVersion({ ...baseParams, latestVersion: '1.4.2', checkType: 'absence' })
74 }) 74 })
75 75
76 it('Should send a notification to admins on new plugin version', async function () { 76 it('Should send a notification to admins on new plugin version', async function () {
@@ -79,7 +79,7 @@ describe('Test admin notifications', function () {
79 joinPeerTubeServer.setLatestVersion('15.4.2') 79 joinPeerTubeServer.setLatestVersion('15.4.2')
80 80
81 await wait(3000) 81 await wait(3000)
82 await checkNewPeerTubeVersion(baseParams, '15.4.2', 'presence') 82 await checkNewPeerTubeVersion({ ...baseParams, latestVersion: '15.4.2', checkType: 'presence' })
83 }) 83 })
84 84
85 it('Should not send the same notification to admins', async function () { 85 it('Should not send the same notification to admins', async function () {
@@ -101,7 +101,7 @@ describe('Test admin notifications', function () {
101 joinPeerTubeServer.setLatestVersion('15.4.3') 101 joinPeerTubeServer.setLatestVersion('15.4.3')
102 102
103 await wait(3000) 103 await wait(3000)
104 await checkNewPeerTubeVersion(baseParams, '15.4.3', 'presence') 104 await checkNewPeerTubeVersion({ ...baseParams, latestVersion: '15.4.3', checkType: 'presence' })
105 expect(adminNotifications.filter(n => n.type === UserNotificationType.NEW_PEERTUBE_VERSION)).to.have.lengthOf(2) 105 expect(adminNotifications.filter(n => n.type === UserNotificationType.NEW_PEERTUBE_VERSION)).to.have.lengthOf(2)
106 }) 106 })
107 }) 107 })
@@ -112,7 +112,7 @@ describe('Test admin notifications', function () {
112 this.timeout(30000) 112 this.timeout(30000)
113 113
114 await wait(6000) 114 await wait(6000)
115 await checkNewPluginVersion(baseParams, PluginType.PLUGIN, 'hello-world', 'absence') 115 await checkNewPluginVersion({ ...baseParams, pluginType: PluginType.PLUGIN, pluginName: 'hello-world', checkType: 'absence' })
116 }) 116 })
117 117
118 it('Should send a notification to admins on new plugin version', async function () { 118 it('Should send a notification to admins on new plugin version', async function () {
@@ -122,7 +122,7 @@ describe('Test admin notifications', function () {
122 await server.sql.setPluginLatestVersion('hello-world', '0.0.1') 122 await server.sql.setPluginLatestVersion('hello-world', '0.0.1')
123 await wait(6000) 123 await wait(6000)
124 124
125 await checkNewPluginVersion(baseParams, PluginType.PLUGIN, 'hello-world', 'presence') 125 await checkNewPluginVersion({ ...baseParams, pluginType: PluginType.PLUGIN, pluginName: 'hello-world', checkType: 'presence' })
126 }) 126 })
127 127
128 it('Should not send the same notification to admins', async function () { 128 it('Should not send the same notification to admins', async function () {