aboutsummaryrefslogtreecommitdiffhomepage
path: root/server/tests/api/search
diff options
context:
space:
mode:
Diffstat (limited to 'server/tests/api/search')
-rw-r--r--server/tests/api/search/search-activitypub-video-channels.ts10
-rw-r--r--server/tests/api/search/search-index.ts2
2 files changed, 6 insertions, 6 deletions
diff --git a/server/tests/api/search/search-activitypub-video-channels.ts b/server/tests/api/search/search-activitypub-video-channels.ts
index 8173c8b60..003bd34d0 100644
--- a/server/tests/api/search/search-activitypub-video-channels.ts
+++ b/server/tests/api/search/search-activitypub-video-channels.ts
@@ -87,7 +87,7 @@ describe('Test ActivityPub video channels search', function () {
87 it('Should search a local video channel', async function () { 87 it('Should search a local video channel', async function () {
88 const searches = [ 88 const searches = [
89 servers[0].url + '/video-channels/channel1_server1', 89 servers[0].url + '/video-channels/channel1_server1',
90 'channel1_server1@localhost:' + servers[0].port 90 'channel1_server1@' + servers[0].host
91 ] 91 ]
92 92
93 for (const search of searches) { 93 for (const search of searches) {
@@ -139,7 +139,7 @@ describe('Test ActivityPub video channels search', function () {
139 servers[1].url + '/video-channels/channel1_server2', 139 servers[1].url + '/video-channels/channel1_server2',
140 servers[1].url + '/c/channel1_server2', 140 servers[1].url + '/c/channel1_server2',
141 servers[1].url + '/c/channel1_server2/videos', 141 servers[1].url + '/c/channel1_server2/videos',
142 'channel1_server2@localhost:' + servers[1].port 142 'channel1_server2@' + servers[1].host
143 ] 143 ]
144 144
145 for (const search of searches) { 145 for (const search of searches) {
@@ -169,7 +169,7 @@ describe('Test ActivityPub video channels search', function () {
169 169
170 const { total, data } = await servers[0].videos.listByChannel({ 170 const { total, data } = await servers[0].videos.listByChannel({
171 token: null, 171 token: null,
172 handle: 'channel1_server2@localhost:' + servers[1].port 172 handle: 'channel1_server2@' + servers[1].host
173 }) 173 })
174 expect(total).to.equal(0) 174 expect(total).to.equal(0)
175 expect(data).to.have.lengthOf(0) 175 expect(data).to.have.lengthOf(0)
@@ -177,7 +177,7 @@ describe('Test ActivityPub video channels search', function () {
177 177
178 it('Should list video channel videos of server 2 with token', async function () { 178 it('Should list video channel videos of server 2 with token', async function () {
179 const { total, data } = await servers[0].videos.listByChannel({ 179 const { total, data } = await servers[0].videos.listByChannel({
180 handle: 'channel1_server2@localhost:' + servers[1].port 180 handle: 'channel1_server2@' + servers[1].host
181 }) 181 })
182 182
183 expect(total).to.equal(1) 183 expect(total).to.equal(1)
@@ -226,7 +226,7 @@ describe('Test ActivityPub video channels search', function () {
226 226
227 await waitJobs(servers) 227 await waitJobs(servers)
228 228
229 const handle = 'channel1_server2@localhost:' + servers[1].port 229 const handle = 'channel1_server2@' + servers[1].host
230 const { total, data } = await servers[0].videos.listByChannel({ handle, sort: '-createdAt' }) 230 const { total, data } = await servers[0].videos.listByChannel({ handle, sort: '-createdAt' })
231 231
232 expect(total).to.equal(2) 232 expect(total).to.equal(2)
diff --git a/server/tests/api/search/search-index.ts b/server/tests/api/search/search-index.ts
index eae4391ec..c8be762d2 100644
--- a/server/tests/api/search/search-index.ts
+++ b/server/tests/api/search/search-index.ts
@@ -57,7 +57,7 @@ describe('Test index search', function () {
57 57
58 expect(body.total).to.equal(1) 58 expect(body.total).to.equal(1)
59 expect(body.data[0].name).to.equal('root_channel') 59 expect(body.data[0].name).to.equal('root_channel')
60 expect(body.data[0].host).to.equal('localhost:' + server.port) 60 expect(body.data[0].host).to.equal(server.host)
61 }) 61 })
62 62
63 it('Should make an index videos search by default', async function () { 63 it('Should make an index videos search by default', async function () {