mirror of
https://gitlab.winehq.org/wine/wine-gecko.git
synced 2024-09-13 09:24:08 -07:00
40 lines
1.3 KiB
JavaScript
40 lines
1.3 KiB
JavaScript
/* Any copyright is dedicated to the Public Domain.
|
|
http://creativecommons.org/publicdomain/zero/1.0/ */
|
|
|
|
/**
|
|
* Tests that params view correctly displays all properties for nodes
|
|
* correctly, with default values and correct types.
|
|
*/
|
|
|
|
function spawnTest() {
|
|
let { target, panel } = yield initWebAudioEditor(SIMPLE_NODES_URL);
|
|
let { panelWin } = panel;
|
|
let { gFront, $, $$, EVENTS, InspectorView } = panelWin;
|
|
let gVars = InspectorView._propsView;
|
|
|
|
let started = once(gFront, "start-context");
|
|
|
|
reload(target);
|
|
|
|
let [actors] = yield Promise.all([
|
|
getN(gFront, "create-node", 14),
|
|
waitForGraphRendered(panelWin, 14, 0)
|
|
]);
|
|
let nodeIds = actors.map(actor => actor.actorID);
|
|
let types = [
|
|
"AudioDestinationNode", "AudioBufferSourceNode", "ScriptProcessorNode",
|
|
"AnalyserNode", "GainNode", "DelayNode", "BiquadFilterNode", "WaveShaperNode",
|
|
"PannerNode", "ConvolverNode", "ChannelSplitterNode", "ChannelMergerNode",
|
|
"DynamicsCompressorNode", "OscillatorNode"
|
|
];
|
|
|
|
for (let i = 0; i < types.length; i++) {
|
|
click(panelWin, findGraphNode(panelWin, nodeIds[i]));
|
|
yield once(panelWin, EVENTS.UI_INSPECTOR_NODE_SET);
|
|
checkVariableView(gVars, 0, NODE_DEFAULT_VALUES[types[i]], types[i]);
|
|
}
|
|
|
|
yield teardown(panel);
|
|
finish();
|
|
}
|