Bug 1089022 - Give WebGL conf. tests a longer timeout. r=kamidphish, a=test-only
authorJeff Gilbert <jgilbert@mozilla.com>
Wed, 15 Oct 2014 15:40:41 -0700
changeset 225846 9a6a63827c10
parent 225845 76dcced7d838
child 225847 d9496ec99e83
push id4039
push userryanvm@gmail.com
push date2014-10-29 14:09 +0000
treeherdermozilla-beta@c94fc6b83daa [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewerskamidphish, test-only
bugs1089022
milestone34.0
Bug 1089022 - Give WebGL conf. tests a longer timeout. r=kamidphish, a=test-only
dom/canvas/test/webgl-conformance/mochi-single.html
--- a/dom/canvas/test/webgl-conformance/mochi-single.html
+++ b/dom/canvas/test/webgl-conformance/mochi-single.html
@@ -47,18 +47,19 @@ if (!window.ok) {
 }
 if (!window.todo) {
   window.todo = function(status, message) {
     console.log('todo(' + status + ', "' + message + '")');
   }
 }
 if (!window.SimpleTest) {
   window.SimpleTest = {
+    finish: function(){},
+    requestLongerTimeout: function(){},
     waitForExplicitFinish: function(){},
-    finish: function(){},
   };
 }
 
 ////////////////////////////////////////////////////////////////////////
 // Implement our own version of `fail-if` expected failure handling.
 // `fail-if` in mochitest.ini doesn't work yet. (bug 987849)
 
 var OS_VERSION_WIN7 = 6.1;
@@ -235,16 +236,23 @@ function OnTestComplete() {
   SimpleTest.finish();
 }
 
 ////////////////////////////////////////////////////////////////////////
 // Begin execution
 
 SimpleTest.waitForExplicitFinish();
 
+var isAndroid2_3 = (DriverInfo.getOS() == DriverInfo.OS.ANDROID &&
+                    DriverInfo.getOSVersion() < OS_VERSION_ANDROID_ICS);
+if (isAndroid2_3) {
+  var timeoutLengthMultiplier = 2.0;
+  SimpleTest.requestLongerTimeout(timeoutLengthMultiplier);
+}
+
 do {
   var arg = location.search.substr(1);
   if (arg == 'dump') {
     statusElem.innerHTML = 'Dumping';
 
     ok(true, 'OS:' + DriverInfo.getOS());
     ok(true, 'OS version:' + DriverInfo.getOSVersion());
     ok(true, 'Driver:' + DriverInfo.getDriver());