Bug 867104 - Add a crashtest. r=ehsan
authorPaul Adenot <paul@paul.cx>
Tue, 14 May 2013 14:14:42 +0200
changeset 131879 d98e7c680020219847eb2786111fecfdf753af68
parent 131878 744de2aced8cd2b4176f4274327586040e40ddde
child 131880 2aa62db58f2488f67ee73980c5cc4b816272feca
push id24674
push userryanvm@gmail.com
push dateTue, 14 May 2013 20:16:17 +0000
treeherdermozilla-central@26ab72bfa9df [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersehsan
bugs867104
milestone24.0a1
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Bug 867104 - Add a crashtest. r=ehsan
content/media/webaudio/test/Makefile.in
content/media/webaudio/test/test_bug867104.html
--- a/content/media/webaudio/test/Makefile.in
+++ b/content/media/webaudio/test/Makefile.in
@@ -15,16 +15,17 @@ MOCHITEST_FILES := \
   test_bug808374.html \
   test_bug827541.html \
   test_bug839753.html \
   test_bug845960.html \
   test_bug856771.html \
   test_bug866570.html \
   test_bug866737.html \
   test_bug867089.html \
+  test_bug867104.html \
   test_bug867174.html \
   test_bug867203.html \
   test_analyserNode.html \
   test_AudioBuffer.html \
   test_AudioContext.html \
   test_AudioListener.html \
   test_AudioParam.html \
   test_audioParamExponentialRamp.html \
new file mode 100644
--- /dev/null
+++ b/content/media/webaudio/test/test_bug867104.html
@@ -0,0 +1,36 @@
+<!DOCTYPE HTML>
+<html>
+<head>
+  <title>Crashtest for bug 867104</title>
+  <script type="text/javascript" src="/tests/SimpleTest/SimpleTest.js"></script>
+  <link rel="stylesheet" type="text/css" href="/tests/SimpleTest/test.css" />
+</head>
+<body>
+<pre id="test">
+<script class="testbody" type="text/javascript">
+
+SpecialPowers.setBoolPref("media.webaudio.enabled", true);
+SimpleTest.waitForExplicitFinish();
+addLoadEvent(function() {
+  var ctx = new AudioContext();
+  var source = ctx.createBufferSource();
+  var b0 = ctx.createBuffer(32,798,22050);
+  var b1 = ctx.createBuffer(32,28,22050);
+  var sp = ctx.createScriptProcessor();
+  source.buffer = b0;
+  source.connect(sp);
+  source.start(0);
+  source.buffer = b1;
+  sp.onaudioprocess = function() {
+    ok(true, "We did not crash.");
+    sp.onaudioprocess = null;
+    SpecialPowers.clearUserPref("media.webaudio.enabled");
+    SimpleTest.finish();
+  };
+});
+
+
+</script>
+</pre>
+</body>
+</html>