Commit Graph

8 Commits

Author SHA1 Message Date
Joey Parrish 2e7c25ab67 Export shaka.util.AbortableOperation
This exports shaka.util.AbortableOperation, which plugin writers will
realistically need to update their scheme plugins.

Change-Id: Idfc149f06d22699a78c4d989d331619d5e74f097
2018-04-05 22:03:11 +00:00
Theodore Abshire 7c5186332b Typo fixes and rewording in comments, part 7
This makes a large number of small typo fixes. It also rewords a
number of comments and JSDoc descriptions, and does some
formatting standardization.

This doesn't fix every single issue, but it fixes a lot. Notably,
there were some formatting issues I declined to standardize due to
ambivalence on what the proper standardization would be; for example,
when and where empty lines should show up in JSDoc.

Change-Id: I225f5c7e54adf4cca8512cddae082ba50ed82e4e
2018-03-21 19:45:15 +00:00
Joey Parrish f48f7fd9c4 Clean up uncaught Promise rejections
- Translate uncaught Promise rejections into test failures
   (Chrome only until the event is more widely implemented)

 - Clean up uncaught Promise rejection caused by exceptions thrown
   after destroy() in:
   - CastProxy
   - CastReceiver
   - NetworkingEngine
   - StreamingEngine

 - Clean up uncaught Promise rejection caused by test cases in:
   - CancelableChain unit tests
   - DrmEngine unit tests
   - StreamingEngine unit and integration tests
   - Player unit and integration tests

 - Speed up rejection in NetworkingEngine when we should not retry

 - Add --delay-tests to test.py, to aid in debugging uncaught
   Promise rejections and other types of async test pollution

Closes #1323

Change-Id: I5a8f5702a22430929babeb071bf6650c52c5ad17
2018-02-28 22:56:12 +00:00
Jacob Trimble f70436540c Convert 'var' to 'let'/'const' (3 of 9).
This is part of a change to convert all usages of 'var' with either
'let' or 'const'.  This takes a conservative approach for 'const' where
it will only be used for aliases and storing the "original" values in
tests.

Change-Id: I10f5c38a8b06b5797c6eec7492829084114514c9
2018-02-14 00:47:03 +00:00
Joey Parrish ed54199260 Upgrade and unfork jsdoc
This updates jsdoc to the latest version from npm and forks a copy of
the default jsdoc template.

In subsequent commits, we will reapply our customizations to the
template and to a jsdoc plugin.

This also fixes several bad annotations that the new jsdoc failed to
parse.

Issue #1259

Change-Id: I00a47270ea4754e1c96c43ca900d5cf889ab72e6
2018-01-31 22:04:48 +00:00
Joey Parrish 0cbb962681 Improve AbortableOperation tests
This does not solve failures on IE11, but does make them clearer and
helps pinpoint the root cause.

Issue #1260

Change-Id: I00a10b38d1eb1f3293c3285a34bde96c631d1c74
2018-01-30 20:42:15 +00:00
Joey Parrish 6910648ec6 Add one more test for AbortableOperation
This is a regression test for an implementation bug we caught before
it was released.  It took a little longer to get the regression test
working, so this was deferred to a later commit.

Issue #829

Change-Id: I272ebe0e6fa2f0ac462c3a3d236250242f7d7192
2018-01-29 22:20:06 +00:00
Joey Parrish e5afb35169 AbortableOperation interface
This adds a general interface for abortable operations, and a specific
implementation of that interface for use internally.  This should
simplify the transition to abortable network requests and others.

Issue #829

Change-Id: Icf54e23028f7454640f5ec76ca97d8a8ed5915ed
2018-01-29 19:23:47 +00:00