Bug 1060691 - Fix error message comparison test; a=kwierso
authorKyle Machulis <kyle@nonpolynomial.com>
Fri, 29 Aug 2014 18:09:46 -0700
changeset 224301 40d152f640df86e24820891eb34149964fdaab55
parent 224300 e0fb09d7b65f7b84eb7a5e3d8d5673818cec81cd
child 224302 e38f8e204c23d64ddacee56df5b6caa5363e588f
push id3979
push userraliiev@mozilla.com
push dateMon, 13 Oct 2014 16:35:44 +0000
treeherdermozilla-beta@30f2cc610691 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewerskwierso
bugs1060691
milestone34.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 1060691 - Fix error message comparison test; a=kwierso
dom/settings/tests/test_settings_permissions.html
--- a/dom/settings/tests/test_settings_permissions.html
+++ b/dom/settings/tests/test_settings_permissions.html
@@ -133,16 +133,18 @@ var steps = [
       next();
     }
     req.onsuccess = onFailure;
   },
   function () {
     ok(true, "All requests on a failed lock should fail");
     var lock = mozSettings.createLock();
     lock.onsettingstransactionfailure = function (evt) {
+      // Stop listening at this point
+      lock.onsettingstransactionfailure = null;
       ok(evt.error == "Lock failed a permissions check, all requests now failing.", "transaction failure on permissions error message correct.");
       ok(true, "transaction failed (expected) ");
       next();
     };
     lock.onsettingstransactionsuccess = onFailure;
 
     req = lock.set(wifi);
     req.onerror = function () {
@@ -161,26 +163,16 @@ var steps = [
     req = lock.set(combination);
     req.onerror = function () {
       ok(true, "set failed (expected)");
       next();
     }
     req.onsuccess = onFailure;
   },
   function () {
-    ok(true, "Set combination (1 valid 1 not valid)");
-    var lock = mozSettings.createLock();
-    req = lock.set(combination);
-    req.onerror = function () {
-      ok(true, "set failed (expected)");
-      next();
-    }
-    req.onsuccess = onFailure;
-  },
-  function () {
     ok(true, "all done!\n");
     SimpleTest.finish();
   }
 ];
 
 function next() {
   ok(true, "Begin!");
   if (index >= steps.length) {