You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
* fix(tests): correct unit tests that pass without verifying behavior
- DashParser: replace .bind() with arrow functions so parse() is
actually called with the intended arguments (lines 17-28)
- DashParser: move async fixture loading from describe() scope into
a before() hook — Mocha does not support async describe (line 64)
- MssParser: same .bind() fix (line 62)
- Stream: await the Promise from setMediaSource() so the assertion
runs before Mocha marks the test as passed (lines 93-98)
FixesDash-Industry-Forum#5011
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
* fix(parser): reject non-MPD XML input in DashParser.parse()
parseXml() can return a non-null object for any parseable XML-like
string. The existing guard only checked for null, so non-MPD input
(e.g. plain text) would pass validation and crash later when accessing
.protocol on undefined.
Add a check for the presence of MPD or Patch root elements before
proceeding. This gives callers the expected 'failed to parse the
manifest' error instead of a cryptic property access error.
Bug exposed by fixing the .bind() test pattern in Dash-Industry-Forum#5012.
Refs Dash-Industry-Forum#5011
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
* test(dash): cover patch root parsing in DashParser
---------
Co-authored-by: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
0 commit comments