This is done by implementing a fake cubeb backend that implements the subset of
operations we need, while offering an API to be able to control what this
backend is doing.
Because we're reimplementing the private cubeb API, it is necessary to copy
part of a cubeb internal header, and mimick exactly how the vtable mechanism to
do the dynamic dispatch to the diffferent backends in cubeb works. This is not
ideal but works.
When the cubeb API functions are called (from deep in the Gecko process), we
re-bind the call to the mock cubeb backend object and behave exactly like a
normal backend (calling various callbacks and returning fake objects).
Finally, we inject this mock cubeb backend to the running Gecko process (in lieu
of the real one that would have been picked) by setting the global sCubebBackend
variable via a private API exposed only in the test in CubebUtils.h.
MozReview-Commit-ID: 8ZbJhl7pZ2t
--HG--
extra : rebase_source : 922a03fa84803ed04aed633795a54b8d2a305e15
Also, clear the array that's been passed in before appending the new devices.
MozReview-Commit-ID: BTnwzyKBrb5
--HG--
extra : rebase_source : 23dbd11720804a30188389bc4408be4b40ad70b2
This is for testing purposes only. Defining ENABLE_SET_CUBEB_BACKEND before
including CubebUtils.h will expose the function. This is not to be set outside
of test files.
MozReview-Commit-ID: D0V8oLj9xo6
--HG--
extra : rebase_source : e80d4c01ff3b28c300de1e6819477ea732c2f157
This is slightly slower, especially if the main thread is busy, but it's cleaner
and actually safe.
MozReview-Commit-ID: 4C2FalxmE3L
--HG--
extra : rebase_source : 3f1341397bede31fcc35dab5a0cbf59b893f9b81
For an AudioCallbackDriver, the number of input channels is immutable, and
passed at construction, so that it's less necessary to rely on global state.
MozReview-Commit-ID: F9TL1H92z3W
--HG--
extra : rebase_source : 5193488592ca97273eb2b6f43d4c7a0e4beb0a33
The MSG now can feed microphone data to all its input listeners. This paves the
way for multiple input device, if we feel it's needed at some point, but does
not implement it.
The method for adding/removing inputs are also cleaned up.
MozReview-Commit-ID: 9OX4Da6Gjq2
--HG--
extra : rebase_source : 043c486e53f9220ae61fd788ed86064ba723f1a4
beforeTestSync uses an asynchronous operation that takes a while to finish.
In the meantime, it's very likely that the browser will run some tasks
scheduled to run when idle, which cause XPCOMUtils mock in browser-test.js
to be used, which references _globalProperties.
--HG--
extra : rebase_source : 3d75068a43cad4e87317792c67b6fe5fd483f0c5
TypedObjects that map Wasm structs with fields that have Ref type are
not yet constructible from JS because the type constraint can't be
honored. So for now, make it possible for Wasm to flag such structs
as unconstructible-from-JS.
--HG--
extra : rebase_source : aab9d7f2ba7b4c1ff7875d184b86bb0ae3e32413
extra : intermediate-source : 97c72ae6e843fe1cb712bd4855d174fc711c3cb0
extra : source : f59588ebc5c4ff06bfb437896147e07cb856e355
This allows internal clients (notably Wasm) to flag TO fields as
immutable; we need this both to provide immutability for fields that
are declared immutable in wasm structs, and to temporarily avoid the
need for type constraints on assignments to Ref-typed pointer fields.
--HG--
extra : rebase_source : 19d1b1bf81396ca305b699cda0277fd8e41f5fe9
extra : intermediate-source : d219c9587f920a0f5924dbdab3e8cf5dfecf3f75
extra : source : f1161dd31ac1cf6f050315d04b978b9d6c0c824a
Struct types need to appear to be callable, or some paths through the
engine will not think that they are constructors (since constructors
are callable).
They are not *actually* callable however; the call implementation
always throws.
--HG--
extra : rebase_source : a0db93050943bda3348887c8a63a374e19158d41
extra : source : 437198f32338d69602f3375f94a996f3d880fa17
In the old days we could only share a SharedArrayBuffer, but now we
can also share WasmMemory and WasmModule objects. Rename the shell's
get/setSharedArrayBuffer as get/setSharedObject and generalize them to
handle the new types.
Leave the old names in place as aliases of the new names.
We rename /some/ uses of get/setSharedArrayBuffer in existing test
cases, but leave uses in test262 alone; we need to upstream those more
carefully.
--HG--
extra : rebase_source : 5ca04306a739249a70fc4aa8734b08e16d62f7d4
extra : source : fcd471c23cf3c1374541df766fd5aea0628fb2a5
Automatic update from web-platform-testsHTML event handlers: More uniform naming convention
--
HTML event handlers: Use .window.js instead of .html for some files
--
HTML event handlers: Use IDL parser for list of event handlers
--
HTML event handlers: Use synchronous test() where able
--
HTML event handlers: Additionally test unshadowed event handlers
--
HTML: tests for new event handler spec
See: https://github.com/whatwg/html/pull/3850
--
HTML event handlers: Test document.createElement("body")
--
wpt-commits: db24506f8af9048c0a80d89c9981ef445d6c3af9, 3e273bc58ae2af40f4b00b514f2fd6d604ffc98d, 8bf45a39c3435737ebc862904af245d27b68efce, 776041862ca0cab7a8dd10e29361dbf3359a0b2f, fa58a12fc565fc152bff196e803fd9290dfa1bc7, fc2eba9d6f0a860c0db1457852124e320fd8d499, 8e668a6b63e5dbb68304c182fdc1f7b4e6edaf96
wpt-pr: 12201
Automatic update from web-platform-testsAdd UserActivation member to MessageEvent
Add an API to query user activation state on a posted message event.
Add includeUserActivation attribute on the WindowPostMessageOptions so
that indication of user gesture behavior can be opted in.
https://github.com/dtapuska/useractivationhttps://github.com/whatwg/html/issues/1983
BUG=846858
TBR=mkwst@chromium.org
Change-Id: I2459b21004afbe00c41ddf992533c60728768bb4
Reviewed-on: https://chromium-review.googlesource.com/1131558
Commit-Queue: Dave Tapuska <dtapuska@chromium.org>
Reviewed-by: Ken Buchanan <kenrb@chromium.org>
Reviewed-by: Marijn Kruisselbrink <mek@chromium.org>
Cr-Commit-Position: refs/heads/master@{#579398}
--
wpt-commits: 8a1d5c110779c525257fe2305ba7a21ae6e969e6
wpt-pr: 12157
Automatic update from web-platform-testsAvoid using the JavaScript reserved word `arguments`
ES6 complains if the JS reserved word `arguments` is used in strict
mode. Rename variable to avoid issues --- especially when test cases
are reused with other test harnesses.
--
wpt-commits: fe830a9732f4748d37a932d1b2c813e2ed47d491
wpt-pr: 12213
Automatic update from web-platform-testsClean up the BackgroundSync IDL test (#12242)
--
wpt-commits: f1d7391442edcdb97bbf968b2ff631c387e3a8ef
wpt-pr: 12242
Automatic update from web-platform-testsMark some tests as failing in python 3.0-3.5. (#11753)
The json.loads API did not accept binary strings in these python versions.
This change does not affect the testing in CI, but helps with certain older
local setups.
--
wpt-commits: 03a5a5cb81912613e15f268a20cfdf919635fe4d
wpt-pr: 11753
Automatic update from web-platform-testsCreate a dictionary of {item_type: ManifestItemClass}
Sometimes we need to know all the types of test that exist. Typically
this has either been done by hardcoding a list or using some custom
approach to finding all the subclasses of the original. Instead it
makes sense to have the classes register themselves on creation so
that we can simply look in the registry for the types.
To do this we use a cusom metaclass that first constucts the class
object and then adds it to the registry.
--
wpt-commits: 76d1afcb887b5911e0151ff0be991a267d70d0a1
wpt-pr: 12229