Skip to content

Commit

Permalink
Omit VOD "ended" event tests with overlapping appends from Safari
Browse files Browse the repository at this point in the history
  • Loading branch information
robwalch committed Jan 11, 2024
1 parent 2dea295 commit 30f8d93
Showing 1 changed file with 14 additions and 9 deletions.
23 changes: 14 additions & 9 deletions tests/functional/auto/setup.js
Original file line number Diff line number Diff line change
Expand Up @@ -616,13 +616,21 @@ describe(`testing hls.js playback in the browser on "${browserDescription}"`, fu
entries.length = 10;
}

const isSafari = browserConfig.name === 'safari';

entries
// eslint-disable-next-line no-unused-vars
.filter(([name, stream]) => !stream.skipFunctionalTests)
// eslint-disable-next-line no-unused-vars
.forEach(([name, stream]) => {
const url = stream.url;
const config = stream.config || {};

// Segment media is shorted than playlist duration resulting in overlapping appends on switch
// This appears to prevent playback in Safari which causes smoothswitch and VOD ended event tests to fail
const isStreamsWithOverlappingAppends =
name === 'arte' || name === 'oceansAES';

config.preferManagedMediaSource = false;
if (
stream.skip_ua &&
Expand Down Expand Up @@ -650,11 +658,6 @@ describe(`testing hls.js playback in the browser on "${browserDescription}"`, fu
);
}

// Segment media is shorted than playlist duration resulting in overlapping appends on switch
// This appears to prevent playback in Safari which causes smoothswitch tests to fail
const isSafari = browserConfig.name === 'safari';
const isStreamsWithOverlappingAppends =
name === 'arte' || name === 'oceansAES';
if (
stream.abr &&
!HlsjsLightBuild &&
Expand All @@ -680,10 +683,12 @@ describe(`testing hls.js playback in the browser on "${browserDescription}"`, fu
`should play ${stream.description}`,
testIsPlayingVOD.bind(null, url, config)
);
it(
`should seek 3s from end and receive video ended event for ${stream.description} with 2 or less buffered ranges`,
testSeekOnVOD.bind(null, url, config)
);
if (!isSafari || !isStreamsWithOverlappingAppends) {
it(
`should seek 3s from end and receive video ended event for ${stream.description} with 2 or less buffered ranges`,
testSeekOnVOD.bind(null, url, config)
);
}
// TODO: Seeking to or past VOD duration should result in the video ending
// it(`should seek on end and receive video ended event for ${stream.description}`, testSeekEndVOD.bind(null, url));
}
Expand Down

0 comments on commit 30f8d93

Please sign in to comment.