browsertime 20.0.0 → 21.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +23 -0
- package/README.md +2 -2
- package/bin/browsertime.js +9 -3
- package/browserscripts/pageinfo/interactionToNextPaintInfo.js +170 -143
- package/browserscripts/timings/interactionToNextPaint.js +49 -137
- package/lib/chrome/webdriver/setupChromiumOptions.js +0 -9
- package/lib/core/engine/collector.js +11 -0
- package/lib/core/engine/command/actions.js +52 -0
- package/lib/core/engine/command/addText.js +48 -30
- package/lib/core/engine/command/android.js +43 -4
- package/lib/core/engine/command/cache.js +39 -2
- package/lib/core/engine/command/chromeDevToolsProtocol.js +51 -1
- package/lib/core/engine/command/chromeTrace.js +34 -0
- package/lib/core/engine/command/click.js +102 -52
- package/lib/core/engine/command/debug.js +19 -2
- package/lib/core/engine/command/element.js +66 -0
- package/lib/core/engine/command/geckoProfiler.js +41 -1
- package/lib/core/engine/command/javaScript.js +43 -20
- package/lib/core/engine/command/measure.js +147 -15
- package/lib/core/engine/command/meta.js +17 -0
- package/lib/core/engine/command/mouse/clickAndHold.js +56 -29
- package/lib/core/engine/command/mouse/contextClick.js +30 -11
- package/lib/core/engine/command/mouse/doubleClick.js +35 -11
- package/lib/core/engine/command/mouse/mouseMove.js +38 -16
- package/lib/core/engine/command/mouse/singleClick.js +187 -12
- package/lib/core/engine/command/navigation.js +31 -3
- package/lib/core/engine/command/screenshot.js +33 -0
- package/lib/core/engine/command/scroll.js +35 -13
- package/lib/core/engine/command/select.js +55 -36
- package/lib/core/engine/command/set.js +51 -36
- package/lib/core/engine/command/stopWatch.js +30 -9
- package/lib/core/engine/command/switch.js +49 -11
- package/lib/core/engine/command/wait.js +50 -25
- package/lib/core/engine/commands.js +267 -0
- package/lib/core/engine/context.js +81 -0
- package/lib/core/engine/iteration.js +20 -102
- package/lib/firefox/geckoProfiler.js +49 -1
- package/lib/firefox/webdriver/builder.js +4 -9
- package/lib/firefox/webdriver/firefox.js +1 -1
- package/lib/support/cli.js +7 -0
- package/lib/support/statistics.js +11 -1
- package/package.json +17 -7
- package/types/android/index.d.ts +70 -0
- package/types/android/index.d.ts.map +1 -0
- package/types/chrome/parseCpuTrace.d.ts +21 -0
- package/types/chrome/parseCpuTrace.d.ts.map +1 -0
- package/types/chrome/traceCategoriesParser.d.ts +2 -0
- package/types/chrome/traceCategoriesParser.d.ts.map +1 -0
- package/types/chrome/webdriver/traceUtilities.d.ts +8 -0
- package/types/chrome/webdriver/traceUtilities.d.ts.map +1 -0
- package/types/core/engine/command/action.d.ts +73 -0
- package/types/core/engine/command/action.d.ts.map +1 -0
- package/types/core/engine/command/actions.d.ts +38 -0
- package/types/core/engine/command/actions.d.ts.map +1 -0
- package/types/core/engine/command/addText.d.ts +68 -0
- package/types/core/engine/command/addText.d.ts.map +1 -0
- package/types/core/engine/command/android.d.ts +39 -0
- package/types/core/engine/command/android.d.ts.map +1 -0
- package/types/core/engine/command/cache.d.ts +53 -0
- package/types/core/engine/command/cache.d.ts.map +1 -0
- package/types/core/engine/command/chromeDevToolsProtocol.d.ts +61 -0
- package/types/core/engine/command/chromeDevToolsProtocol.d.ts.map +1 -0
- package/types/core/engine/command/chromeTrace.d.ts +45 -0
- package/types/core/engine/command/chromeTrace.d.ts.map +1 -0
- package/types/core/engine/command/click.d.ts +151 -0
- package/types/core/engine/command/click.d.ts.map +1 -0
- package/types/core/engine/command/debug.d.ts +28 -0
- package/types/core/engine/command/debug.d.ts.map +1 -0
- package/types/core/engine/command/element.d.ts +49 -0
- package/types/core/engine/command/element.d.ts.map +1 -0
- package/types/core/engine/command/geckoProfiler.d.ts +46 -0
- package/types/core/engine/command/geckoProfiler.d.ts.map +1 -0
- package/types/core/engine/command/javaScript.d.ts +63 -0
- package/types/core/engine/command/javaScript.d.ts.map +1 -0
- package/types/core/engine/command/measure.d.ts +194 -0
- package/types/core/engine/command/measure.d.ts.map +1 -0
- package/types/core/engine/command/meta.d.ts +23 -0
- package/types/core/engine/command/meta.d.ts.map +1 -0
- package/types/core/engine/command/mouse/clickAndHold.d.ts +82 -0
- package/types/core/engine/command/mouse/clickAndHold.d.ts.map +1 -0
- package/types/core/engine/command/mouse/contextClick.d.ts +44 -0
- package/types/core/engine/command/mouse/contextClick.d.ts.map +1 -0
- package/types/core/engine/command/mouse/doubleClick.d.ts +51 -0
- package/types/core/engine/command/mouse/doubleClick.d.ts.map +1 -0
- package/types/core/engine/command/mouse/index.d.ts +6 -0
- package/types/core/engine/command/mouse/index.d.ts.map +1 -0
- package/types/core/engine/command/mouse/mouseMove.d.ts +56 -0
- package/types/core/engine/command/mouse/mouseMove.d.ts.map +1 -0
- package/types/core/engine/command/mouse/singleClick.d.ts +115 -0
- package/types/core/engine/command/mouse/singleClick.d.ts.map +1 -0
- package/types/core/engine/command/navigation.d.ts +45 -0
- package/types/core/engine/command/navigation.d.ts.map +1 -0
- package/types/core/engine/command/screenshot.d.ts +33 -0
- package/types/core/engine/command/screenshot.d.ts.map +1 -0
- package/types/core/engine/command/scroll.d.ts +52 -0
- package/types/core/engine/command/scroll.d.ts.map +1 -0
- package/types/core/engine/command/select.d.ts +81 -0
- package/types/core/engine/command/select.d.ts.map +1 -0
- package/types/core/engine/command/set.d.ts +74 -0
- package/types/core/engine/command/set.d.ts.map +1 -0
- package/types/core/engine/command/stopWatch.d.ts +49 -0
- package/types/core/engine/command/stopWatch.d.ts.map +1 -0
- package/types/core/engine/command/switch.d.ts +77 -0
- package/types/core/engine/command/switch.d.ts.map +1 -0
- package/types/core/engine/command/util/lcpHighlightScript.d.ts +2 -0
- package/types/core/engine/command/util/lcpHighlightScript.d.ts.map +1 -0
- package/types/core/engine/command/util/lsHighlightScript.d.ts +2 -0
- package/types/core/engine/command/util/lsHighlightScript.d.ts.map +1 -0
- package/types/core/engine/command/wait.d.ts +74 -0
- package/types/core/engine/command/wait.d.ts.map +1 -0
- package/types/core/engine/commands.d.ts +161 -0
- package/types/core/engine/commands.d.ts.map +1 -0
- package/types/core/engine/context.d.ts +87 -0
- package/types/core/engine/context.d.ts.map +1 -0
- package/types/firefox/geckoProfiler.d.ts +11 -0
- package/types/firefox/geckoProfiler.d.ts.map +1 -0
- package/types/firefox/settings/geckoProfilerDefaults.d.ts +8 -0
- package/types/firefox/settings/geckoProfilerDefaults.d.ts.map +1 -0
- package/types/scripting.d.ts +2 -0
- package/types/support/engineUtils.d.ts +5 -0
- package/types/support/engineUtils.d.ts.map +1 -0
- package/types/support/errors.d.ts +15 -0
- package/types/support/errors.d.ts.map +1 -0
- package/types/support/fileUtil.d.ts +10 -0
- package/types/support/fileUtil.d.ts.map +1 -0
- package/types/support/filters.d.ts +7 -0
- package/types/support/filters.d.ts.map +1 -0
- package/types/support/getViewPort.d.ts +2 -0
- package/types/support/getViewPort.d.ts.map +1 -0
- package/types/support/pathToFolder.d.ts +2 -0
- package/types/support/pathToFolder.d.ts.map +1 -0
- package/types/support/storageManager.d.ts +17 -0
- package/types/support/storageManager.d.ts.map +1 -0
- package/types/support/tcpdump.d.ts +10 -0
- package/types/support/tcpdump.d.ts.map +1 -0
- package/types/support/userTiming.d.ts +2 -0
- package/types/support/userTiming.d.ts.map +1 -0
- package/types/support/util.d.ts +6 -0
- package/types/support/util.d.ts.map +1 -0
- package/types/video/defaults.d.ts +7 -0
- package/types/video/defaults.d.ts.map +1 -0
- package/types/video/postprocessing/finetune/addTextToVideo.d.ts +2 -0
- package/types/video/postprocessing/finetune/addTextToVideo.d.ts.map +1 -0
- package/types/video/postprocessing/finetune/convertFps.d.ts +2 -0
- package/types/video/postprocessing/finetune/convertFps.d.ts.map +1 -0
- package/types/video/postprocessing/finetune/getFont.d.ts +2 -0
- package/types/video/postprocessing/finetune/getFont.d.ts.map +1 -0
- package/types/video/postprocessing/finetune/getTimingMetrics.d.ts +2 -0
- package/types/video/postprocessing/finetune/getTimingMetrics.d.ts.map +1 -0
- package/types/video/postprocessing/finetune/index.d.ts +2 -0
- package/types/video/postprocessing/finetune/index.d.ts.map +1 -0
- package/types/video/postprocessing/finetune/removeOrange.d.ts +2 -0
- package/types/video/postprocessing/finetune/removeOrange.d.ts.map +1 -0
- package/types/video/postprocessing/visualmetrics/extraMetrics.d.ts +5 -0
- package/types/video/postprocessing/visualmetrics/extraMetrics.d.ts.map +1 -0
- package/types/video/postprocessing/visualmetrics/getVideoMetrics.d.ts +5 -0
- package/types/video/postprocessing/visualmetrics/getVideoMetrics.d.ts.map +1 -0
- package/types/video/postprocessing/visualmetrics/visualMetrics.d.ts +3 -0
- package/types/video/postprocessing/visualmetrics/visualMetrics.d.ts.map +1 -0
- package/types/video/screenRecording/android/recorder.d.ts +11 -0
- package/types/video/screenRecording/android/recorder.d.ts.map +1 -0
- package/types/video/screenRecording/desktop/convert.d.ts +2 -0
- package/types/video/screenRecording/desktop/convert.d.ts.map +1 -0
- package/types/video/screenRecording/desktop/desktopRecorder.d.ts +28 -0
- package/types/video/screenRecording/desktop/desktopRecorder.d.ts.map +1 -0
- package/types/video/screenRecording/desktop/ffmpegRecorder.d.ts +17 -0
- package/types/video/screenRecording/desktop/ffmpegRecorder.d.ts.map +1 -0
- package/types/video/screenRecording/desktop/osx/getSPDisplaysDataType.d.ts +2 -0
- package/types/video/screenRecording/desktop/osx/getSPDisplaysDataType.d.ts.map +1 -0
- package/types/video/screenRecording/desktop/osx/getScreen.d.ts +2 -0
- package/types/video/screenRecording/desktop/osx/getScreen.d.ts.map +1 -0
- package/types/video/screenRecording/firefox/firefoxWindowRecorder.d.ts +13 -0
- package/types/video/screenRecording/firefox/firefoxWindowRecorder.d.ts.map +1 -0
- package/types/video/screenRecording/ios/convertToMp4.d.ts +2 -0
- package/types/video/screenRecording/ios/convertToMp4.d.ts.map +1 -0
- package/types/video/screenRecording/ios/iosRecorder.d.ts +14 -0
- package/types/video/screenRecording/ios/iosRecorder.d.ts.map +1 -0
- package/types/video/screenRecording/iosSimulator/convertToMp4.d.ts +2 -0
- package/types/video/screenRecording/iosSimulator/convertToMp4.d.ts.map +1 -0
- package/types/video/screenRecording/iosSimulator/recorder.d.ts +9 -0
- package/types/video/screenRecording/iosSimulator/recorder.d.ts.map +1 -0
- package/types/video/screenRecording/recorder.d.ts +7 -0
- package/types/video/screenRecording/recorder.d.ts.map +1 -0
- package/types/video/screenRecording/setOrangeBackground.d.ts +2 -0
- package/types/video/screenRecording/setOrangeBackground.d.ts.map +1 -0
- package/types/video/video.d.ts +41 -0
- package/types/video/video.d.ts.map +1 -0
- package/browsersupport/firefox-profile/cert9.db +0 -0
- package/browsersupport/firefox-profile/chrome/userChrome.css +0 -4
- package/browsersupport/firefox-profile/key4.db +0 -0
- package/vendor/mac/x86/qvh +0 -0
- package/visualmetrics/__init__.py +0 -1
- package/visualmetrics/test_data/ms_000000.png +0 -0
- package/visualmetrics/test_data/ms_000920.png +0 -0
- package/visualmetrics/test_data/ms_001000.png +0 -0
- package/visualmetrics/test_data/ms_001080.png +0 -0
- package/visualmetrics/test_data/ms_001200.png +0 -0
- package/visualmetrics/test_data/ms_001240.png +0 -0
- package/visualmetrics/test_data/ms_001280.png +0 -0
- package/visualmetrics/test_data/ms_001360.png +0 -0
- package/visualmetrics/test_data/ms_001400.png +0 -0
- package/visualmetrics/test_data/ms_001520.png +0 -0
- package/visualmetrics/test_data/ms_002040.png +0 -0
- package/visualmetrics/test_data/ms_002600.png +0 -0
- package/visualmetrics/test_data/ms_003160.png +0 -0
- package/visualmetrics/test_data/ms_003720.png +0 -0
- package/visualmetrics/test_data/ms_004280.png +0 -0
- package/visualmetrics/test_data/ms_004880.png +0 -0
- package/visualmetrics/test_data/ms_005440.png +0 -0
- package/visualmetrics/test_data/ms_006000.png +0 -0
- package/visualmetrics/test_visualmetrics.py +0 -34
|
@@ -0,0 +1,77 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Provides functionality to switch between frames, windows, and tabs in the browser.
|
|
3
|
+
*
|
|
4
|
+
* @class
|
|
5
|
+
* @hideconstructor
|
|
6
|
+
*/
|
|
7
|
+
export class Switch {
|
|
8
|
+
constructor(browser: any, pageCompleteCheck: any, navigate: any);
|
|
9
|
+
/**
|
|
10
|
+
* @private
|
|
11
|
+
*/
|
|
12
|
+
private browser;
|
|
13
|
+
/**
|
|
14
|
+
* @private
|
|
15
|
+
*/
|
|
16
|
+
private pageCompleteCheck;
|
|
17
|
+
/**
|
|
18
|
+
* @private
|
|
19
|
+
*/
|
|
20
|
+
private navigate;
|
|
21
|
+
/**
|
|
22
|
+
* Switches to a frame identified by its ID.
|
|
23
|
+
*
|
|
24
|
+
* @async
|
|
25
|
+
* @param {string|number} id - The ID of the frame.
|
|
26
|
+
* @throws {Error} Throws an error if switching to the frame fails.
|
|
27
|
+
*/
|
|
28
|
+
toFrame(id: string | number): Promise<void>;
|
|
29
|
+
/**
|
|
30
|
+
* Switches to a frame identified by an XPath.
|
|
31
|
+
*
|
|
32
|
+
* @async
|
|
33
|
+
* @param {string} xpath - The XPath of the frame element.
|
|
34
|
+
* @throws {Error} Throws an error if the frame is not found or switching fails.
|
|
35
|
+
*/
|
|
36
|
+
toFrameByXpath(xpath: string): Promise<void>;
|
|
37
|
+
/**
|
|
38
|
+
* Switches to a frame identified by a CSS selector.
|
|
39
|
+
*
|
|
40
|
+
* @async
|
|
41
|
+
* @param {string} selector - The CSS selector of the frame element.
|
|
42
|
+
* @throws {Error} Throws an error if the frame is not found or switching fails.
|
|
43
|
+
*/
|
|
44
|
+
toFrameBySelector(selector: string): Promise<void>;
|
|
45
|
+
/**
|
|
46
|
+
* Switches to a window identified by its name.
|
|
47
|
+
*
|
|
48
|
+
* @async
|
|
49
|
+
* @param {string} name - The name of the window.
|
|
50
|
+
* @throws {Error} Throws an error if switching to the window fails.
|
|
51
|
+
*/
|
|
52
|
+
toWindow(name: string): Promise<void>;
|
|
53
|
+
/**
|
|
54
|
+
* Switches to the parent frame of the current frame.
|
|
55
|
+
*
|
|
56
|
+
* @async
|
|
57
|
+
* @throws {Error} Throws an error if switching to the parent frame fails.
|
|
58
|
+
*/
|
|
59
|
+
toParentFrame(): Promise<void>;
|
|
60
|
+
/**
|
|
61
|
+
* Opens a new tab and optionally navigates to a URL.
|
|
62
|
+
*
|
|
63
|
+
* @async
|
|
64
|
+
* @param {string} [url] - Optional URL to navigate to in the new tab.
|
|
65
|
+
* @throws {Error} Throws an error if opening a new tab fails.
|
|
66
|
+
*/
|
|
67
|
+
toNewTab(url?: string): Promise<void>;
|
|
68
|
+
/**
|
|
69
|
+
* Opens a new window and optionally navigates to a URL.
|
|
70
|
+
*
|
|
71
|
+
* @async
|
|
72
|
+
* @param {string} [url] - Optional URL to navigate to in the new window.
|
|
73
|
+
* @throws {Error} Throws an error if opening a new window fails.
|
|
74
|
+
*/
|
|
75
|
+
toNewWindow(url?: string): Promise<void>;
|
|
76
|
+
}
|
|
77
|
+
//# sourceMappingURL=switch.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"switch.d.ts","sourceRoot":"","sources":["../../../../lib/core/engine/command/switch.js"],"names":[],"mappings":"AAIA;;;;;GAKG;AACH;IACE,iEAaC;IAZC;;OAEG;IACH,gBAAsB;IACtB;;OAEG;IACH,0BAA0C;IAC1C;;OAEG;IACH,iBAAwB;IAG1B;;;;;;OAMG;IACH,YAHW,MAAM,GAAC,MAAM,iBAYvB;IAED;;;;;;OAMG;IACH,sBAHW,MAAM,iBAkBhB;IAED;;;;;;OAMG;IACH,4BAHW,MAAM,iBAkBhB;IAED;;;;;;OAMG;IACH,eAHW,MAAM,iBAYhB;IAED;;;;;OAKG;IACH,+BASC;IAED;;;;;;OAMG;IACH,eAHW,MAAM,iBAiBhB;IAED;;;;;;OAMG;IACH,kBAHW,MAAM,iBAiBhB;CACF"}
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
export const lcpHighlightScript: "\nreturn (function(color) {\n const observer = new PerformanceObserver(list => {});\n observer.observe({ type: 'largest-contentful-paint', buffered: true });\n const entries = observer.takeRecords();\n if (entries.length > 0) {\n const largestEntry = entries[entries.length - 1];\n // There could be cases where we do not get an element\n if (largestEntry.element) {\n const clientRect = largestEntry.element.getBoundingClientRect();\n\n const canvas = document.createElement('canvas'); //Create a canvas element\n canvas.style.width='100%';\n canvas.style.height='100%';\n canvas.width = window.innerWidth;\n canvas.height = window.innerHeight;\n canvas.style.position='absolute';\n canvas.style.left=0;\n canvas.style.top=0;\n canvas.style.zIndex=2147483646;\n canvas.id = \"browsertime-lcp\";\n document.body.appendChild(canvas); \n const context = canvas.getContext('2d');\n context.rect(Math.max(0,clientRect.x), Math.max(0,clientRect.y), Math.min(clientRect.width, window.innerWidth - clientRect.x) , Math.min(clientRect.height, window.innerHeight-clientRect.y));\n context.lineWidth = \"6\";\n context.strokeStyle = color;\n context.stroke();\n\n context.fillStyle = color;\n context.globalAlpha = 0.1;\n context.rect(Math.max(0,clientRect.x), Math.max(0,clientRect.y), Math.min(clientRect.width, window.innerWidth - clientRect.x) , Math.min(clientRect.height, window.innerHeight-clientRect.y));\n context.fill();\n return '';\n } else {\n return 'No element attached to the entry in largest-contentful-paint';\n }\n } else {\n return 'Chrome did not report any largest-contentful-paint';\n }\n})(arguments[arguments.length - 1]);\n";
|
|
2
|
+
//# sourceMappingURL=lcpHighlightScript.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"lcpHighlightScript.d.ts","sourceRoot":"","sources":["../../../../../lib/core/engine/command/util/lcpHighlightScript.js"],"names":[],"mappings":"AAAA,o8DAwCE"}
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
export const clsHighlightScript: "\n(function(options) {\n const rectColor = options.color;\n const limit = options.limit;\n const observer = new PerformanceObserver(list => {});\n observer.observe({ type: 'layout-shift', buffered: true });\n const entries = observer.takeRecords();\n if (entries.length > 0) {\n const canvas = document.createElement('canvas'); \n canvas.style.width='100%';\n canvas.style.height='100%';\n canvas.width = window.innerWidth;\n canvas.height = window.innerHeight;\n canvas.style.position='absolute';\n canvas.style.left=0;\n canvas.style.top=0;\n canvas.style.zIndex=2147483646;\n canvas.id = \"browsertime-ls\";\n document.body.appendChild(canvas);\n\n function paintRectangle(context, clientRect, color) { \n context.fillStyle = color;\n context.globalAlpha = 0.03;\n context.rect(Math.max(0,clientRect.x), Math.max(0,clientRect.y), Math.min(clientRect.width, window.innerWidth - clientRect.x) , Math.min(clientRect.height, window.innerHeight-clientRect.y));\n context.fill();\n\n\n context.strokeStyle = color;\n context.globalAlpha = 1.0;\n context.rect(Math.max(0,clientRect.x), Math.max(0,clientRect.y), Math.min(clientRect.width, window.innerWidth - clientRect.x) , Math.min(clientRect.height, window.innerHeight-clientRect.y));\n context.stroke();\n }\n\n let maxSessionGap1sLimit5s = {}; \n let max = 0; \n let current = [];\n let curr = 0; \n let firstTs = Number.NEGATIVE_INFINITY;\n let prevTs = Number.NEGATIVE_INFINITY;\n\n for (let entry of entries) {\n if (entry.hadRecentInput || entry.value <= limit) {\n continue;\n } \n if (entry.startTime - firstTs > 5000 || entry.startTime - prevTs > 1000) {\n firstTs = entry.startTime;\n curr = 0;\n maxSessionGap1sLimit5s[max] = [...current];\n current = []; \n }\n prevTs = entry.startTime;\n curr += entry.value;\n max = Math.max(max, curr);\n current.push(entry);\n }\n\n for (let entry of maxSessionGap1sLimit5s[max] || current) {\n for (let source of entry.sources) {\n if (source.previousRect && source.currentRect) {\n const context = canvas.getContext('2d');\n \n // paintRectangle(context, source.previousRect, \"yellow\", false);\n paintRectangle(context, source.currentRect, rectColor);\n \n context.font = \"bolder 24px Arial\";\n context.fillStyle = \"black\";\n context.fillText(entry.value.toFixed(4), Math.max(0,source.currentRect.x) + 24,Math.max(0,source.currentRect.y) + 24);\n\n }\n }\n }\n }\n})(arguments[arguments.length - 1]);\n";
|
|
2
|
+
//# sourceMappingURL=lsHighlightScript.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"lsHighlightScript.d.ts","sourceRoot":"","sources":["../../../../../lib/core/engine/command/util/lsHighlightScript.js"],"names":[],"mappings":"AAAA,0+FAyEE"}
|
|
@@ -0,0 +1,74 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Provides functionality to wait for different conditions in the browser.
|
|
3
|
+
*
|
|
4
|
+
* @class
|
|
5
|
+
* @hideconstructor
|
|
6
|
+
*/
|
|
7
|
+
export class Wait {
|
|
8
|
+
constructor(browser: any, pageCompleteCheck: any);
|
|
9
|
+
/**
|
|
10
|
+
* @private
|
|
11
|
+
*/
|
|
12
|
+
private browser;
|
|
13
|
+
/**
|
|
14
|
+
* @private
|
|
15
|
+
*/
|
|
16
|
+
private pageCompleteCheck;
|
|
17
|
+
/**
|
|
18
|
+
* Waits for an element with a specific ID to appear within a maximum time.
|
|
19
|
+
*
|
|
20
|
+
* @async
|
|
21
|
+
* @param {string} id - The ID of the element to wait for.
|
|
22
|
+
* @param {number} maxTime - Maximum time to wait in milliseconds.
|
|
23
|
+
* @returns {Promise<void>} A promise that resolves when the element is found or the time times out.
|
|
24
|
+
* @throws {Error} Throws an error if the element is not found within the specified time.
|
|
25
|
+
*/
|
|
26
|
+
byId(id: string, maxTime: number): Promise<void>;
|
|
27
|
+
/**
|
|
28
|
+
* Waits for an element located by XPath to appear within a maximum time.
|
|
29
|
+
*
|
|
30
|
+
* @async
|
|
31
|
+
* @param {string} xpath - The XPath of the element to wait for.
|
|
32
|
+
* @param {number} maxTime - Maximum time to wait in milliseconds.
|
|
33
|
+
* @returns {Promise<void>} A promise that resolves when the element is found or the time times out.
|
|
34
|
+
* @throws {Error} Throws an error if the element is not found within the specified time.
|
|
35
|
+
*/
|
|
36
|
+
byXpath(xpath: string, maxTime: number): Promise<void>;
|
|
37
|
+
/**
|
|
38
|
+
* Waits for an element located by a CSS selector to appear within a maximum time.
|
|
39
|
+
*
|
|
40
|
+
* @async
|
|
41
|
+
* @param {string} selector - The CSS selector of the element to wait for.
|
|
42
|
+
* @param {number} maxTime - Maximum time to wait in milliseconds.
|
|
43
|
+
* @returns {Promise<void>} A promise that resolves when the element is found or the time times out.
|
|
44
|
+
* @throws {Error} Throws an error if the element is not found within the specified time.
|
|
45
|
+
*/
|
|
46
|
+
bySelector(selector: string, maxTime: number): Promise<void>;
|
|
47
|
+
/**
|
|
48
|
+
* Waits for a specified amount of time.
|
|
49
|
+
*
|
|
50
|
+
* @async
|
|
51
|
+
* @example async commands.wait.byTime(1000);
|
|
52
|
+
* @param {number} ms - The time in milliseconds to wait.
|
|
53
|
+
* @returns {Promise<void>} A promise that resolves when the specified time has elapsed.
|
|
54
|
+
*/
|
|
55
|
+
byTime(ms: number): Promise<void>;
|
|
56
|
+
/**
|
|
57
|
+
* Waits for the page to finish loading.
|
|
58
|
+
* @async
|
|
59
|
+
* @example async commands.wait.byPageToComplete();
|
|
60
|
+
* @returns {Promise<void>} A promise that resolves when the page complete check has finished.
|
|
61
|
+
*/
|
|
62
|
+
byPageToComplete(): Promise<void>;
|
|
63
|
+
/**
|
|
64
|
+
* Waits for a JavaScript condition to return a truthy value within a maximum time.
|
|
65
|
+
*
|
|
66
|
+
* @async
|
|
67
|
+
* @param {string} jsExpression - The JavaScript expression to evaluate.
|
|
68
|
+
* @param {number} maxTime - Maximum time to wait in milliseconds.
|
|
69
|
+
* @returns {Promise<void>} A promise that resolves when the condition becomes truthy or the time times out.
|
|
70
|
+
* @throws {Error} Throws an error if the condition is not met within the specified time.
|
|
71
|
+
*/
|
|
72
|
+
byCondition(jsExpression: string, maxTime: number): Promise<void>;
|
|
73
|
+
}
|
|
74
|
+
//# sourceMappingURL=wait.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"wait.d.ts","sourceRoot":"","sources":["../../../../lib/core/engine/command/wait.js"],"names":[],"mappings":"AAKA;;;;;GAKG;AACH;IACE,kDASC;IARC;;OAEG;IACH,gBAAsB;IACtB;;OAEG;IACH,0BAA0C;IAG5C;;;;;;;;OAQG;IACH,SALW,MAAM,WACN,MAAM,GACJ,QAAQ,IAAI,CAAC,CAiBzB;IAED;;;;;;;;OAQG;IACH,eALW,MAAM,WACN,MAAM,GACJ,QAAQ,IAAI,CAAC,CAmBzB;IAED;;;;;;;;OAQG;IACH,qBALW,MAAM,WACN,MAAM,GACJ,QAAQ,IAAI,CAAC,CAuBzB;IAED;;;;;;;OAOG;IACH,WAHW,MAAM,GACJ,QAAQ,IAAI,CAAC,CAIzB;IAED;;;;;OAKG;IACH,oBAFa,QAAQ,IAAI,CAAC,CAIzB;IAED;;;;;;;;OAQG;IACH,0BALW,MAAM,WACN,MAAM,GACJ,QAAQ,IAAI,CAAC,CAiBzB;CACF"}
|
|
@@ -0,0 +1,161 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Represents the set of commands available in a Browsertime script.
|
|
3
|
+
* @hideconstructor
|
|
4
|
+
*/
|
|
5
|
+
export class Commands {
|
|
6
|
+
constructor(browser: any, engineDelegate: any, index: any, result: any, storageManager: any, pageCompleteCheck: any, extensionServer: any, context: any, videos: any, screenshotManager: any, scriptsByCategory: any, asyncScriptsByCategory: any, postURLScripts: any, options: any);
|
|
7
|
+
profiler: GeckoProfilerCommand;
|
|
8
|
+
/**
|
|
9
|
+
* Manages Chrome trace functionality, enabling custom profiling and trace collection in Chrome.
|
|
10
|
+
* @type {ChromeTrace}
|
|
11
|
+
*/
|
|
12
|
+
trace: ChromeTrace;
|
|
13
|
+
/**
|
|
14
|
+
* Provides functionality to perform click actions on elements in a web page using various selectors.
|
|
15
|
+
* @type {Click}
|
|
16
|
+
*/
|
|
17
|
+
click: Click;
|
|
18
|
+
/**
|
|
19
|
+
* Provides functionality to control page scrolling in the browser.
|
|
20
|
+
* @type {Scroll}
|
|
21
|
+
*/
|
|
22
|
+
scroll: Scroll;
|
|
23
|
+
/**
|
|
24
|
+
* Provides functionality to add text to elements on a web page using various selectors.
|
|
25
|
+
* @type {AddText}
|
|
26
|
+
*/
|
|
27
|
+
addText: AddText;
|
|
28
|
+
/**
|
|
29
|
+
* Provides functionality to wait for different conditions in the browser.
|
|
30
|
+
* @type {Wait}
|
|
31
|
+
*/
|
|
32
|
+
wait: Wait;
|
|
33
|
+
/**
|
|
34
|
+
* Provides functionality for measuring a navigation.
|
|
35
|
+
* @type {Measure}
|
|
36
|
+
*/
|
|
37
|
+
measure: Measure;
|
|
38
|
+
/**
|
|
39
|
+
* Navigates to a specified URL and handles additional setup for a page visit.
|
|
40
|
+
* @async
|
|
41
|
+
* @example await commands.navigate('https://www.example.org');
|
|
42
|
+
* @type {Function}
|
|
43
|
+
* @param {string} url - The URL to navigate to.
|
|
44
|
+
* @throws {Error} Throws an error if navigation or setup fails.
|
|
45
|
+
* @returns {Promise<void>} A promise that resolves when the navigation and setup are
|
|
46
|
+
*/
|
|
47
|
+
navigate: Function;
|
|
48
|
+
/**
|
|
49
|
+
* Provides functionality to control browser navigation such as back, forward, and refresh actions.
|
|
50
|
+
* @type {Navigation}
|
|
51
|
+
*/
|
|
52
|
+
navigation: Navigation;
|
|
53
|
+
/**
|
|
54
|
+
* Add a text that will be an error attached to the current page.
|
|
55
|
+
* @example await commands.error('My error message');
|
|
56
|
+
* @param {string} message - The error message.
|
|
57
|
+
* @type {Function}
|
|
58
|
+
*/
|
|
59
|
+
error: Function;
|
|
60
|
+
/**
|
|
61
|
+
* Mark this run as an failure. Add a message that explains the failure.
|
|
62
|
+
* @example await commands.markAsFailure('My failure message');
|
|
63
|
+
* @param {string} message - The message attached as a failure
|
|
64
|
+
* @type {Function}
|
|
65
|
+
*/
|
|
66
|
+
markAsFailure: Function;
|
|
67
|
+
/**
|
|
68
|
+
* Executes JavaScript in the browser context.
|
|
69
|
+
* @type {JavaScript}
|
|
70
|
+
*/
|
|
71
|
+
js: JavaScript;
|
|
72
|
+
/**
|
|
73
|
+
* Switches context to different frames, windows, or tabs in the browser.
|
|
74
|
+
* @type {Switch}
|
|
75
|
+
*/
|
|
76
|
+
switch: Switch;
|
|
77
|
+
/**
|
|
78
|
+
* Sets values on HTML elements in the page.
|
|
79
|
+
* @type {Set}
|
|
80
|
+
*/
|
|
81
|
+
set: Set;
|
|
82
|
+
/**
|
|
83
|
+
* Stopwatch utility for measuring time intervals.
|
|
84
|
+
* @type {StopWatch}
|
|
85
|
+
*/
|
|
86
|
+
stopWatch: StopWatch;
|
|
87
|
+
/**
|
|
88
|
+
* Manages the browser's cache.
|
|
89
|
+
* @type {Cache}
|
|
90
|
+
*/
|
|
91
|
+
cache: Cache;
|
|
92
|
+
/**
|
|
93
|
+
* Adds metadata to the user journey.
|
|
94
|
+
* @type {Meta}
|
|
95
|
+
*/
|
|
96
|
+
meta: Meta;
|
|
97
|
+
/**
|
|
98
|
+
* Takes and manages screenshots.
|
|
99
|
+
* @type {Screenshot}
|
|
100
|
+
*/
|
|
101
|
+
screenshot: Screenshot;
|
|
102
|
+
/**
|
|
103
|
+
* Use the Chrome DevTools Protocol, available in Chrome and Edge.
|
|
104
|
+
* @type {ChromeDevelopmentToolsProtocol}
|
|
105
|
+
*/
|
|
106
|
+
cdp: ChromeDevelopmentToolsProtocol;
|
|
107
|
+
/**
|
|
108
|
+
* Provides commands for interacting with an Android device.
|
|
109
|
+
* @type {AndroidCommand}
|
|
110
|
+
*/
|
|
111
|
+
android: AndroidCommand;
|
|
112
|
+
/**
|
|
113
|
+
* Provides debugging capabilities within a browser automation script.
|
|
114
|
+
* It allows setting breakpoints to pause script execution and inspect the current state.
|
|
115
|
+
* @type {Debug}
|
|
116
|
+
*/
|
|
117
|
+
debug: Debug;
|
|
118
|
+
/**
|
|
119
|
+
* Interact with the page using the mouse.
|
|
120
|
+
* @type {Object}
|
|
121
|
+
*/
|
|
122
|
+
mouse: any;
|
|
123
|
+
/**
|
|
124
|
+
* Interact with a select element.
|
|
125
|
+
* @type {Select}
|
|
126
|
+
*/
|
|
127
|
+
select: Select;
|
|
128
|
+
/**
|
|
129
|
+
* Selenium's action sequence functionality.
|
|
130
|
+
* @type {Actions}
|
|
131
|
+
* @see https://www.selenium.dev/documentation/webdriver/actions_api/
|
|
132
|
+
*/
|
|
133
|
+
action: Actions;
|
|
134
|
+
/**
|
|
135
|
+
* Get Selenium's WebElements.
|
|
136
|
+
* @type {Element}
|
|
137
|
+
*/
|
|
138
|
+
element: Element;
|
|
139
|
+
}
|
|
140
|
+
import { GeckoProfiler as GeckoProfilerCommand } from './command/geckoProfiler.js';
|
|
141
|
+
import { ChromeTrace } from './command/chromeTrace.js';
|
|
142
|
+
import { Click } from './command/click.js';
|
|
143
|
+
import { Scroll } from './command/scroll.js';
|
|
144
|
+
import { AddText } from './command/addText.js';
|
|
145
|
+
import { Wait } from './command/wait.js';
|
|
146
|
+
import { Measure } from './command/measure.js';
|
|
147
|
+
import { Navigation } from './command/navigation.js';
|
|
148
|
+
import { JavaScript } from './command/javaScript.js';
|
|
149
|
+
import { Switch } from './command/switch.js';
|
|
150
|
+
import { Set } from './command/set.js';
|
|
151
|
+
import { Watch as StopWatch } from './command/stopWatch.js';
|
|
152
|
+
import { Cache } from './command/cache.js';
|
|
153
|
+
import { Meta } from './command/meta.js';
|
|
154
|
+
import { Screenshot } from './command/screenshot.js';
|
|
155
|
+
import { ChromeDevelopmentToolsProtocol } from './command/chromeDevToolsProtocol.js';
|
|
156
|
+
import { AndroidCommand } from './command/android.js';
|
|
157
|
+
import { Debug } from './command/debug.js';
|
|
158
|
+
import { Select } from './command/select.js';
|
|
159
|
+
import { Actions } from './command/actions.js';
|
|
160
|
+
import { Element } from './command/element.js';
|
|
161
|
+
//# sourceMappingURL=commands.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"commands.d.ts","sourceRoot":"","sources":["../../../lib/core/engine/commands.js"],"names":[],"mappings":"AA6BA;;;GAGG;AACH;IACE,sRAuOC;IApMC,+BAMC;IAMD;;;OAGG;IACH,OAFU,WAAW,CAE+C;IAEpE;;;OAGG;IACH,OAFU,KAAK,CAEmC;IAElD;;;OAGG;IACH,QAFU,MAAM,CAE0B;IAE1C;;;OAGG;IACH,SAFU,OAAO,CAEkB;IAEnC;;;OAGG;IACH,MAFU,IAAI,CAEkC;IAEhD;;;OAGG;IACH,SAFU,OAAO,CAEK;IAEtB;;;;;;;;OAQG;IACH,mBAA+C;IAE/C;;;OAGG;IACH,YAFU,UAAU,CAEwC;IAE5D;;;;;OAKG;IACH,gBAAyC;IAEzC;;;;;OAKG;IACH,wBAAmD;IAEnD;;;OAGG;IACH,IAFU,UAAU,CAEgC;IAEpD;;;OAGG;IACH,QAFU,MAAM,CAMf;IAED;;;OAGG;IACH,KAFU,GAAG,CAEc;IAE3B;;;OAGG;IACH,WAFU,SAAS,CAEoB;IAEvC;;;OAGG;IACH,OAFU,KAAK,CAEuD;IAEtE;;;OAGG;IACH,MAFU,IAAI,CAEQ;IAEtB;;;OAGG;IACH,YAFU,UAAU,CAE+C;IAEnE;;;OAGG;IACH,KAFU,8BAA8B,CAE1B;IAEd;;;OAGG;IACH,SAFU,cAAc,CAEkB;IAE1C;;;;OAIG;IACH,OAFW,KAAK,CAEwB;IAExC;;;OAGG;IACH,WA0BC;IAED;;;OAGG;IACH,QAFU,MAAM,CAEiB;IAEjC;;;;OAIG;IACH,QAHU,OAAO,CAGiB;IAElC;;;OAGG;IACH,SAFU,OAAO,CAEkB;CAEtC;sDA9OqD,4BAA4B;4BAXtD,0BAA0B;sBAfhC,oBAAoB;uBAuBnB,qBAAqB;wBAxBpB,sBAAsB;qBAGzB,mBAAmB;wBAChB,sBAAsB;2BAqBnB,yBAAyB;2BApBzB,yBAAyB;uBAC7B,qBAAqB;oBAExB,kBAAkB;mCAGH,wBAAwB;sBAFrC,oBAAoB;qBACrB,mBAAmB;2BAHb,yBAAyB;+CAQL,qCAAqC;+BADrD,sBAAsB;sBAD/B,oBAAoB;uBADnB,qBAAqB;wBAbpB,sBAAsB;wBAGtB,sBAAsB"}
|
|
@@ -0,0 +1,87 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @typedef {Object} Logger
|
|
3
|
+
* @property {function(string): void} trace - Function to log trace messages.
|
|
4
|
+
* @property {function(string): void} verbose - Function to log verbose messages.
|
|
5
|
+
* @property {function(string): void} info - Function to log info messages.
|
|
6
|
+
* @property {function(string): void} warn - Function to log warning messages.
|
|
7
|
+
* @property {function(string): void} error - Function to log error messages.
|
|
8
|
+
* @property {function(string): void} critical - Function to log critical messages.
|
|
9
|
+
*/
|
|
10
|
+
/**
|
|
11
|
+
* @typedef {typeof import('selenium-webdriver')} WebDriverClass
|
|
12
|
+
* @typedef {import('selenium-webdriver').WebDriver} WebDriverInstance
|
|
13
|
+
*/
|
|
14
|
+
/**
|
|
15
|
+
* Class representing the context of a Browsertime run.
|
|
16
|
+
* @hideconstructor
|
|
17
|
+
* @class
|
|
18
|
+
*/
|
|
19
|
+
export class Context {
|
|
20
|
+
constructor(options: any, result: any, log: any, storageManager: any, index: any, webdriver: any, instantiatedDriver: any);
|
|
21
|
+
/**
|
|
22
|
+
* This is the yargs object you get from the cli. If you add --my.id you can get that using options.my.id.
|
|
23
|
+
* @type {Object}
|
|
24
|
+
*/
|
|
25
|
+
options: any;
|
|
26
|
+
/**
|
|
27
|
+
* Here the result from each run is stored.
|
|
28
|
+
* @type {Object}
|
|
29
|
+
*/
|
|
30
|
+
result: any;
|
|
31
|
+
/**
|
|
32
|
+
* @type {Logger}
|
|
33
|
+
*/
|
|
34
|
+
log: Logger;
|
|
35
|
+
/**
|
|
36
|
+
* The index of the iteration.
|
|
37
|
+
* @type {number}
|
|
38
|
+
*/
|
|
39
|
+
index: number;
|
|
40
|
+
/**
|
|
41
|
+
* Storage manager to save things to disk.
|
|
42
|
+
* @type {import('../../support/storageManager.js').StorageManager}
|
|
43
|
+
*/
|
|
44
|
+
storageManager: import('../../support/storageManager.js').StorageManager;
|
|
45
|
+
/**
|
|
46
|
+
* @type {Object}
|
|
47
|
+
*/
|
|
48
|
+
taskData: any;
|
|
49
|
+
/**
|
|
50
|
+
* Get raw Selenium functionality.
|
|
51
|
+
* @see https://www.selenium.dev/selenium/docs/api/javascript/module/selenium-webdriver/index.html
|
|
52
|
+
* @type {{webdriver: WebDriverClass, driver: WebDriverInstance}}
|
|
53
|
+
*/
|
|
54
|
+
selenium: {
|
|
55
|
+
webdriver: typeof import("selenium-webdriver");
|
|
56
|
+
driver: import("selenium-webdriver").WebDriver;
|
|
57
|
+
};
|
|
58
|
+
}
|
|
59
|
+
export type Logger = {
|
|
60
|
+
/**
|
|
61
|
+
* - Function to log trace messages.
|
|
62
|
+
*/
|
|
63
|
+
trace: (arg0: string) => void;
|
|
64
|
+
/**
|
|
65
|
+
* - Function to log verbose messages.
|
|
66
|
+
*/
|
|
67
|
+
verbose: (arg0: string) => void;
|
|
68
|
+
/**
|
|
69
|
+
* - Function to log info messages.
|
|
70
|
+
*/
|
|
71
|
+
info: (arg0: string) => void;
|
|
72
|
+
/**
|
|
73
|
+
* - Function to log warning messages.
|
|
74
|
+
*/
|
|
75
|
+
warn: (arg0: string) => void;
|
|
76
|
+
/**
|
|
77
|
+
* - Function to log error messages.
|
|
78
|
+
*/
|
|
79
|
+
error: (arg0: string) => void;
|
|
80
|
+
/**
|
|
81
|
+
* - Function to log critical messages.
|
|
82
|
+
*/
|
|
83
|
+
critical: (arg0: string) => void;
|
|
84
|
+
};
|
|
85
|
+
export type WebDriverClass = typeof import('selenium-webdriver');
|
|
86
|
+
export type WebDriverInstance = import('selenium-webdriver').WebDriver;
|
|
87
|
+
//# sourceMappingURL=context.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"context.d.ts","sourceRoot":"","sources":["../../../lib/core/engine/context.js"],"names":[],"mappings":"AAAA;;;;;;;;GAQG;AAEH;;;GAGG;AAEH;;;;GAIG;AACH;IACE,2HA0DC;IAjDC;;;OAGG;IACH,aAAsB;IAEtB;;;OAGG;IACH,YAAoB;IAEpB;;OAEG;IACH,KAFU,MAAM,CAEF;IAEd;;;OAGG;IACH,OAFU,MAAM,CAEE;IAElB;;;OAGG;IACH,gBAFU,OAAO,iCAAiC,EAAE,cAAc,CAE9B;IAEpC;;OAEG;IACH,cAAkB;IAElB;;;;OAIG;IACH;;;MASC;CAEJ;;;;;kBA9EsB,MAAM,KAAG,IAAI;;;;oBACb,MAAM,KAAG,IAAI;;;;iBACb,MAAM,KAAG,IAAI;;;;iBACb,MAAM,KAAG,IAAI;;;;kBACb,MAAM,KAAG,IAAI;;;;qBACb,MAAM,KAAG,IAAI;;6BAIvB,cAAc,oBAAoB,CAAC;gCACnC,OAAO,oBAAoB,EAAE,SAAS"}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
export class GeckoProfiler {
|
|
2
|
+
constructor(runner: any, storageManager: any, options: any);
|
|
3
|
+
runner: any;
|
|
4
|
+
storageManager: any;
|
|
5
|
+
firefoxConfig: any;
|
|
6
|
+
options: any;
|
|
7
|
+
start(): Promise<any>;
|
|
8
|
+
stop(index: any, url: any, result: any): Promise<void>;
|
|
9
|
+
addMetaData(): void;
|
|
10
|
+
}
|
|
11
|
+
//# sourceMappingURL=geckoProfiler.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"geckoProfiler.d.ts","sourceRoot":"","sources":["../../lib/firefox/geckoProfiler.js"],"names":[],"mappings":"AAmDA;IACE,4DAKC;IAJC,YAAoB;IACpB,oBAAoC;IACpC,mBAAoC;IACpC,aAAsB;IAGxB,sBA2FC;IAED,uDAgGC;IAED,oBAAgB;CACjB"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"geckoProfilerDefaults.d.ts","sourceRoot":"","sources":["../../../lib/firefox/settings/geckoProfilerDefaults.js"],"names":[],"mappings":""}
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
export function loadPrePostScripts(scripts: any, options: any): Promise<any[]>;
|
|
2
|
+
export function loadPageCompleteScript(script: any): Promise<any>;
|
|
3
|
+
export function loadScript(script: any, options: any, throwError: any): Promise<any>;
|
|
4
|
+
export function timestamp(): string;
|
|
5
|
+
//# sourceMappingURL=engineUtils.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"engineUtils.d.ts","sourceRoot":"","sources":["../../lib/support/engineUtils.js"],"names":[],"mappings":"AAgFA,+EAOC;AAED,kEAKC;AAED,qFAKC;AACD,oCAEC"}
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
export class BrowsertimeError extends Error {
|
|
2
|
+
constructor(message: any, extra: any);
|
|
3
|
+
extra: any;
|
|
4
|
+
}
|
|
5
|
+
export class BrowserError extends BrowsertimeError {
|
|
6
|
+
}
|
|
7
|
+
export class UrlLoadError extends BrowsertimeError {
|
|
8
|
+
constructor(message: any, url: any, extra: any);
|
|
9
|
+
url: any;
|
|
10
|
+
}
|
|
11
|
+
export class TimeoutError extends BrowsertimeError {
|
|
12
|
+
constructor(message: any, url: any, extra: any);
|
|
13
|
+
url: any;
|
|
14
|
+
}
|
|
15
|
+
//# sourceMappingURL=errors.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"errors.d.ts","sourceRoot":"","sources":["../../lib/support/errors.js"],"names":[],"mappings":"AAAA;IACE,sCAIC;IAFC,WAAwB;CAG3B;AAED;CAIC;AAED;IACE,gDAGC;IADC,SAAc;CAEjB;AAED;IACE,gDAGC;IADC,SAAc;CAEjB"}
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
export function rename(old: any, newName: any): Promise<void>;
|
|
2
|
+
export function copyFileSync(source: any, destination: any): void;
|
|
3
|
+
export function removeFileSync(fileName: any): Promise<void>;
|
|
4
|
+
export function copyFile(source: any, destination: any): Promise<void>;
|
|
5
|
+
export function removeFile(fileName: any): Promise<void>;
|
|
6
|
+
export function readFile(fileName: any): Promise<Buffer>;
|
|
7
|
+
export function removeDirAndFiles(dirName: any): Promise<void>;
|
|
8
|
+
export function removeByType(dir: any, type: any): Promise<void>;
|
|
9
|
+
export function findFiles(dir: any, filter: any): Promise<string[]>;
|
|
10
|
+
//# sourceMappingURL=fileUtil.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"fileUtil.d.ts","sourceRoot":"","sources":["../../lib/support/fileUtil.js"],"names":[],"mappings":"AAwBA,8DAEC;AAED,kEAEC;AAED,6DAEC;AAED,uEAEC;AACD,yDAEC;AACD,yDAEC;AACD,+DAqBC;AACD,iEAUC;AACD,oEAMC"}
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Filters to use with Array.prototype.filter, e.g. ['/a/path', '/another/path'].filter(onlyFiles)
|
|
3
|
+
*/
|
|
4
|
+
export function onlyWithExtension(extension: any): (filepath: any) => boolean;
|
|
5
|
+
export function onlyFiles(filepath: any): Promise<boolean>;
|
|
6
|
+
export function onlyDirectories(filepath: any): Promise<boolean>;
|
|
7
|
+
//# sourceMappingURL=filters.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"filters.d.ts","sourceRoot":"","sources":["../../lib/support/filters.js"],"names":[],"mappings":"AAKA;;GAEG;AACH,8EAEC;AACD,2DAGC;AACD,iEAGC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"getViewPort.d.ts","sourceRoot":"","sources":["../../lib/support/getViewPort.js"],"names":[],"mappings":"AA+BA,+CAkCC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"pathToFolder.d.ts","sourceRoot":"","sources":["../../lib/support/pathToFolder.js"],"names":[],"mappings":"AAWA,6DAwDC"}
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
export class StorageManager {
|
|
2
|
+
constructor(url: any, { resultDir, prettyPrint }?: {
|
|
3
|
+
resultDir: any;
|
|
4
|
+
prettyPrint?: boolean;
|
|
5
|
+
});
|
|
6
|
+
baseDir: string;
|
|
7
|
+
jsonIndentation: number;
|
|
8
|
+
createDataDir(): Promise<string>;
|
|
9
|
+
createSubDataDir(...name: any[]): Promise<string>;
|
|
10
|
+
rm(filename: any): Promise<void>;
|
|
11
|
+
writeData(filename: any, data: any, subdir: any): Promise<string>;
|
|
12
|
+
writeJson(filename: any, json: any, shouldGzip: any): Promise<string>;
|
|
13
|
+
readData(filename: any, subdir: any): Promise<string | Buffer>;
|
|
14
|
+
gzip(inputFile: any, outputFile: any, removeInput: any): Promise<any>;
|
|
15
|
+
get directory(): string;
|
|
16
|
+
}
|
|
17
|
+
//# sourceMappingURL=storageManager.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"storageManager.d.ts","sourceRoot":"","sources":["../../lib/support/storageManager.js"],"names":[],"mappings":"AAmDA;IACE;;;OAKC;IAJC,gBAEyD;IACzD,wBAA0C;IAG5C,iCAGC;IAED,kDAIC;IAED,iCAEC;IAED,kEASC;IAED,sEAQC;IAED,+DAcC;IAED,sEAmBC;IAED,wBAEC;CACF"}
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
export class TCPDump {
|
|
2
|
+
constructor(directory: any, options: any);
|
|
3
|
+
baseDir: any;
|
|
4
|
+
options: any;
|
|
5
|
+
start(iteration: any): Promise<void>;
|
|
6
|
+
tcpdumpProcess: import("execa").ExecaChildProcess<string>;
|
|
7
|
+
stop(): Promise<import("execa").ExecaReturnValue<string>>;
|
|
8
|
+
mv(url: any, iteration: any): Promise<void>;
|
|
9
|
+
}
|
|
10
|
+
//# sourceMappingURL=tcpdump.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"tcpdump.d.ts","sourceRoot":"","sources":["../../lib/support/tcpdump.js"],"names":[],"mappings":"AAKA;IACE,0CAGC;IAFC,aAAwB;IACxB,aAAsB;IAExB,qCAsBC;IADC,0DAA+C;IAEjD,0DAEC;IAED,4CAQC;CACF"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"userTiming.d.ts","sourceRoot":"","sources":["../../lib/support/userTiming.js"],"names":[],"mappings":"AAAA,+EAMC"}
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
export function formatMetric(name: any, metric: any, multiple: any, inMs: any, extras: any): string;
|
|
2
|
+
export function logResultLogLine(results: any): void;
|
|
3
|
+
export function toArray(arrayLike: any): any[];
|
|
4
|
+
export function jsonifyVisualProgress(visualProgress: any): any;
|
|
5
|
+
export function adjustVisualProgressTimestamps(visualProgress: any, profilerStartTime: any, recordingStartTime: any): any;
|
|
6
|
+
//# sourceMappingURL=util.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"util.d.ts","sourceRoot":"","sources":["../../lib/support/util.js"],"names":[],"mappings":"AAIA,oGAeC;AACD,qDA0LC;AACD,+CAQC;AACD,gEAeC;AACD,0HAWC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"defaults.d.ts","sourceRoot":"","sources":["../../lib/video/defaults.js"],"names":[],"mappings":"AAAA,2BAA4B;AAC5B,qBAAsB;AACtB,6BAA8B;AAC9B,4BAA6B;AAC7B,2BAA4B;AAC5B,wBAAyB"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"addTextToVideo.d.ts","sourceRoot":"","sources":["../../../../lib/video/postprocessing/finetune/addTextToVideo.js"],"names":[],"mappings":"AAgBA,wKAiCC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"convertFps.d.ts","sourceRoot":"","sources":["../../../../lib/video/postprocessing/finetune/convertFps.js"],"names":[],"mappings":"AAIA,0HAWC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"getFont.d.ts","sourceRoot":"","sources":["../../../../lib/video/postprocessing/finetune/getFont.js"],"names":[],"mappings":"AACA,8CA6BC"}
|