@wdio/browserstack-service 9.33.2 → 9.34.1
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/build/bstackLogger.d.ts +13 -0
- package/build/cleanup.js +552 -119
- package/build/cli/cliUtils.d.ts +14 -1
- package/build/cli/modules/automateModule.d.ts +5 -0
- package/build/cli/modules/testHubModule.d.ts +1 -1
- package/build/configCapture.d.ts +117 -0
- package/build/constants.d.ts +38 -0
- package/build/index.js +811 -251
- package/build/insights-handler.d.ts +4 -3
- package/build/service.d.ts +1 -0
- package/build/types.d.ts +16 -0
- package/build/util.d.ts +21 -1
- package/package.json +1 -1
|
@@ -46,9 +46,10 @@ declare class _InsightsHandler {
|
|
|
46
46
|
* test/hook so the backend closes the entity instead of leaving it in_progress and
|
|
47
47
|
* letting the build watchdog inflate the duration.
|
|
48
48
|
*
|
|
49
|
-
*
|
|
50
|
-
*
|
|
51
|
-
*
|
|
49
|
+
* Covers mocha and cucumber. Cucumber entries are keyed by hook-definition id / scenario
|
|
50
|
+
* unique id rather than title, but both stash kind + identity at start time, so the same
|
|
51
|
+
* kind-tag scan closes them (SDK-7167: an AFTER_EACH hook whose finish was never emitted
|
|
52
|
+
* held the hook open until the backend's 2h hook timeout, inflating the build duration).
|
|
52
53
|
*
|
|
53
54
|
* Each entry was tagged with kind at start time so we emit HookRunFinished for hooks and
|
|
54
55
|
* TestRunFinished for tests without re-deriving the kind from the title. Entries without a
|
package/build/service.d.ts
CHANGED
|
@@ -75,6 +75,7 @@ export default class BrowserstackService implements Services.ServiceInstance {
|
|
|
75
75
|
onReload(oldSessionId: string, newSessionId: string): Promise<void>;
|
|
76
76
|
_isAppAutomate(): boolean;
|
|
77
77
|
_updateJob(requestBody: unknown): Promise<unknown>;
|
|
78
|
+
_routeBidiExecutorToHttp(browser: WebdriverIO.Browser): void;
|
|
78
79
|
_multiRemoteAction(action: MultiRemoteAction): Promise<unknown>;
|
|
79
80
|
_update(sessionId: string, requestBody: unknown): Promise<void> | Promise<Response>;
|
|
80
81
|
_printSessionURL(): Promise<void>;
|
package/build/types.d.ts
CHANGED
|
@@ -91,6 +91,22 @@ export interface BrowserstackConfig {
|
|
|
91
91
|
* Currently supports testPlanId.
|
|
92
92
|
*/
|
|
93
93
|
testManagementOptions?: TestManagementOptions;
|
|
94
|
+
/**
|
|
95
|
+
* By default the service uploads its own debug logs, your `package.json` and a copy of
|
|
96
|
+
* your wdio config file at the end of a run, so BrowserStack support can debug issues
|
|
97
|
+
* without asking you to reproduce them.
|
|
98
|
+
*
|
|
99
|
+
* Values under known credential keys are removed before upload on a best-effort basis:
|
|
100
|
+
* BrowserStack credentials, common third-party secret names (`clientSecret`,
|
|
101
|
+
* `AWS_SECRET_ACCESS_KEY`, …), inline PEM blocks and basic-auth URLs. It is key-name
|
|
102
|
+
* driven, so a secret stored under an unrecognised name can still be included — if your
|
|
103
|
+
* config holds secrets you would rather not send, set this to true.
|
|
104
|
+
*
|
|
105
|
+
* Set this to true to disable that upload entirely.
|
|
106
|
+
* Can also be set with the `BROWSERSTACK_DISABLE_AUTO_CAPTURE_LOGS=true` env var.
|
|
107
|
+
* @default false
|
|
108
|
+
*/
|
|
109
|
+
disableAutoCaptureLogs?: boolean;
|
|
94
110
|
/**
|
|
95
111
|
* Set this to true to enable BrowserStack Percy which will take screenshots
|
|
96
112
|
* and snapshots for your tests run on Browserstack
|
package/build/util.d.ts
CHANGED
|
@@ -99,6 +99,15 @@ export declare const getA11yResults: (...args: (object | boolean | undefined | n
|
|
|
99
99
|
export declare const getAppA11yResults: (...args: (object | boolean | undefined | null | string)[]) => any;
|
|
100
100
|
export declare const getAppA11yResultsSummary: (...args: (object | boolean | undefined | null | string)[]) => any;
|
|
101
101
|
export declare const getA11yResultsSummary: (...args: (object | boolean | undefined | null | string)[]) => any;
|
|
102
|
+
/**
|
|
103
|
+
* Render an error together with its `cause` chain.
|
|
104
|
+
*
|
|
105
|
+
* Node's native fetch reports every transport failure as the same opaque
|
|
106
|
+
* `TypeError: fetch failed`; the actionable detail (ENOTFOUND, ECONNRESET, a proxy
|
|
107
|
+
* refusal) only lives on `error.cause`, which plain interpolation drops. Without this
|
|
108
|
+
* a failed build-stop is indistinguishable from any other network fault in the logs.
|
|
109
|
+
*/
|
|
110
|
+
export declare const describeErrorWithCause: (error: unknown, depth?: number) => string;
|
|
102
111
|
export declare const stopBuildUpstream: (...args: (object | boolean | undefined | null | string)[]) => any;
|
|
103
112
|
export declare function getCiInfo(): {
|
|
104
113
|
name: string;
|
|
@@ -191,7 +200,11 @@ export declare function getFailureObject(error: string | Error): {
|
|
|
191
200
|
failure_type: string | null;
|
|
192
201
|
};
|
|
193
202
|
export declare const sleep: (ms?: number) => Promise<unknown>;
|
|
194
|
-
export
|
|
203
|
+
export interface UploadLogsOptions {
|
|
204
|
+
disableAutoCaptureLogs?: boolean;
|
|
205
|
+
config?: Options.Testrunner;
|
|
206
|
+
}
|
|
207
|
+
export declare function uploadLogs(user: string | undefined, key: string | undefined, clientBuildUuid: string, options?: UploadLogsOptions): Promise<any>;
|
|
195
208
|
export declare const isObject: (object: unknown) => boolean;
|
|
196
209
|
export declare const ObjectsAreEqual: (object1: object, object2: object) => boolean;
|
|
197
210
|
export declare const getPlatformVersion: (...args: unknown[]) => any;
|
|
@@ -259,6 +272,13 @@ export declare function createDir(dir: string): void;
|
|
|
259
272
|
export declare function isWritable(dirPath: string): boolean;
|
|
260
273
|
export declare function setReadWriteAccess(dirPath: string): void;
|
|
261
274
|
export declare function getMochaTestHierarchy(test: Frameworks.Test): string[];
|
|
275
|
+
/**
|
|
276
|
+
* True only for the hub-interpreted `browserstack_executor: {…}` magic string.
|
|
277
|
+
* Anchored to the start (leading whitespace tolerated) and case-sensitive, matching
|
|
278
|
+
* how the hub reads the payload — a plain script merely mentioning the token must not
|
|
279
|
+
* be rerouted off its normal transport.
|
|
280
|
+
*/
|
|
281
|
+
export declare const isBrowserstackExecutorScript: (script: unknown) => script is string;
|
|
262
282
|
export declare const performO11ySync: (browser: WebdriverIO.Browser) => Promise<void>;
|
|
263
283
|
/**
|
|
264
284
|
* Checks if the capabilities represent a multiremote configuration
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@wdio/browserstack-service",
|
|
3
|
-
"version": "9.
|
|
3
|
+
"version": "9.34.1",
|
|
4
4
|
"description": "WebdriverIO service for better Browserstack integration",
|
|
5
5
|
"author": "BrowserStack <support@browserstack.com>",
|
|
6
6
|
"homepage": "https://github.com/browserstack/wdio-browserstack-service",
|