Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(124)

Side by Side Diff: third_party/WebKit/LayoutTests/webaudio/oscillator-ended.html

Issue 2581463002: Refactor WebAudio test directory (Closed)
Patch Set: Use correct path for wav result files Created 3 years, 12 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
(Empty)
1 <!DOCTYPE html>
2 <head>
3 <script src="../resources/js-test.js"></script>
4 <script src="resources/compatibility.js"></script>
5 <script src="resources/audit-util.js"></script>
6 <script src="resources/audio-testing.js"></script>
7 <script src="resources/audiobuffersource-testing.js"></script>
8 <script>
9 var context;
10 var source;
11
12 function runTest()
13 {
14 if (window.testRunner) {
15 testRunner.dumpAsText();
16 testRunner.waitUntilDone();
17 }
18
19 var sampleRate = 44100.0;
20 var lengthInSeconds = 0.1;
21 context = new OfflineAudioContext(1, sampleRate * lengthInSeconds, s ampleRate);
22 osc = context.createOscillator();
23 osc.type = "sine";
24 osc.connect(context.destination);
25 osc.onended = function()
26 {
27 testPassed("osc.onended called.");
28 finishJSTest();
29 if (window.testRunner)
30 testRunner.notifyDone();
31
32 }
33 osc.start(0);
34 osc.stop(0.1);
35 context.startRendering();
36 }
37 </script>
38 </head>
39 <body onload="runTest()">
40 <div>Tests that OscillatorNode calls its onended EventListener.</div>
41 <div id="console"></div>
42 </body>
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698