Bug 911777 - Collect cycles before getting maxChannelCount to release some cubeb streams. r=padenot, a=test-only
authorKarl Tomlinson <karlt+@karlt.net>
Sat, 07 Sep 2013 00:33:32 +1200
changeset 154034 b8722497028839afd325680f11f3d2b4491496bb
parent 154033 8e1dde8bf956b30f32c762e8e84030db7cada96d
child 154035 ed7e018f12bd4d0a86c7e0e3a4280a38a9fc0c13
push id2859
push userakeybl@mozilla.com
push dateMon, 16 Sep 2013 19:14:59 +0000
treeherdermozilla-beta@87d3c51cd2bf [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewerspadenot, test-only
bugs911777
milestone25.0a2
Bug 911777 - Collect cycles before getting maxChannelCount to release some cubeb streams. r=padenot, a=test-only
content/media/webaudio/test/Makefile.in
content/media/webaudio/test/test_maxChannelCount.html
--- a/content/media/webaudio/test/Makefile.in
+++ b/content/media/webaudio/test/Makefile.in
@@ -52,20 +52,22 @@ MOCHITEST_FILES := \
   test_audioBufferSourceNodeNullBuffer.html \
   test_badConnect.html \
   test_biquadFilterNode.html \
   test_channelMergerNode.html \
   test_channelMergerNodeWithVolume.html \
   test_channelSplitterNode.html \
   test_channelSplitterNodeWithVolume.html \
   test_convolverNode.html \
+  test_convolverNodeChannelCount.html \
   test_convolverNodeWithGain.html \
   test_convolverNode_mono_mono.html \
   test_currentTime.html \
   test_delayNode.html \
+  test_delayNodeAtMax.html \
   test_delayNodeSmallMaxDelay.html \
   test_delayNodeWithGain.html \
   test_dynamicsCompressorNode.html \
   test_gainNode.html \
   test_gainNodeInLoop.html \
   test_maxChannelCount.html \
   test_mediaDecoding.html \
   test_decodeMultichannel.html \
@@ -108,22 +110,15 @@ MOCHITEST_FILES := \
   noaudio.webm \
   audio.ogv \
   audio-expected.wav \
   audio-mono-expected.wav \
   audio-mono-expected-2.wav \
   audio-quad.wav \
   $(NULL)
 
-ifneq ($(MOZ_DEBUG)+$(MOZ_WIDGET_TOOLKIT),+gtk2) # bug 911777
-MOCHITEST_FILES += \
-  test_convolverNodeChannelCount.html \
-  test_delayNodeAtMax.html \
-  $(NULL)
-endif # bug 911777
-
 ifneq ($(OS_TARGET),Android) # bug 912474
 MOCHITEST_FILES += \
   test_pannerNodeChannelCount.html \
   $(NULL)
 endif
 
 include $(topsrcdir)/config/rules.mk
--- a/content/media/webaudio/test/test_maxChannelCount.html
+++ b/content/media/webaudio/test/test_maxChannelCount.html
@@ -5,16 +5,20 @@
   <script type="text/javascript" src="/tests/SimpleTest/SimpleTest.js"></script>
   <script type="text/javascript" src="webaudio.js"></script>
   <link rel="stylesheet" type="text/css" href="/tests/SimpleTest/test.css" />
 </head>
 <body>
 <pre id="test">
 <script class="testbody" type="text/javascript">
 
+// Work around bug 911777
+SpecialPowers.forceGC();
+SpecialPowers.forceCC();
+
 SimpleTest.waitForExplicitFinish();
 addLoadEvent(function() {
   var ac = new AudioContext();
   ok(ac.destination.maxChannelCount > 0, "We can query the maximum number of channels");
 
   var oac = new OfflineAudioContext(2, 1024, 48000);
   ok(oac.destination.maxChannelCount, 2, "This OfflineAudioContext should have 2 max channels.");