Bug 1519455 - Fix browser_service_workers_push.js for sw-e10s refactor;r=daisuke
authorJulian Descottes <jdescottes@mozilla.com>
Wed, 13 Feb 2019 07:54:47 +0000
changeset 458871 e5f3e1584cf99bd8a020182d9b3ffa4211ea626b
parent 458870 93e37c529818028d26d1a0ff7ea46e6173b83c98
child 458872 23fa2fb048b999da8edede73f5fb3ce4913a9b9e
push id78071
push userjdescottes@mozilla.com
push dateWed, 13 Feb 2019 07:55:31 +0000
treeherderautoland@e5f3e1584cf9 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersdaisuke
bugs1519455
milestone67.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 1519455 - Fix browser_service_workers_push.js for sw-e10s refactor;r=daisuke Differential Revision: https://phabricator.services.mozilla.com/D19466
devtools/client/aboutdebugging/test/browser_service_workers_push.js
--- a/devtools/client/aboutdebugging/test/browser_service_workers_push.js
+++ b/devtools/client/aboutdebugging/test/browser_service_workers_push.js
@@ -41,16 +41,21 @@ add_task(async function() {
 
   info("Ensure that the registration resolved before trying to interact with " +
     "the service worker.");
   await waitForServiceWorkerRegistered(swTab);
   ok(true, "Service worker registration resolved");
 
   await waitForServiceWorkerActivation(SERVICE_WORKER, document);
 
+  info("Wait until the service worker is running");
+  const container = await waitUntilServiceWorkerContainer(SERVICE_WORKER, document);
+  await waitUntil(
+    () => container.querySelector(".target-status").textContent === "Running", 100);
+
   // Retrieve the Push button for the worker.
   const names = [...document.querySelectorAll("#service-workers .target-name")];
   const name = names.filter(element => element.textContent === SERVICE_WORKER)[0];
   ok(name, "Found the service worker in the list");
 
   const targetElement = name.parentNode.parentNode;
 
   const pushBtn = targetElement.querySelector(".push-button");