Bug 1374333 - Use TalosParentProfiler to fix profiling in damp tests. r?rwood
MozReview-Commit-ID: 6soeiMl2NXx
--- a/testing/talos/talos/tests/devtools/addon/content/damp.js
+++ b/testing/talos/talos/tests/devtools/addon/content/damp.js
@@ -491,28 +491,28 @@ Damp.prototype = {
window.on(EVENTS.NETWORK_EVENT, onRequest);
window.on(EVENTS.RECEIVED_EVENT_TIMINGS, onTimings);
});
},
startTest(doneCallback, config) {
this._onTestComplete = function(results) {
- Profiler.mark("DAMP - end", true);
+ TalosParentProfiler.pause("DAMP - end");
doneCallback(results);
};
this._config = config;
const Ci = Components.interfaces;
var wm = Components.classes["@mozilla.org/appshell/window-mediator;1"].getService(Ci.nsIWindowMediator);
this._win = wm.getMostRecentWindow("navigator:browser");
this._dampTab = this._win.gBrowser.selectedTab;
this._win.gBrowser.selectedBrowser.focus(); // Unfocus the URL bar to avoid caret blink
- Profiler.mark("DAMP - start", true);
+ TalosParentProfiler.resume("DAMP - start");
let tests = [];
tests = tests.concat(this._getToolLoadingTests(SIMPLE_URL, "simple"));
tests = tests.concat(this._getToolLoadingTests(COMPLICATED_URL, "complicated"));
if (config.subtests.indexOf("consoleBulkLogging") > -1) {
tests = tests.concat(this._consoleBulkLoggingTest);
}
--- a/testing/talos/talos/tests/devtools/addon/content/damp.overlay.xul
+++ b/testing/talos/talos/tests/devtools/addon/content/damp.overlay.xul
@@ -1,12 +1,12 @@
<?xml version="1.0"?>
<overlay id="Scrapper-Overlay" xmlns="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul">
-<script type="application/x-javascript" src="Profiler.js" />
+<script type="application/x-javascript" src="chrome://talos-powers-content/content/TalosParentProfiler.js" />
<script type="application/x-javascript" src="damp.js" />
<script type="application/x-javascript">
(function(){
const Cc = Components.classes;
const Ci = Components.interfaces;
var prefs = Cc["@mozilla.org/preferences-service;1"].getService(Ci.nsIPrefBranch);