mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2025-01-22 23:28:16 +00:00
tests: hlsdemux: Fix live startup sequence and seek range
To satisfy follwing restriction of HLS spec 6.3.3, select startup fragment sequence to 4th from end of playlist. Also, seek range should exclude last three fragment in playlist. "the client SHOULD NOT choose a segment which starts less than three target durations from the end of the Playlist file." https://bugzilla.gnome.org/show_bug.cgi?id=777682
This commit is contained in:
parent
b5cf96fc35
commit
d59571e80e
1 changed files with 3 additions and 3 deletions
|
@ -517,7 +517,7 @@ GST_START_TEST (test_live_playlist)
|
|||
pl = master->default_variant->m3u8;
|
||||
/* Check that we are live */
|
||||
assert_equals_int (gst_m3u8_is_live (pl), TRUE);
|
||||
assert_equals_int (pl->sequence, 2681);
|
||||
assert_equals_int (pl->sequence, 2680);
|
||||
/* Check number of entries */
|
||||
assert_equals_int (g_list_length (pl->files), 4);
|
||||
/* Check first media segments */
|
||||
|
@ -532,7 +532,7 @@ GST_START_TEST (test_live_playlist)
|
|||
assert_equals_int (file->sequence, 2683);
|
||||
fail_unless (gst_m3u8_get_seek_range (pl, &start, &stop));
|
||||
assert_equals_int64 (start, 0);
|
||||
assert_equals_float (stop / (double) GST_SECOND, 16.0);
|
||||
assert_equals_float (stop / (double) GST_SECOND, 8.0);
|
||||
|
||||
gst_hls_master_playlist_unref (master);
|
||||
}
|
||||
|
@ -552,7 +552,7 @@ GST_START_TEST (test_live_playlist_rotated)
|
|||
master = load_playlist (LIVE_PLAYLIST);
|
||||
pl = master->default_variant->m3u8;
|
||||
|
||||
assert_equals_int (pl->sequence, 2681);
|
||||
assert_equals_int (pl->sequence, 2680);
|
||||
/* Check first media segments */
|
||||
file = GST_M3U8_MEDIA_FILE (g_list_first (pl->files)->data);
|
||||
assert_equals_int (file->sequence, 2680);
|
||||
|
|
Loading…
Reference in a new issue