@wdio/appium-service 9.23.0 → 9.23.2
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/cli-utils.d.ts +6 -0
- package/build/cli-utils.d.ts.map +1 -1
- package/build/cli.d.ts.map +1 -1
- package/build/cli.js +14 -1
- package/package.json +6 -6
package/build/cli-utils.d.ts
CHANGED
|
@@ -1,6 +1,12 @@
|
|
|
1
1
|
import { type ChildProcessByStdio } from 'node:child_process';
|
|
2
2
|
import { type Readable } from 'node:stream';
|
|
3
3
|
export declare function extractPortFromCliArgs(args: string[]): number;
|
|
4
|
+
/**
|
|
5
|
+
* Removes any existing --port argument from the args array.
|
|
6
|
+
* Handles both --port=5555 and --port 5555 formats.
|
|
7
|
+
* @param args - Array of command line arguments
|
|
8
|
+
*/
|
|
9
|
+
export declare function removePortFromArgs(args: string[]): void;
|
|
4
10
|
export declare function determineAppiumCliCommand(command?: string): Promise<string>;
|
|
5
11
|
export declare function checkInspectorPluginInstalled(appiumCommandPath: string): Promise<void>;
|
|
6
12
|
export declare function startAppiumForCli(appiumCommandPath: string, args: string[], timeout?: number): Promise<ChildProcessByStdio<null, Readable, Readable>>;
|
package/build/cli-utils.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"cli-utils.d.ts","sourceRoot":"","sources":["../src/cli-utils.ts"],"names":[],"mappings":"AAGA,OAAO,EAAyB,KAAK,mBAAmB,EAAE,MAAM,oBAAoB,CAAA;AACpF,OAAO,EAAE,KAAK,QAAQ,EAAE,MAAM,aAAa,CAAA;AAoC3C,wBAAgB,sBAAsB,CAAC,IAAI,EAAE,MAAM,EAAE,GAAG,MAAM,CAE7D;AAYD,wBAAsB,yBAAyB,CAAC,OAAO,SAAW,GAAG,OAAO,CAAC,MAAM,CAAC,CA8BnF;AAED,wBAAsB,6BAA6B,CAAC,iBAAiB,EAAE,MAAM,GAAG,OAAO,CAAC,IAAI,CAAC,CAkC5F;AAED,wBAAsB,iBAAiB,CACnC,iBAAiB,EAAE,MAAM,EACzB,IAAI,EAAE,MAAM,EAAE,EACd,OAAO,SAAuB,GAC/B,OAAO,CAAC,mBAAmB,CAAC,IAAI,EAAE,QAAQ,EAAE,QAAQ,CAAC,CAAC,CA6GxD;AAED,wBAAsB,WAAW,CAAC,GAAG,EAAE,MAAM,GAAG,OAAO,CAAC,IAAI,CAAC,CAoB5D"}
|
|
1
|
+
{"version":3,"file":"cli-utils.d.ts","sourceRoot":"","sources":["../src/cli-utils.ts"],"names":[],"mappings":"AAGA,OAAO,EAAyB,KAAK,mBAAmB,EAAE,MAAM,oBAAoB,CAAA;AACpF,OAAO,EAAE,KAAK,QAAQ,EAAE,MAAM,aAAa,CAAA;AAoC3C,wBAAgB,sBAAsB,CAAC,IAAI,EAAE,MAAM,EAAE,GAAG,MAAM,CAE7D;AAED;;;;GAIG;AACH,wBAAgB,kBAAkB,CAAC,IAAI,EAAE,MAAM,EAAE,GAAG,IAAI,CAcvD;AAYD,wBAAsB,yBAAyB,CAAC,OAAO,SAAW,GAAG,OAAO,CAAC,MAAM,CAAC,CA8BnF;AAED,wBAAsB,6BAA6B,CAAC,iBAAiB,EAAE,MAAM,GAAG,OAAO,CAAC,IAAI,CAAC,CAkC5F;AAED,wBAAsB,iBAAiB,CACnC,iBAAiB,EAAE,MAAM,EACzB,IAAI,EAAE,MAAM,EAAE,EACd,OAAO,SAAuB,GAC/B,OAAO,CAAC,mBAAmB,CAAC,IAAI,EAAE,QAAQ,EAAE,QAAQ,CAAC,CAAC,CA6GxD;AAED,wBAAsB,WAAW,CAAC,GAAG,EAAE,MAAM,GAAG,OAAO,CAAC,IAAI,CAAC,CAoB5D"}
|
package/build/cli.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"cli.d.ts","sourceRoot":"","sources":["../src/cli.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"cli.d.ts","sourceRoot":"","sources":["../src/cli.ts"],"names":[],"mappings":"AAaA,wBAAsB,GAAG,kBAuDxB"}
|
package/build/cli.js
CHANGED
|
@@ -31,6 +31,18 @@ function extractPortFromArgs(args) {
|
|
|
31
31
|
function extractPortFromCliArgs(args) {
|
|
32
32
|
return extractPortFromArgs(args) ?? 4723;
|
|
33
33
|
}
|
|
34
|
+
function removePortFromArgs(args) {
|
|
35
|
+
for (let i = args.length - 1; i >= 0; i--) {
|
|
36
|
+
if (args[i].startsWith("--port")) {
|
|
37
|
+
const portArg = args[i];
|
|
38
|
+
if (portArg.includes("=")) {
|
|
39
|
+
args.splice(i, 1);
|
|
40
|
+
} else {
|
|
41
|
+
args.splice(i, 2);
|
|
42
|
+
}
|
|
43
|
+
}
|
|
44
|
+
}
|
|
45
|
+
}
|
|
34
46
|
async function tryResolveModule(command, from) {
|
|
35
47
|
try {
|
|
36
48
|
const entryPath = await resolveModule(command, from);
|
|
@@ -185,7 +197,8 @@ async function run() {
|
|
|
185
197
|
const args = process.argv.slice(2);
|
|
186
198
|
const port = extractPortFromCliArgs(args);
|
|
187
199
|
const requiredFlags = ["--log-timestamp", "--use-plugins=inspector", "--allow-cors"];
|
|
188
|
-
args
|
|
200
|
+
removePortFromArgs(args);
|
|
201
|
+
args.unshift(`--port=${port}`);
|
|
189
202
|
requiredFlags.forEach((flag) => {
|
|
190
203
|
if (!args.includes(flag)) {
|
|
191
204
|
args.push(flag);
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@wdio/appium-service",
|
|
3
|
-
"version": "9.23.
|
|
3
|
+
"version": "9.23.2",
|
|
4
4
|
"description": "A WebdriverIO service to start & stop Appium Server",
|
|
5
5
|
"author": "Morten Bjerg Gregersen <morten@mogee.dk>",
|
|
6
6
|
"homepage": "https://github.com/webdriverio/webdriverio/tree/main/packages/wdio-appium-service",
|
|
@@ -43,18 +43,18 @@
|
|
|
43
43
|
},
|
|
44
44
|
"typeScriptVersion": "3.8.3",
|
|
45
45
|
"dependencies": {
|
|
46
|
-
"@wdio/config": "9.23.
|
|
46
|
+
"@wdio/config": "9.23.2",
|
|
47
47
|
"@wdio/logger": "9.18.0",
|
|
48
|
-
"@wdio/types": "9.
|
|
49
|
-
"@wdio/utils": "9.23.
|
|
48
|
+
"@wdio/types": "9.23.2",
|
|
49
|
+
"@wdio/utils": "9.23.2",
|
|
50
50
|
"change-case": "^5.4.3",
|
|
51
51
|
"get-port": "^7.0.0",
|
|
52
52
|
"import-meta-resolve": "^4.0.0",
|
|
53
53
|
"tree-kill": "^1.2.2",
|
|
54
|
-
"webdriverio": "9.23.
|
|
54
|
+
"webdriverio": "9.23.2"
|
|
55
55
|
},
|
|
56
56
|
"publishConfig": {
|
|
57
57
|
"access": "public"
|
|
58
58
|
},
|
|
59
|
-
"gitHead": "
|
|
59
|
+
"gitHead": "3447f2744e52b367ad1164ff6a920924d830e4ee"
|
|
60
60
|
}
|