diff --git a/karma.conf.js b/karma.conf.js index 5db40c6cf75..50c9da8d88e 100644 --- a/karma.conf.js +++ b/karma.conf.js @@ -237,6 +237,13 @@ module.exports = (config) => { {pattern: 'test/**/*.js', included: false}, {pattern: 'test/test/assets/*', included: false}, {pattern: 'test/test/assets/3675/*', included: false}, + {pattern: 'test/test/assets/hls-raw-aac/*', included: false}, + {pattern: 'test/test/assets/hls-raw-ac3/*', included: false}, + {pattern: 'test/test/assets/hls-raw-ec3/*', included: false}, + {pattern: 'test/test/assets/hls-raw-mp3/*', included: false}, + {pattern: 'test/test/assets/hls-ts-aac/*', included: false}, + {pattern: 'test/test/assets/hls-ts-h264/*', included: false}, + {pattern: 'test/test/assets/hls-ts-muxed-aac-h264/*', included: false}, {pattern: 'dist/shaka-player.ui.js', included: false}, {pattern: 'dist/locales.js', included: false}, {pattern: 'demo/**/*.js', included: false}, diff --git a/test/test/assets/hls-raw-aac/fileSequence0.aac b/test/test/assets/hls-raw-aac/fileSequence0.aac new file mode 100644 index 00000000000..220a47823b0 Binary files /dev/null and b/test/test/assets/hls-raw-aac/fileSequence0.aac differ diff --git a/test/test/assets/hls-raw-aac/fileSequence1.aac b/test/test/assets/hls-raw-aac/fileSequence1.aac new file mode 100644 index 00000000000..25a5739d35f Binary files /dev/null and b/test/test/assets/hls-raw-aac/fileSequence1.aac differ diff --git a/test/test/assets/hls-raw-aac/fileSequence2.aac b/test/test/assets/hls-raw-aac/fileSequence2.aac new file mode 100644 index 00000000000..db4173420f9 Binary files /dev/null and b/test/test/assets/hls-raw-aac/fileSequence2.aac differ diff --git a/test/test/assets/hls-raw-aac/fileSequence3.aac b/test/test/assets/hls-raw-aac/fileSequence3.aac new file mode 100644 index 00000000000..4097eae9ee5 Binary files /dev/null and b/test/test/assets/hls-raw-aac/fileSequence3.aac differ diff --git a/test/test/assets/hls-raw-aac/manifest.m3u8 b/test/test/assets/hls-raw-aac/manifest.m3u8 new file mode 100644 index 00000000000..74efc9e2ea7 --- /dev/null +++ b/test/test/assets/hls-raw-aac/manifest.m3u8 @@ -0,0 +1,4 @@ +#EXTM3U + +#EXT-X-STREAM-INF:PROGRAM-ID=1,BANDWIDTH=41457,CODECS="mp4a.40.2" +stream.m4a.m3u8 diff --git a/test/test/assets/hls-raw-aac/stream.m4a.m3u8 b/test/test/assets/hls-raw-aac/stream.m4a.m3u8 new file mode 100644 index 00000000000..114cefba9c6 --- /dev/null +++ b/test/test/assets/hls-raw-aac/stream.m4a.m3u8 @@ -0,0 +1,14 @@ +#EXTM3U +#EXT-X-TARGETDURATION:11 +#EXT-X-VERSION:3 +#EXT-X-MEDIA-SEQUENCE:0 +#EXT-X-PLAYLIST-TYPE:VOD +#EXTINF:9.98458, +fileSequence0.aac +#EXTINF:9.98458, +fileSequence1.aac +#EXTINF:9.98459, +fileSequence2.aac +#EXTINF:10.03102, +fileSequence3.aac +#EXT-X-ENDLIST diff --git a/test/test/assets/hls-raw-ac3/fileSequence0.ac3 b/test/test/assets/hls-raw-ac3/fileSequence0.ac3 new file mode 100644 index 00000000000..a84fdbe8ed2 Binary files /dev/null and b/test/test/assets/hls-raw-ac3/fileSequence0.ac3 differ diff --git a/test/test/assets/hls-raw-ac3/fileSequence1.ac3 b/test/test/assets/hls-raw-ac3/fileSequence1.ac3 new file mode 100644 index 00000000000..b305cb0d0e2 Binary files /dev/null and b/test/test/assets/hls-raw-ac3/fileSequence1.ac3 differ diff --git a/test/test/assets/hls-raw-ac3/fileSequence2.ac3 b/test/test/assets/hls-raw-ac3/fileSequence2.ac3 new file mode 100644 index 00000000000..d53b979a8ea Binary files /dev/null and b/test/test/assets/hls-raw-ac3/fileSequence2.ac3 differ diff --git a/test/test/assets/hls-raw-ac3/fileSequence3.ac3 b/test/test/assets/hls-raw-ac3/fileSequence3.ac3 new file mode 100644 index 00000000000..6ebb7632ae3 Binary files /dev/null and b/test/test/assets/hls-raw-ac3/fileSequence3.ac3 differ diff --git a/test/test/assets/hls-raw-ac3/fileSequence4.ac3 b/test/test/assets/hls-raw-ac3/fileSequence4.ac3 new file mode 100644 index 00000000000..547f4d37cb8 Binary files /dev/null and b/test/test/assets/hls-raw-ac3/fileSequence4.ac3 differ diff --git a/test/test/assets/hls-raw-ac3/fileSequence5.ac3 b/test/test/assets/hls-raw-ac3/fileSequence5.ac3 new file mode 100644 index 00000000000..79bd9b8f153 Binary files /dev/null and b/test/test/assets/hls-raw-ac3/fileSequence5.ac3 differ diff --git a/test/test/assets/hls-raw-ac3/fileSequence6.ac3 b/test/test/assets/hls-raw-ac3/fileSequence6.ac3 new file mode 100644 index 00000000000..3ac183499f6 Binary files /dev/null and b/test/test/assets/hls-raw-ac3/fileSequence6.ac3 differ diff --git a/test/test/assets/hls-raw-ac3/fileSequence7.ac3 b/test/test/assets/hls-raw-ac3/fileSequence7.ac3 new file mode 100644 index 00000000000..f70b708a301 Binary files /dev/null and b/test/test/assets/hls-raw-ac3/fileSequence7.ac3 differ diff --git a/test/test/assets/hls-raw-ac3/prog_index.m3u8 b/test/test/assets/hls-raw-ac3/prog_index.m3u8 new file mode 100644 index 00000000000..91174626f5c --- /dev/null +++ b/test/test/assets/hls-raw-ac3/prog_index.m3u8 @@ -0,0 +1,31 @@ +#EXTM3U +#EXT-X-TARGETDURATION:6 +#EXT-X-VERSION:3 +#EXT-X-MEDIA-SEQUENCE:0 +#EXT-X-PLAYLIST-TYPE:VOD +#EXT-X-INDEPENDENT-SEGMENTS +#EXTINF:5.98400, +#EXT-X-BITRATE:384 +fileSequence0.ac3 +#EXTINF:5.98400, +#EXT-X-BITRATE:384 +fileSequence1.ac3 +#EXTINF:5.98400, +#EXT-X-BITRATE:384 +fileSequence2.ac3 +#EXTINF:5.98400, +#EXT-X-BITRATE:384 +fileSequence3.ac3 +#EXTINF:5.98400, +#EXT-X-BITRATE:384 +fileSequence4.ac3 +#EXTINF:5.98400, +#EXT-X-BITRATE:384 +fileSequence5.ac3 +#EXTINF:5.98400, +#EXT-X-BITRATE:384 +fileSequence6.ac3 +#EXTINF:5.98400, +#EXT-X-BITRATE:384 +fileSequence7.ac3 +#EXT-X-ENDLIST diff --git a/test/test/assets/hls-raw-ec3/fileSequence0.ec3 b/test/test/assets/hls-raw-ec3/fileSequence0.ec3 new file mode 100644 index 00000000000..745a2f9ab9d Binary files /dev/null and b/test/test/assets/hls-raw-ec3/fileSequence0.ec3 differ diff --git a/test/test/assets/hls-raw-ec3/fileSequence1.ec3 b/test/test/assets/hls-raw-ec3/fileSequence1.ec3 new file mode 100644 index 00000000000..4411d49eb76 Binary files /dev/null and b/test/test/assets/hls-raw-ec3/fileSequence1.ec3 differ diff --git a/test/test/assets/hls-raw-ec3/fileSequence2.ec3 b/test/test/assets/hls-raw-ec3/fileSequence2.ec3 new file mode 100644 index 00000000000..5832d7c5e03 Binary files /dev/null and b/test/test/assets/hls-raw-ec3/fileSequence2.ec3 differ diff --git a/test/test/assets/hls-raw-ec3/fileSequence3.ec3 b/test/test/assets/hls-raw-ec3/fileSequence3.ec3 new file mode 100644 index 00000000000..4d6c4a9b916 Binary files /dev/null and b/test/test/assets/hls-raw-ec3/fileSequence3.ec3 differ diff --git a/test/test/assets/hls-raw-ec3/fileSequence4.ec3 b/test/test/assets/hls-raw-ec3/fileSequence4.ec3 new file mode 100644 index 00000000000..e5ea0e04aa6 Binary files /dev/null and b/test/test/assets/hls-raw-ec3/fileSequence4.ec3 differ diff --git a/test/test/assets/hls-raw-ec3/fileSequence5.ec3 b/test/test/assets/hls-raw-ec3/fileSequence5.ec3 new file mode 100644 index 00000000000..7f26e5fd5be Binary files /dev/null and b/test/test/assets/hls-raw-ec3/fileSequence5.ec3 differ diff --git a/test/test/assets/hls-raw-ec3/fileSequence6.ec3 b/test/test/assets/hls-raw-ec3/fileSequence6.ec3 new file mode 100644 index 00000000000..0941b13b1dd Binary files /dev/null and b/test/test/assets/hls-raw-ec3/fileSequence6.ec3 differ diff --git a/test/test/assets/hls-raw-ec3/fileSequence7.ec3 b/test/test/assets/hls-raw-ec3/fileSequence7.ec3 new file mode 100644 index 00000000000..2e14cc413ca Binary files /dev/null and b/test/test/assets/hls-raw-ec3/fileSequence7.ec3 differ diff --git a/test/test/assets/hls-raw-ec3/prog_index.m3u8 b/test/test/assets/hls-raw-ec3/prog_index.m3u8 new file mode 100644 index 00000000000..bcdb96ac0da --- /dev/null +++ b/test/test/assets/hls-raw-ec3/prog_index.m3u8 @@ -0,0 +1,31 @@ +#EXTM3U +#EXT-X-TARGETDURATION:6 +#EXT-X-VERSION:3 +#EXT-X-MEDIA-SEQUENCE:0 +#EXT-X-PLAYLIST-TYPE:VOD +#EXT-X-INDEPENDENT-SEGMENTS +#EXTINF:5.98400, +#EXT-X-BITRATE:192 +fileSequence0.ec3 +#EXTINF:5.98400, +#EXT-X-BITRATE:192 +fileSequence1.ec3 +#EXTINF:5.98400, +#EXT-X-BITRATE:192 +fileSequence2.ec3 +#EXTINF:5.98400, +#EXT-X-BITRATE:192 +fileSequence3.ec3 +#EXTINF:5.98400, +#EXT-X-BITRATE:192 +fileSequence4.ec3 +#EXTINF:5.98400, +#EXT-X-BITRATE:192 +fileSequence5.ec3 +#EXTINF:5.98400, +#EXT-X-BITRATE:192 +fileSequence6.ec3 +#EXTINF:5.98400, +#EXT-X-BITRATE:192 +fileSequence7.ec3 +#EXT-X-ENDLIST diff --git a/test/test/assets/hls-raw-mp3/chunklist_w905519204.m3u8 b/test/test/assets/hls-raw-mp3/chunklist_w905519204.m3u8 new file mode 100644 index 00000000000..23c5981a3c5 --- /dev/null +++ b/test/test/assets/hls-raw-mp3/chunklist_w905519204.m3u8 @@ -0,0 +1,13 @@ +#EXTM3U +#EXT-X-VERSION:3 +#EXT-X-TARGETDURATION:10 +#EXT-X-MEDIA-SEQUENCE:0 +#EXTINF:10.0, +media_w905519204_0.mp3 +#EXTINF:10.0, +media_w905519204_1.mp3 +#EXTINF:10.0, +media_w905519204_2.mp3 +#EXTINF:10.0, +media_w905519204_3.mp3 +#EXT-X-ENDLIST diff --git a/test/test/assets/hls-raw-mp3/media_w905519204_0.mp3 b/test/test/assets/hls-raw-mp3/media_w905519204_0.mp3 new file mode 100644 index 00000000000..ed43e61d1e1 Binary files /dev/null and b/test/test/assets/hls-raw-mp3/media_w905519204_0.mp3 differ diff --git a/test/test/assets/hls-raw-mp3/media_w905519204_1.mp3 b/test/test/assets/hls-raw-mp3/media_w905519204_1.mp3 new file mode 100644 index 00000000000..a6fc3b858e6 Binary files /dev/null and b/test/test/assets/hls-raw-mp3/media_w905519204_1.mp3 differ diff --git a/test/test/assets/hls-raw-mp3/media_w905519204_2.mp3 b/test/test/assets/hls-raw-mp3/media_w905519204_2.mp3 new file mode 100644 index 00000000000..69db362994c Binary files /dev/null and b/test/test/assets/hls-raw-mp3/media_w905519204_2.mp3 differ diff --git a/test/test/assets/hls-raw-mp3/media_w905519204_3.mp3 b/test/test/assets/hls-raw-mp3/media_w905519204_3.mp3 new file mode 100644 index 00000000000..c177a979524 Binary files /dev/null and b/test/test/assets/hls-raw-mp3/media_w905519204_3.mp3 differ diff --git a/test/test/assets/hls-raw-mp3/playlist.m3u8 b/test/test/assets/hls-raw-mp3/playlist.m3u8 new file mode 100644 index 00000000000..c7de0791361 --- /dev/null +++ b/test/test/assets/hls-raw-mp3/playlist.m3u8 @@ -0,0 +1,4 @@ +#EXTM3U +#EXT-X-VERSION:3 +#EXT-X-STREAM-INF:BANDWIDTH=63701,CODECS="mp4a.40.34" +chunklist_w905519204.m3u8 diff --git a/test/test/assets/hls-ts-aac/playlist.m3u8 b/test/test/assets/hls-ts-aac/playlist.m3u8 new file mode 100644 index 00000000000..a5887908127 --- /dev/null +++ b/test/test/assets/hls-ts-aac/playlist.m3u8 @@ -0,0 +1,23 @@ +#EXTM3U + +#EXT-X-VERSION:3 +#EXT-X-MEDIA-SEQUENCE:0 +#EXT-X-TARGETDURATION:4 + +#EXTINF:3.989 +segment_0.ts +#EXTINF:3.989 +segment_1.ts +#EXTINF:3.989 +segment_2.ts +#EXTINF:3.989 +segment_3.ts +#EXTINF:3.989 +segment_4.ts +#EXTINF:3.989 +segment_5.ts +#EXTINF:3.989 +segment_6.ts +#EXTINF:3.989 +segment_7.ts +#EXT-X-ENDLIST \ No newline at end of file diff --git a/test/test/assets/hls-ts-aac/segment_0.ts b/test/test/assets/hls-ts-aac/segment_0.ts new file mode 100644 index 00000000000..3e713b6182c Binary files /dev/null and b/test/test/assets/hls-ts-aac/segment_0.ts differ diff --git a/test/test/assets/hls-ts-aac/segment_1.ts b/test/test/assets/hls-ts-aac/segment_1.ts new file mode 100644 index 00000000000..3dc97b5598d Binary files /dev/null and b/test/test/assets/hls-ts-aac/segment_1.ts differ diff --git a/test/test/assets/hls-ts-aac/segment_2.ts b/test/test/assets/hls-ts-aac/segment_2.ts new file mode 100644 index 00000000000..5f1254f4bd1 Binary files /dev/null and b/test/test/assets/hls-ts-aac/segment_2.ts differ diff --git a/test/test/assets/hls-ts-aac/segment_3.ts b/test/test/assets/hls-ts-aac/segment_3.ts new file mode 100644 index 00000000000..c9800f6d291 Binary files /dev/null and b/test/test/assets/hls-ts-aac/segment_3.ts differ diff --git a/test/test/assets/hls-ts-aac/segment_4.ts b/test/test/assets/hls-ts-aac/segment_4.ts new file mode 100644 index 00000000000..b5f027d85bf Binary files /dev/null and b/test/test/assets/hls-ts-aac/segment_4.ts differ diff --git a/test/test/assets/hls-ts-aac/segment_5.ts b/test/test/assets/hls-ts-aac/segment_5.ts new file mode 100644 index 00000000000..187193705dc Binary files /dev/null and b/test/test/assets/hls-ts-aac/segment_5.ts differ diff --git a/test/test/assets/hls-ts-aac/segment_6.ts b/test/test/assets/hls-ts-aac/segment_6.ts new file mode 100644 index 00000000000..ab2bd2d6c74 Binary files /dev/null and b/test/test/assets/hls-ts-aac/segment_6.ts differ diff --git a/test/test/assets/hls-ts-aac/segment_7.ts b/test/test/assets/hls-ts-aac/segment_7.ts new file mode 100644 index 00000000000..591eb287127 Binary files /dev/null and b/test/test/assets/hls-ts-aac/segment_7.ts differ diff --git a/test/test/assets/hls-ts-h264/fileSequence0.ts b/test/test/assets/hls-ts-h264/fileSequence0.ts new file mode 100644 index 00000000000..7f3487c01df Binary files /dev/null and b/test/test/assets/hls-ts-h264/fileSequence0.ts differ diff --git a/test/test/assets/hls-ts-h264/fileSequence1.ts b/test/test/assets/hls-ts-h264/fileSequence1.ts new file mode 100644 index 00000000000..01aec21158c Binary files /dev/null and b/test/test/assets/hls-ts-h264/fileSequence1.ts differ diff --git a/test/test/assets/hls-ts-h264/fileSequence2.ts b/test/test/assets/hls-ts-h264/fileSequence2.ts new file mode 100644 index 00000000000..a068814b78c Binary files /dev/null and b/test/test/assets/hls-ts-h264/fileSequence2.ts differ diff --git a/test/test/assets/hls-ts-h264/fileSequence3.ts b/test/test/assets/hls-ts-h264/fileSequence3.ts new file mode 100644 index 00000000000..fbcc4e5f9a5 Binary files /dev/null and b/test/test/assets/hls-ts-h264/fileSequence3.ts differ diff --git a/test/test/assets/hls-ts-h264/fileSequence4.ts b/test/test/assets/hls-ts-h264/fileSequence4.ts new file mode 100644 index 00000000000..2ae33539c09 Binary files /dev/null and b/test/test/assets/hls-ts-h264/fileSequence4.ts differ diff --git a/test/test/assets/hls-ts-h264/fileSequence5.ts b/test/test/assets/hls-ts-h264/fileSequence5.ts new file mode 100644 index 00000000000..cd6e2beaecf Binary files /dev/null and b/test/test/assets/hls-ts-h264/fileSequence5.ts differ diff --git a/test/test/assets/hls-ts-h264/prog_index.m3u8 b/test/test/assets/hls-ts-h264/prog_index.m3u8 new file mode 100644 index 00000000000..aa72c23da1b --- /dev/null +++ b/test/test/assets/hls-ts-h264/prog_index.m3u8 @@ -0,0 +1,25 @@ +#EXTM3U +#EXT-X-TARGETDURATION:6 +#EXT-X-VERSION:3 +#EXT-X-MEDIA-SEQUENCE:0 +#EXT-X-PLAYLIST-TYPE:VOD +#EXT-X-INDEPENDENT-SEGMENTS +#EXTINF:6.00000, +#EXT-X-BITRATE:377 +fileSequence0.ts +#EXTINF:6.00000, +#EXT-X-BITRATE:385 +fileSequence1.ts +#EXTINF:6.00000, +#EXT-X-BITRATE:388 +fileSequence2.ts +#EXTINF:6.00000, +#EXT-X-BITRATE:378 +fileSequence3.ts +#EXTINF:6.00000, +#EXT-X-BITRATE:378 +fileSequence4.ts +#EXTINF:6.00000, +#EXT-X-BITRATE:372 +fileSequence5.ts +#EXT-X-ENDLIST diff --git a/test/test/assets/hls-ts-muxed-aac-h264/chunk.m3u8 b/test/test/assets/hls-ts-muxed-aac-h264/chunk.m3u8 new file mode 100644 index 00000000000..3cb900763c9 --- /dev/null +++ b/test/test/assets/hls-ts-muxed-aac-h264/chunk.m3u8 @@ -0,0 +1,17 @@ +#EXTM3U +#EXT-X-VERSION:3 +#EXT-X-TARGETDURATION:7 +#EXT-X-MEDIA-SEQUENCE:0 +#EXTINF:6, +n_0_0_0.ts +#EXTINF:6, +n_1_0_0.ts +#EXTINF:6, +n_2_0_0.ts +#EXTINF:6, +n_3_0_0.ts +#EXTINF:6, +n_4_0_0.ts +#EXTINF:6, +n_5_0_0.ts +#EXT-X-ENDLIST diff --git a/test/test/assets/hls-ts-muxed-aac-h264/n_0_0_0.ts b/test/test/assets/hls-ts-muxed-aac-h264/n_0_0_0.ts new file mode 100644 index 00000000000..e7bbfa66a64 Binary files /dev/null and b/test/test/assets/hls-ts-muxed-aac-h264/n_0_0_0.ts differ diff --git a/test/test/assets/hls-ts-muxed-aac-h264/n_1_0_0.ts b/test/test/assets/hls-ts-muxed-aac-h264/n_1_0_0.ts new file mode 100644 index 00000000000..e5863732c66 Binary files /dev/null and b/test/test/assets/hls-ts-muxed-aac-h264/n_1_0_0.ts differ diff --git a/test/test/assets/hls-ts-muxed-aac-h264/n_2_0_0.ts b/test/test/assets/hls-ts-muxed-aac-h264/n_2_0_0.ts new file mode 100644 index 00000000000..cfcbb1ae149 Binary files /dev/null and b/test/test/assets/hls-ts-muxed-aac-h264/n_2_0_0.ts differ diff --git a/test/test/assets/hls-ts-muxed-aac-h264/n_3_0_0.ts b/test/test/assets/hls-ts-muxed-aac-h264/n_3_0_0.ts new file mode 100644 index 00000000000..0f6411cb7e5 Binary files /dev/null and b/test/test/assets/hls-ts-muxed-aac-h264/n_3_0_0.ts differ diff --git a/test/test/assets/hls-ts-muxed-aac-h264/n_4_0_0.ts b/test/test/assets/hls-ts-muxed-aac-h264/n_4_0_0.ts new file mode 100644 index 00000000000..7f3d08fb11c Binary files /dev/null and b/test/test/assets/hls-ts-muxed-aac-h264/n_4_0_0.ts differ diff --git a/test/test/assets/hls-ts-muxed-aac-h264/n_5_0_0.ts b/test/test/assets/hls-ts-muxed-aac-h264/n_5_0_0.ts new file mode 100644 index 00000000000..3a580fe02e4 Binary files /dev/null and b/test/test/assets/hls-ts-muxed-aac-h264/n_5_0_0.ts differ diff --git a/test/test/assets/hls-ts-muxed-aac-h264/playlist.m3u8 b/test/test/assets/hls-ts-muxed-aac-h264/playlist.m3u8 new file mode 100644 index 00000000000..e2dd642e523 --- /dev/null +++ b/test/test/assets/hls-ts-muxed-aac-h264/playlist.m3u8 @@ -0,0 +1,4 @@ +#EXTM3U +#EXT-X-VERSION:3 +#EXT-X-STREAM-INF:BANDWIDTH=1225016,CODECS="avc1.42c00d,mp4a.40.2",RESOLUTION=320x180 +chunk.m3u8 diff --git a/test/transmuxer/transmuxer_integration.js b/test/transmuxer/transmuxer_integration.js index e8332d048ef..432fceac196 100644 --- a/test/transmuxer/transmuxer_integration.js +++ b/test/transmuxer/transmuxer_integration.js @@ -32,19 +32,10 @@ describe('Transmuxer Player', () => { await shaka.test.Loader.loadShaka(getClientArg('uncompiled')); }); - beforeEach(() => { + beforeEach(async () => { + await shaka.test.TestScheme.createManifests(compiledShaka, '_compiled'); player = new compiledShaka.Player(video); - // Make sure we are playing the lowest res available to avoid test flake - // based on network issues. Note that disabling ABR and setting a low - // abr.defaultBandwidthEstimate would not be sufficient, because it - // would only affect the choice of track on the first period. When we - // cross a period boundary, the default bandwidth estimate will no - // longer be in effect, and AbrManager may choose higher res tracks for - // the new period. Using abr.restrictions.maxHeight will let us force - // AbrManager to the lowest resolution, which is its fallback when these - // soft restrictions cannot be met. - player.configure('abr.restrictions.maxHeight', 1); player.configure('mediaSource.forceTransmux', true); player.configure('streaming.useNativeHlsOnSafari', false); @@ -71,11 +62,7 @@ describe('Transmuxer Player', () => { }); it('raw AAC', async () => { - // eslint-disable-next-line max-len - const url = 'https://storage.googleapis.com/shaka-demo-assets/raw-hls-audio-only/manifest.m3u8'; - - await player.load(url, /* startTime= */ null, - /* mimeType= */ undefined); + await player.load('/base/test/test/assets/hls-raw-aac/manifest.m3u8'); await video.play(); expect(player.isLive()).toBe(false); @@ -85,7 +72,7 @@ describe('Transmuxer Player', () => { // Play for 15 seconds, but stop early if the video ends. If it takes // longer than 90 seconds, fail the test. - await waiter.waitUntilPlayheadReachesOrFailOnTimeout(video, 15, 90); + await waiter.waitUntilPlayheadReachesOrFailOnTimeout(video, 15, 15); await player.unload(); }); @@ -94,11 +81,7 @@ describe('Transmuxer Player', () => { if (!MediaSource.isTypeSupported('audio/mp4; codecs="mp3"')) { return; } - // eslint-disable-next-line max-len - const url = 'https://pl.streamingvideoprovider.com/mp3-playlist/playlist.m3u8'; - - await player.load(url, /* startTime= */ null, - /* mimeType= */ undefined); + await player.load('/base/test/test/assets/hls-raw-mp3/playlist.m3u8'); await video.play(); expect(player.isLive()).toBe(false); @@ -132,11 +115,7 @@ describe('Transmuxer Player', () => { return; } - // eslint-disable-next-line max-len - const url = 'https://devstreaming-cdn.apple.com/videos/streaming/examples/img_bipbop_adv_example_ts/a2/prog_index.m3u8'; - - await player.load(url, /* startTime= */ null, - /* mimeType= */ undefined); + await player.load('/base/test/test/assets/hls-raw-ac3/prog_index.m3u8'); await video.play(); expect(player.isLive()).toBe(false); @@ -166,11 +145,7 @@ describe('Transmuxer Player', () => { return; } - // eslint-disable-next-line max-len - const url = 'https://devstreaming-cdn.apple.com/videos/streaming/examples/img_bipbop_adv_example_ts/a3/prog_index.m3u8'; - - await player.load(url, /* startTime= */ null, - /* mimeType= */ undefined); + await player.load('/base/test/test/assets/hls-raw-ac3/prog_index.m3u8'); await video.play(); expect(player.isLive()).toBe(false); @@ -187,10 +162,7 @@ describe('Transmuxer Player', () => { it('muxed H.264+AAC in TS', async () => { // eslint-disable-next-line max-len - const url = 'https://cf-sf-video.wmspanel.com/local/raw/BigBuckBunny_320x180.mp4/playlist.m3u8'; - - await player.load(url, /* startTime= */ null, - /* mimeType= */ undefined); + await player.load('/base/test/test/assets/hls-ts-muxed-aac-h264/playlist.m3u8'); await video.play(); expect(player.isLive()).toBe(false); @@ -206,11 +178,7 @@ describe('Transmuxer Player', () => { }); it('AAC in TS', async () => { - // eslint-disable-next-line max-len - const url = 'https://bitdash-a.akamaihd.net/content/MI201109210084_1/m3u8s/f08e80da-bf1d-4e3d-8899-f0f6155f6efa_audio_1_stereo_128000.m3u8'; - - await player.load(url, /* startTime= */ null, - /* mimeType= */ undefined); + await player.load('/base/test/test/assets/hls-ts-aac/playlist.m3u8'); await video.play(); expect(player.isLive()).toBe(false); @@ -226,11 +194,7 @@ describe('Transmuxer Player', () => { }); it('H.264 in TS', async () => { - // eslint-disable-next-line max-len - const url = 'https://storage.googleapis.com/shaka-demo-assets/apple-advanced-stream-ts/v2/prog_index.m3u8'; - - await player.load(url, /* startTime= */ null, - /* mimeType= */ undefined); + await player.load('/base/test/test/assets/hls-ts-h264/prog_index.m3u8'); await video.play(); expect(player.isLive()).toBe(false);