| OLD | NEW |
| 1 <!DOCTYPE html> | 1 <!DOCTYPE html> |
| 2 <html> | 2 <html> |
| 3 <head> | 3 <head> |
| 4 <script src="../../resources/js-test.js"></script> | 4 <script src="../../resources/js-test.js"></script> |
| 5 <script src="../resources/compatibility.js"></script> | |
| 6 </head> | 5 </head> |
| 7 <body> | 6 <body> |
| 8 <script> | 7 <script> |
| 9 description("Check that the AudioContext constructor throws when the limit on ha
rdware contexts is reached."); | 8 description("Check that the AudioContext constructor throws when the limit on ha
rdware contexts is reached."); |
| 10 | 9 |
| 11 function reachHardwareContextsLimit() { | 10 function reachHardwareContextsLimit() { |
| 12 var context = []; | 11 var context = []; |
| 13 for (var i=0; i<10; ++i) | 12 for (var i=0; i<10; ++i) |
| 14 context[i] = new AudioContext(); | 13 context[i] = new AudioContext(); |
| 15 } | 14 } |
| 16 | 15 |
| 17 shouldThrow("reachHardwareContextsLimit()"); | 16 shouldThrow("reachHardwareContextsLimit()"); |
| 18 </script> | 17 </script> |
| 19 </body> | 18 </body> |
| 20 </html> | 19 </html> |
| OLD | NEW |