aboutsummaryrefslogtreecommitdiffhomepage
path: root/server/tests/api/redundancy/redundancy.ts
diff options
context:
space:
mode:
authorChocobozzz <me@florianbigard.com>2022-12-09 11:14:47 +0100
committerChocobozzz <me@florianbigard.com>2022-12-12 13:36:23 +0100
commit2732eeff9e6994582293b5aaa0cb158b7e272e9e (patch)
tree417d30cf470cd1db84e06c5dbd1b5429d4b99bc1 /server/tests/api/redundancy/redundancy.ts
parentc7c5f8d0f17b0ab598fbe237f11639c6de28110c (diff)
downloadPeerTube-2732eeff9e6994582293b5aaa0cb158b7e272e9e.tar.gz
PeerTube-2732eeff9e6994582293b5aaa0cb158b7e272e9e.tar.zst
PeerTube-2732eeff9e6994582293b5aaa0cb158b7e272e9e.zip
Fix CI using 127.0.0.1 for tests
Diffstat (limited to 'server/tests/api/redundancy/redundancy.ts')
-rw-r--r--server/tests/api/redundancy/redundancy.ts10
1 files changed, 5 insertions, 5 deletions
diff --git a/server/tests/api/redundancy/redundancy.ts b/server/tests/api/redundancy/redundancy.ts
index fb2e6e91c..57939775e 100644
--- a/server/tests/api/redundancy/redundancy.ts
+++ b/server/tests/api/redundancy/redundancy.ts
@@ -265,8 +265,8 @@ async function checkStatsWithoutRedundancy (strategy: VideoRedundancyStrategyWit
265async function findServerFollows () { 265async function findServerFollows () {
266 const body = await servers[0].follows.getFollowings({ start: 0, count: 5, sort: '-createdAt' }) 266 const body = await servers[0].follows.getFollowings({ start: 0, count: 5, sort: '-createdAt' })
267 const follows = body.data 267 const follows = body.data
268 const server2 = follows.find(f => f.following.host === `localhost:${servers[1].port}`) 268 const server2 = follows.find(f => f.following.host === `${servers[1].host}`)
269 const server3 = follows.find(f => f.following.host === `localhost:${servers[2].port}`) 269 const server3 = follows.find(f => f.following.host === `${servers[2].host}`)
270 270
271 return { server2, server3 } 271 return { server2, server3 }
272} 272}
@@ -639,12 +639,12 @@ describe('Test videos redundancy', function () {
639 await wait(10000) 639 await wait(10000)
640 640
641 try { 641 try {
642 await checkContains(servers, 'http%3A%2F%2Flocalhost%3A' + servers[0].port) 642 await checkContains(servers, 'http%3A%2F%2F' + servers[0].hostname + '%3A' + servers[0].port)
643 } catch { 643 } catch {
644 // Maybe a server deleted a redundancy in the scheduler 644 // Maybe a server deleted a redundancy in the scheduler
645 await wait(2000) 645 await wait(2000)
646 646
647 await checkContains(servers, 'http%3A%2F%2Flocalhost%3A' + servers[0].port) 647 await checkContains(servers, 'http%3A%2F%2F' + servers[0].hostname + '%3A' + servers[0].port)
648 } 648 }
649 }) 649 })
650 650
@@ -655,7 +655,7 @@ describe('Test videos redundancy', function () {
655 655
656 await wait(15000) 656 await wait(15000)
657 657
658 await checkNotContains([ servers[1], servers[2] ], 'http%3A%2F%2Flocalhost%3A' + servers[0].port) 658 await checkNotContains([ servers[1], servers[2] ], 'http%3A%2F%2F' + servers[0].port + '%3A' + servers[0].port)
659 }) 659 })
660 660
661 after(async function () { 661 after(async function () {