Display total VOD duration from provider metadata and stream probes
Adapted from MikaelKW/nodecast-tv-plus commit 9c6416cdba40813d44d21c8d76e31e4d9ab3155f. Co-authored-by: Mikael <mikaelkwessel@gmail.com>
This commit is contained in:
@ -21,7 +21,7 @@ test('probe preserves every audio track index including unknown codecs', () => {
|
||||
|
||||
function playerFixture(name, settings, probe) {
|
||||
const window = { dispatchEvent() {} };
|
||||
const context = { window, console: { log() {}, warn() {}, error() {} },
|
||||
const context = { window, VodDuration: require('../public/js/components/VodDuration'), console: { log() {}, warn() {}, error() {} },
|
||||
CustomEvent: class {}, document: { getElementById() { return null; } },
|
||||
API: { settings: { get: async () => settings } }, fetch: probe };
|
||||
const file = name === 'VideoPlayer' ? 'components/VideoPlayer.js' : 'pages/WatchPage.js';
|
||||
|
||||
Reference in New Issue
Block a user