Upstream version 5.34.104.0
[platform/framework/web/crosswalk.git] / src / third_party / WebKit / LayoutTests / webaudio / gain-basic.html
1 <!DOCTYPE html>
2
3 <!--
4 Verifies GainNode attributes and their type.
5 -->
6
7 <html>
8 <head>
9 <script src="../resources/js-test.js"></script>
10 <script type="text/javascript" src="resources/audio-testing.js"></script>
11
12 </head>
13 <body>
14
15 <script>
16 description("Tests GainNode attributes in IDL.");
17
18 function runTest() {
19     if (window.testRunner) {
20         testRunner.dumpAsText();
21     }
22
23     // Create audio context.
24     var context = new webkitAudioContext();
25
26     // Create gain node.
27     var gainNode = context.createGain();
28
29     if (gainNode.gain.toString().indexOf("AudioParam") > -1)
30         testPassed("gain is of AudioParam type.");
31     else
32         testFailed("gain is not of AudioParam type.");
33 }
34
35 runTest();
36 </script>
37
38 </body>
39 </html>