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

Side by Side Diff: LayoutTests/webaudio/mediastreamaudiosourcenode.html

Issue 208943004: Update WebAudio layout tests to use unprefixed AudioContext. (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Add console.log to compatibility.js Created 6 years, 9 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 | Annotate | Revision Log
OLDNEW
1 <!DOCTYPE html> 1 <!DOCTYPE html>
2 2
3 <html> 3 <html>
4 <head> 4 <head>
5 <script src="../resources/js-test.js"></script> 5 <script src="../resources/js-test.js"></script>
6 <script src="resources/compatibility.js"></script>
6 <script src="resources/audio-testing.js"></script> 7 <script src="resources/audio-testing.js"></script>
7 </head> 8 </head>
8 9
9 <body> 10 <body>
10 <div id="description"></div> 11 <div id="description"></div>
11 <div id="console"></div> 12 <div id="console"></div>
12 13
13 <script> 14 <script>
14 description("Basic tests for MediaStreamAudioSourceNode API."); 15 description("Basic tests for MediaStreamAudioSourceNode API.");
15 16
(...skipping 12 matching lines...) Expand all
28 finishJSTest(); 29 finishJSTest();
29 } 30 }
30 } 31 }
31 32
32 function gotStream(stream) { 33 function gotStream(stream) {
33 s = stream; 34 s = stream;
34 testPassed('{audio:true} generated stream'); 35 testPassed('{audio:true} generated stream');
35 shouldBe('s.getAudioTracks().length', '1'); 36 shouldBe('s.getAudioTracks().length', '1');
36 shouldBe('s.getVideoTracks().length', '0'); 37 shouldBe('s.getVideoTracks().length', '0');
37 38
38 context = new webkitAudioContext(); 39 context = new AudioContext();
39 40
40 // Create an AudioNode from the stream. 41 // Create an AudioNode from the stream.
41 var mediaStreamSource = context.createMediaStreamSource(stream); 42 var mediaStreamSource = context.createMediaStreamSource(stream);
42 43
43 // Check number of inputs and outputs. 44 // Check number of inputs and outputs.
44 if (mediaStreamSource.numberOfInputs == 0) 45 if (mediaStreamSource.numberOfInputs == 0)
45 testPassed("Source AudioNode has no inputs."); 46 testPassed("Source AudioNode has no inputs.");
46 else 47 else
47 testFailed("Source AudioNode should not have inputs."); 48 testFailed("Source AudioNode should not have inputs.");
48 49
(...skipping 37 matching lines...) Expand 10 before | Expand all | Expand 10 after
86 } 87 }
87 88
88 getUserMedia({audio:true}, gotStream); 89 getUserMedia({audio:true}, gotStream);
89 window.jsTestIsAsync = true; 90 window.jsTestIsAsync = true;
90 window.successfullyParsed = true; 91 window.successfullyParsed = true;
91 92
92 </script> 93 </script>
93 94
94 </body> 95 </body>
95 </html> 96 </html>
OLDNEW
« no previous file with comments | « LayoutTests/webaudio/mediastreamaudiodestinationnode.html ('k') | LayoutTests/webaudio/mixing.html » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698