aboutsummaryrefslogtreecommitdiffhomepage
path: root/server/tests/shared
diff options
context:
space:
mode:
Diffstat (limited to 'server/tests/shared')
-rw-r--r--server/tests/shared/live.ts6
-rw-r--r--server/tests/shared/mock-servers/mock-object-storage.ts2
2 files changed, 4 insertions, 4 deletions
diff --git a/server/tests/shared/live.ts b/server/tests/shared/live.ts
index da3691711..78e29f575 100644
--- a/server/tests/shared/live.ts
+++ b/server/tests/shared/live.ts
@@ -50,7 +50,7 @@ async function testVideoResolutions (options: {
50 }) 50 })
51 51
52 if (objectStorage) { 52 if (objectStorage) {
53 expect(hlsPlaylist.playlistUrl).to.contain(ObjectStorageCommand.getPlaylistBaseUrl()) 53 expect(hlsPlaylist.playlistUrl).to.contain(ObjectStorageCommand.getMockPlaylistBaseUrl())
54 } 54 }
55 55
56 for (let i = 0; i < resolutions.length; i++) { 56 for (let i = 0; i < resolutions.length; i++) {
@@ -65,11 +65,11 @@ async function testVideoResolutions (options: {
65 }) 65 })
66 66
67 const baseUrl = objectStorage 67 const baseUrl = objectStorage
68 ? ObjectStorageCommand.getPlaylistBaseUrl() + 'hls' 68 ? ObjectStorageCommand.getMockPlaylistBaseUrl() + 'hls'
69 : originServer.url + '/static/streaming-playlists/hls' 69 : originServer.url + '/static/streaming-playlists/hls'
70 70
71 if (objectStorage) { 71 if (objectStorage) {
72 expect(hlsPlaylist.segmentsSha256Url).to.contain(ObjectStorageCommand.getPlaylistBaseUrl()) 72 expect(hlsPlaylist.segmentsSha256Url).to.contain(ObjectStorageCommand.getMockPlaylistBaseUrl())
73 } 73 }
74 74
75 const subPlaylist = await originServer.streamingPlaylists.get({ 75 const subPlaylist = await originServer.streamingPlaylists.get({
diff --git a/server/tests/shared/mock-servers/mock-object-storage.ts b/server/tests/shared/mock-servers/mock-object-storage.ts
index 99d68e014..8c325bf11 100644
--- a/server/tests/shared/mock-servers/mock-object-storage.ts
+++ b/server/tests/shared/mock-servers/mock-object-storage.ts
@@ -12,7 +12,7 @@ export class MockObjectStorage {
12 const app = express() 12 const app = express()
13 13
14 app.get('/:bucketName/:path(*)', (req: express.Request, res: express.Response, next: express.NextFunction) => { 14 app.get('/:bucketName/:path(*)', (req: express.Request, res: express.Response, next: express.NextFunction) => {
15 const url = `http://${req.params.bucketName}.${ObjectStorageCommand.getEndpointHost()}/${req.params.path}` 15 const url = `http://${req.params.bucketName}.${ObjectStorageCommand.getMockEndpointHost()}/${req.params.path}`
16 16
17 if (process.env.DEBUG) { 17 if (process.env.DEBUG) {
18 console.log('Receiving request on mocked server %s.', req.url) 18 console.log('Receiving request on mocked server %s.', req.url)