Bug 1687263: part 2) Add `NodeOffsetRange::operator==(const nsRange& aRange)`. r...
[gecko.git] / testing / performance / perftest_android_view.js
blob50e4dce85ea0bb4b2f171fad6f3fd1f85b0bed59
1 // This Source Code Form is subject to the terms of the Mozilla Public
2 // License, v. 2.0. If a copy of the MPL was not distributed with this
3 // file, You can obtain one at http://mozilla.org/MPL/2.0/.
4 /* eslint-env node */
5 "use strict";
7 async function test(context, commands) {
8   await commands.measure.start();
9   await commands.measure.browser.wait(commands.measure.pageCompleteCheck);
10   await commands.measure.stop();
12   const browserScripts = commands.measure.result[0].browserScripts;
14   const processLaunchToNavStart =
15     browserScripts.pageinfo.navigationStartTime -
16     browserScripts.browser.processStartTime;
18   browserScripts.pageinfo.processLaunchToNavStart = processLaunchToNavStart;
19   console.log("processLaunchToNavStart: " + processLaunchToNavStart);
21   return true;
24 module.exports = {
25   test,
26   owner: "Performance Team",
27   name: "VIEW",
28   description: "Measures cold process view time",
29   longDescription: `
30   This test launches the appropriate android app, simulating a opening a link through VIEW intent
31   workflow. The application is launched with the intent action
32   android.intent.action.VIEW loading a trivially simple website. The reported
33   metric is the time from process start to navigationStart, reported as processLaunchToNavStart
34   `,
35   usage: `
36   ./mach perftest testing/performance/perftest_android_view.js \
37     --android-install-apk ~/fenix.v2.fennec-nightly.2020.04.22-arm32.apk \
38     --hooks testing/performance/hooks_android_view.py \
39     --android-app-name org.mozilla.fenix \
40     --perfherder-metrics processLaunchToNavStart
41   `,
42   supportedBrowsers: ["Fenix nightly", "Geckoview_example", "Fennec"],
43   supportedPlatforms: ["Android"],