Skip to content

Commit

Permalink
improve(e2e): rename e2e test
Browse files Browse the repository at this point in the history
  • Loading branch information
a-wing committed Oct 25, 2024
1 parent c93d52a commit b71b403
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions cluster.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -103,7 +103,7 @@ async function hasSubscribeStreams(server: string): Promise<boolean> {
return (await getStreams(server))[0]?.subscribe.sessions.length > 0
}

async function reforward(server: string, streamId: string, url: string) {
async function cascade(server: string, streamId: string, url: string) {
return fetch(`${server}/api/cascade/${streamId}`, {
method: "POST",
headers: {
Expand Down Expand Up @@ -253,7 +253,7 @@ each_stream_max_sub = 1
cascade_push_close_sub = true
`
const fileContentMan = `
[reforward]
[cascade]
close_other_sub = true
[[nodes]]
Expand Down Expand Up @@ -291,7 +291,7 @@ url = "http://${localhost}:${live777CloudPort}"
await until(() => getStreams(live777LivemanHost), s => s.length === 0)
})

test("reforward", { timeout: 60 * 1000 }, async () => {
test("cascade", { timeout: 60 * 1000 }, async () => {
const width = 320, height = 240
const whipintoPort = "5002"
using _ffmpeg = spawn([
Expand All @@ -316,8 +316,8 @@ url = "http://${localhost}:${live777CloudPort}"

await until(() => hasPublishStreams(live777VergeHost))

const resReforward = await reforward(`http://127.0.0.1:${live777VergePort}`, live777VergeStream, `${live777CloudHost}/whip/${live777CloudStream}`)
assert(resReforward.ok)
const resCascade = await cascade(`http://127.0.0.1:${live777VergePort}`, live777VergeStream, `${live777CloudHost}/whip/${live777CloudStream}`)
assert(resCascade.ok)

await until(() => hasPublishStreams(live777CloudHost))

Expand Down

0 comments on commit b71b403

Please sign in to comment.