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

Side by Side Diff: LayoutTests/webaudio/audiobuffersource-channels.html

Issue 99083002: WIP: Migrate generated bindings to new ExceptionState constructor. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Rebase. Created 7 years 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
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 type="text/javascript" src="resources/audio-testing.js"></script> 6 <script type="text/javascript" src="resources/audio-testing.js"></script>
7 </head> 7 </head>
8 8
9 <body> 9 <body>
10 <div id="description"></div> 10 <div id="description"></div>
(...skipping 11 matching lines...) Expand all
22 testRunner.waitUntilDone(); 22 testRunner.waitUntilDone();
23 } 23 }
24 24
25 window.jsTestIsAsync = true; 25 window.jsTestIsAsync = true;
26 26
27 context = new webkitAudioContext(); 27 context = new webkitAudioContext();
28 source = context.createBufferSource(); 28 source = context.createBufferSource();
29 29
30 // Make sure we can't set to something which isn't an AudioBuffer. 30 // Make sure we can't set to something which isn't an AudioBuffer.
31 shouldThrow("source.buffer = 57", '"TypeError: Failed to set the \'buffer\' property on \'AudioBufferSourceNode\': The provided value is not of type \'Audio Buffer\'."'); 31 shouldThrow("source.buffer = 57", '"TypeError: Failed to set the \'buffer\' property on \'AudioBufferSourceNode\': The provided value is not of type \'Audio Buffer\'."');
32 shouldThrow("source.buffer = null", "'TypeError: buffer cannot be null'"); 32 shouldThrow("source.buffer = null", '"TypeError: Failed to set the \'buffer\ ' property on \'AudioBufferSourceNode\': buffer cannot be null"');
33 33
34 // Check that mono buffer can be set. 34 // Check that mono buffer can be set.
35 try { 35 try {
36 var monoBuffer = context.createBuffer(1, 1024, context.sampleRate); 36 var monoBuffer = context.createBuffer(1, 1024, context.sampleRate);
37 source.buffer = monoBuffer; 37 source.buffer = monoBuffer;
38 testPassed("Mono buffer can be set."); 38 testPassed("Mono buffer can be set.");
39 } catch(e) { 39 } catch(e) {
40 testFailed("Mono buffer can not be set."); 40 testFailed("Mono buffer can not be set.");
41 } 41 }
42 42
(...skipping 21 matching lines...) Expand all
64 64
65 finishJSTest(); 65 finishJSTest();
66 } 66 }
67 67
68 runTest(); 68 runTest();
69 69
70 </script> 70 </script>
71 71
72 </body> 72 </body>
73 </html> 73 </html>
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698