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

Side by Side Diff: LayoutTests/webaudio/dom-exceptions.html

Issue 1074463003: Return after throwing an exception when ConvolerNode.buffer rate is wrong. (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 5 years, 8 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
« no previous file with comments | « no previous file | LayoutTests/webaudio/dom-exceptions-expected.txt » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"> 1 <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
2 <html> 2 <html>
3 <head> 3 <head>
4 <script src="resources/compatibility.js"></script> 4 <script src="resources/compatibility.js"></script>
5 <script src="resources/audio-testing.js"></script> 5 <script src="resources/audio-testing.js"></script>
6 <script src="../resources/js-test.js"></script> 6 <script src="../resources/js-test.js"></script>
7 <script src="resources/biquad-testing.js"></script> 7 <script src="resources/biquad-testing.js"></script>
8 </head> 8 </head>
9 9
10 <body> 10 <body>
(...skipping 242 matching lines...) Expand 10 before | Expand all | Expand 10 after
253 // conversion to a float produces 0. Any larger value would produce a non-z ero value when 253 // conversion to a float produces 0. Any larger value would produce a non-z ero value when
254 // converted to a single float. 254 // converted to a single float.
255 shouldThrow("node.gain.exponentialRampToValueAtTime(Math.pow(2, -150), 0.1)" ); 255 shouldThrow("node.gain.exponentialRampToValueAtTime(Math.pow(2, -150), 0.1)" );
256 256
257 // Convolver buffer rate must match context rate. Create on offline context so we 257 // Convolver buffer rate must match context rate. Create on offline context so we
258 // specify the context rate exactly, in case the test is run on platforms wi th different 258 // specify the context rate exactly, in case the test is run on platforms wi th different
259 // HW sample rates. 259 // HW sample rates.
260 shouldNotThrow("oc = new OfflineAudioContext(1, 44100, 44100)"); 260 shouldNotThrow("oc = new OfflineAudioContext(1, 44100, 44100)");
261 shouldNotThrow("conv = oc.createConvolver()"); 261 shouldNotThrow("conv = oc.createConvolver()");
262 shouldThrow("conv.buffer = oc.createBuffer(1, 100, 22050)"); 262 shouldThrow("conv.buffer = oc.createBuffer(1, 100, 22050)");
263 263 // conv.buffer should be unchanged (null) because the above failed.
264 shouldBeNull("conv.buffer");
265
264 // PannerNode channel count and mode 266 // PannerNode channel count and mode
265 panner = context.createPanner(); 267 panner = context.createPanner();
266 // Channel count can only be set to 1 or 2. 268 // Channel count can only be set to 1 or 2.
267 shouldNotThrow("panner.channelCount = 1"); 269 shouldNotThrow("panner.channelCount = 1");
268 shouldNotThrow("panner.channelCount = 2"); 270 shouldNotThrow("panner.channelCount = 2");
269 shouldThrowAndBeUnchanged("panner.channelCount", "0"); 271 shouldThrowAndBeUnchanged("panner.channelCount", "0");
270 shouldThrowAndBeUnchanged("panner.channelCount", "3"); 272 shouldThrowAndBeUnchanged("panner.channelCount", "3");
271 // It is illegal to set the mode to 'max' 273 // It is illegal to set the mode to 'max'
272 shouldThrowAndBeUnchanged("panner.channelCountMode", "'max'"); 274 shouldThrowAndBeUnchanged("panner.channelCountMode", "'max'");
273 shouldNotThrow("panner.channelCountMode = 'explicit'"); 275 shouldNotThrow("panner.channelCountMode = 'explicit'");
(...skipping 21 matching lines...) Expand all
295 shouldBeUndefined("source.noteOn"); 297 shouldBeUndefined("source.noteOn");
296 shouldBeUndefined("source.noteOff"); 298 shouldBeUndefined("source.noteOff");
297 } 299 }
298 300
299 runTest(); 301 runTest();
300 successfullyParsed = true; 302 successfullyParsed = true;
301 303
302 </script> 304 </script>
303 </body> 305 </body>
304 </html> 306 </html>
OLDNEW
« no previous file with comments | « no previous file | LayoutTests/webaudio/dom-exceptions-expected.txt » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698