Backed out changeset dbd03e7e1bc5 (bug 1359855)
authorCarsten "Tomcat" Book <cbook@mozilla.com>
Mon, 24 Jul 2017 12:07:11 +0200
changeset 370545 5c5cd7954f5ce97a1d08dcb32b07c1b4d56b8411
parent 370544 263f0b999ae1239dc1850c528a9f80b4949fc52a
child 370546 e2e44c6b518051dbef072742e8adf70839180713
push id32227
push userkwierso@gmail.com
push dateTue, 25 Jul 2017 00:58:03 +0000
treeherdermozilla-central@f6528783c525 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
bugs1359855
milestone56.0a1
backs outdbd03e7e1bc5aad3148a1b1ef69361bf30e041ef
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
Backed out changeset dbd03e7e1bc5 (bug 1359855)
devtools/client/framework/test/browser_toolbox_dynamic_registration.js
--- a/devtools/client/framework/test/browser_toolbox_dynamic_registration.js
+++ b/devtools/client/framework/test/browser_toolbox_dynamic_registration.js
@@ -21,16 +21,17 @@ function testRegister(aToolbox)
   gDevTools.once("tool-registered", toolRegistered);
 
   gDevTools.registerTool({
     id: "test-tool",
     label: "Test Tool",
     inMenu: true,
     isTargetSupported: () => true,
     build: function () {},
+    key: "t"
   });
 }
 
 function toolRegistered(event, toolId)
 {
   is(toolId, "test-tool", "tool-registered event handler sent tool id");
 
   ok(gDevTools.getToolDefinitionMap().has(toolId), "tool added to map");
@@ -39,16 +40,18 @@ function toolRegistered(event, toolId)
   let doc = toolbox.doc;
   let tab = doc.getElementById("toolbox-tab-" + toolId);
   ok(tab, "new tool's tab exists in toolbox UI");
 
   let panel = doc.getElementById("toolbox-panel-" + toolId);
   ok(panel, "new tool's panel exists in toolbox UI");
 
   for (let win of getAllBrowserWindows()) {
+    let key = win.document.getElementById("key_" + toolId);
+    ok(key, "key for new tool added to every browser window");
     let menuitem = win.document.getElementById("menuitem_" + toolId);
     ok(menuitem, "menu item of new tool added to every browser window");
   }
 
   // then unregister it
   testUnregister();
 }
 
@@ -78,16 +81,18 @@ function toolUnregistered(event, toolId)
   let doc = toolbox.doc;
   let tab = doc.getElementById("toolbox-tab-" + toolId);
   ok(!tab, "tool's tab was removed from the toolbox UI");
 
   let panel = doc.getElementById("toolbox-panel-" + toolId);
   ok(!panel, "tool's panel was removed from toolbox UI");
 
   for (let win of getAllBrowserWindows()) {
+    let key = win.document.getElementById("key_" + toolId);
+    ok(!key, "key removed from every browser window");
     let menuitem = win.document.getElementById("menuitem_" + toolId);
     ok(!menuitem, "menu item removed from every browser window");
   }
 
   cleanup();
 }
 
 function cleanup()