aboutsummaryrefslogtreecommitdiffhomepage
path: root/server/tests/api/activitypub/refresher.ts
diff options
context:
space:
mode:
Diffstat (limited to 'server/tests/api/activitypub/refresher.ts')
-rw-r--r--server/tests/api/activitypub/refresher.ts15
1 files changed, 8 insertions, 7 deletions
diff --git a/server/tests/api/activitypub/refresher.ts b/server/tests/api/activitypub/refresher.ts
index 232c5d823..c717f1a30 100644
--- a/server/tests/api/activitypub/refresher.ts
+++ b/server/tests/api/activitypub/refresher.ts
@@ -24,6 +24,7 @@ import {
24} from '../../../../shared/extra-utils' 24} from '../../../../shared/extra-utils'
25import { getAccount } from '../../../../shared/extra-utils/users/accounts' 25import { getAccount } from '../../../../shared/extra-utils/users/accounts'
26import { VideoPlaylistPrivacy } from '../../../../shared/models/videos' 26import { VideoPlaylistPrivacy } from '../../../../shared/models/videos'
27import { HttpStatusCode } from '../../../../shared/core-utils/miscs/http-error-codes'
27 28
28describe('Test AP refresher', function () { 29describe('Test AP refresher', function () {
29 let servers: ServerInfo[] = [] 30 let servers: ServerInfo[] = []
@@ -86,8 +87,8 @@ describe('Test AP refresher', function () {
86 87
87 await waitJobs(servers) 88 await waitJobs(servers)
88 89
89 await getVideo(servers[0].url, videoUUID1, 404) 90 await getVideo(servers[0].url, videoUUID1, HttpStatusCode.NOT_FOUND_404)
90 await getVideo(servers[0].url, videoUUID2, 200) 91 await getVideo(servers[0].url, videoUUID2, HttpStatusCode.OK_200)
91 }) 92 })
92 93
93 it('Should not update a remote video if the remote instance is down', async function () { 94 it('Should not update a remote video if the remote instance is down', async function () {
@@ -106,7 +107,7 @@ describe('Test AP refresher', function () {
106 107
107 await reRunServer(servers[1]) 108 await reRunServer(servers[1])
108 109
109 await getVideo(servers[0].url, videoUUID3, 200) 110 await getVideo(servers[0].url, videoUUID3, HttpStatusCode.OK_200)
110 }) 111 })
111 }) 112 })
112 113
@@ -126,8 +127,8 @@ describe('Test AP refresher', function () {
126 127
127 await waitJobs(servers) 128 await waitJobs(servers)
128 129
129 await getAccount(servers[0].url, 'user1@localhost:' + servers[1].port, 200) 130 await getAccount(servers[0].url, 'user1@localhost:' + servers[1].port, HttpStatusCode.OK_200)
130 await getAccount(servers[0].url, 'user2@localhost:' + servers[1].port, 404) 131 await getAccount(servers[0].url, 'user2@localhost:' + servers[1].port, HttpStatusCode.NOT_FOUND_404)
131 }) 132 })
132 }) 133 })
133 134
@@ -146,8 +147,8 @@ describe('Test AP refresher', function () {
146 147
147 await waitJobs(servers) 148 await waitJobs(servers)
148 149
149 await getVideoPlaylist(servers[0].url, playlistUUID1, 200) 150 await getVideoPlaylist(servers[0].url, playlistUUID1, HttpStatusCode.OK_200)
150 await getVideoPlaylist(servers[0].url, playlistUUID2, 404) 151 await getVideoPlaylist(servers[0].url, playlistUUID2, HttpStatusCode.NOT_FOUND_404)
151 }) 152 })
152 }) 153 })
153 154