Bug 1462564 - Remove memory DAMP tests. r=yulia
MozReview-Commit-ID: BWXyPnriTcR
--- a/testing/talos/talos/tests/devtools/addon/content/damp-tests.js
+++ b/testing/talos/talos/tests/devtools/addon/content/damp-tests.js
@@ -44,20 +44,16 @@ window.DAMP_TESTS = [
}, {
name: "simple.performance",
path: "performance/simple.js",
description: "Measure open/close toolbox on performance panel against simple document"
}, {
name: "simple.netmonitor",
path: "netmonitor/simple.js",
description: "Measure open/close toolbox on network monitor panel against simple document"
- }, {
- name: "simple.memory",
- path: "memory/simple.js",
- description: "Measure open/close toolbox on memory panel and save/read heap snapshot against simple document"
},
// Run all tests against "complicated" document
{
name: "complicated.webconsole",
path: "webconsole/complicated.js",
description: "Measure open/close toolbox on webconsole panel against complicated document"
}, {
name: "complicated.inspector",
@@ -74,20 +70,16 @@ window.DAMP_TESTS = [
}, {
name: "complicated.performance",
path: "performance/complicated.js",
description: "Measure open/close toolbox on performance panel against complicated document"
}, {
name: "complicated.netmonitor",
path: "netmonitor/complicated.js",
description: "Measure open/close toolbox on network monitor panel against complicated document"
- }, {
- name: "complicated.memory",
- path: "memory/complicated.js",
- description: "Measure open/close toolbox on memory panel and save/read heap snapshot against complicated document"
},
// Run all tests against a document specific to each tool
{
name: "custom.webconsole",
path: "webconsole/custom.js"
}, {
name: "custom.inspector",
path: "inspector/custom.js"
deleted file mode 100644
--- a/testing/talos/talos/tests/devtools/addon/content/tests/memory/complicated.js
+++ /dev/null
@@ -1,24 +0,0 @@
-/* This Source Code Form is subject to the terms of the Mozilla Public
- * License, v. 2.0. If a copy of the MPL was not distributed with this
- * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
-
-"use strict";
-
-const { openToolboxAndLog, closeToolboxAndLog, reloadPageAndLog, testSetup,
- testTeardown, COMPLICATED_URL } = require("../head");
-const { saveHeapSnapshot, readHeapSnapshot, takeCensus } = require("./memory-helpers");
-
-module.exports = async function() {
- await testSetup(COMPLICATED_URL);
-
- const toolbox = await openToolboxAndLog("complicated.memory", "memory");
- await reloadPageAndLog("complicated.memory", toolbox);
-
- let heapSnapshotFilePath = await saveHeapSnapshot("complicated");
- let snapshot = await readHeapSnapshot("complicated", heapSnapshotFilePath);
- await takeCensus("complicated", snapshot);
-
- await closeToolboxAndLog("complicated.memory", toolbox);
- await testTeardown();
-};
-
deleted file mode 100644
--- a/testing/talos/talos/tests/devtools/addon/content/tests/memory/memory-helpers.js
+++ /dev/null
@@ -1,58 +0,0 @@
-/* This Source Code Form is subject to the terms of the Mozilla Public
- * License, v. 2.0. If a copy of the MPL was not distributed with this
- * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
-
-"use strict";
-
-const { getToolbox, runTest } = require("../head");
-
-exports.saveHeapSnapshot = async function(label) {
- let toolbox = getToolbox();
- let panel = toolbox.getCurrentPanel();
- let memoryFront = panel.panelWin.gFront;
-
- let test = runTest(label + ".saveHeapSnapshot");
- let heapSnapshotFilePath = await memoryFront.saveHeapSnapshot();
- test.done();
-
- return heapSnapshotFilePath;
-};
-
-exports.readHeapSnapshot = function(label, snapshotFilePath) {
- const ChromeUtils = require("ChromeUtils");
- let test = runTest(label + ".readHeapSnapshot");
- let snapshot = ChromeUtils.readHeapSnapshot(snapshotFilePath);
- test.done();
-
- return Promise.resolve(snapshot);
-};
-
-exports.takeCensus = function(label, snapshot) {
- let test = runTest("complicated.takeCensus");
- snapshot.takeCensus({
- breakdown: {
- by: "coarseType",
- objects: {
- by: "objectClass",
- then: { by: "count", bytes: true, count: true },
- other: { by: "count", bytes: true, count: true }
- },
- strings: {
- by: "internalType",
- then: { by: "count", bytes: true, count: true }
- },
- scripts: {
- by: "internalType",
- then: { by: "count", bytes: true, count: true }
- },
- other: {
- by: "internalType",
- then: { by: "count", bytes: true, count: true }
- }
- }
- });
-
- test.done();
-
- return Promise.resolve();
-};
deleted file mode 100644
--- a/testing/talos/talos/tests/devtools/addon/content/tests/memory/simple.js
+++ /dev/null
@@ -1,24 +0,0 @@
-/* This Source Code Form is subject to the terms of the Mozilla Public
- * License, v. 2.0. If a copy of the MPL was not distributed with this
- * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
-
-"use strict";
-
-const { openToolboxAndLog, closeToolboxAndLog, reloadPageAndLog, testSetup,
- testTeardown, SIMPLE_URL } = require("../head");
-const { saveHeapSnapshot, readHeapSnapshot, takeCensus } = require("./memory-helpers");
-
-module.exports = async function() {
- await testSetup(SIMPLE_URL);
-
- const toolbox = await openToolboxAndLog("simple.memory", "memory");
- await reloadPageAndLog("simple.memory", toolbox);
-
- let heapSnapshotFilePath = await saveHeapSnapshot("simple");
- let snapshot = await readHeapSnapshot("simple", heapSnapshotFilePath);
- await takeCensus("simple", snapshot);
-
- await closeToolboxAndLog("simple.memory", toolbox);
- await testTeardown();
-};
-