appium-remote-debugger 10.0.2 → 10.1.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 +14 -0
- package/build/index.js +18 -33
- package/build/lib/atoms.d.ts +17 -0
- package/build/lib/atoms.d.ts.map +1 -0
- package/build/lib/atoms.js +75 -50
- package/build/lib/atoms.js.map +1 -1
- package/build/lib/logger.d.ts +3 -0
- package/build/lib/logger.d.ts.map +1 -0
- package/build/lib/logger.js +5 -11
- package/build/lib/logger.js.map +1 -1
- package/build/lib/mixins/connect.d.ts +125 -0
- package/build/lib/mixins/connect.d.ts.map +1 -0
- package/build/lib/mixins/connect.js +299 -202
- package/build/lib/mixins/connect.js.map +1 -1
- package/build/lib/mixins/events.d.ts +7 -0
- package/build/lib/mixins/events.d.ts.map +1 -0
- package/build/lib/mixins/events.js +7 -12
- package/build/lib/mixins/events.js.map +1 -1
- package/build/lib/mixins/execute.d.ts +38 -0
- package/build/lib/mixins/execute.d.ts.map +1 -0
- package/build/lib/mixins/execute.js +162 -122
- package/build/lib/mixins/execute.js.map +1 -1
- package/build/lib/mixins/index.d.ts +5 -0
- package/build/lib/mixins/index.d.ts.map +1 -0
- package/build/lib/mixins/index.js +14 -23
- package/build/lib/mixins/index.js.map +1 -1
- package/build/lib/mixins/message-handlers.d.ts +92 -0
- package/build/lib/mixins/message-handlers.d.ts.map +1 -0
- package/build/lib/mixins/message-handlers.js +160 -97
- package/build/lib/mixins/message-handlers.js.map +1 -1
- package/build/lib/mixins/navigate.d.ts +92 -0
- package/build/lib/mixins/navigate.d.ts.map +1 -0
- package/build/lib/mixins/navigate.js +199 -141
- package/build/lib/mixins/navigate.js.map +1 -1
- package/build/lib/protocol/index.d.ts +14 -0
- package/build/lib/protocol/index.d.ts.map +1 -0
- package/build/lib/protocol/index.js +192 -118
- package/build/lib/protocol/index.js.map +1 -1
- package/build/lib/remote-debugger-real-device.d.ts +6 -0
- package/build/lib/remote-debugger-real-device.d.ts.map +1 -0
- package/build/lib/remote-debugger-real-device.js +29 -32
- package/build/lib/remote-debugger-real-device.js.map +1 -1
- package/build/lib/remote-debugger.d.ts +119 -0
- package/build/lib/remote-debugger.d.ts.map +1 -0
- package/build/lib/remote-debugger.js +256 -226
- package/build/lib/remote-debugger.js.map +1 -1
- package/build/lib/rpc/index.d.ts +4 -0
- package/build/lib/rpc/index.d.ts.map +1 -0
- package/build/lib/rpc/index.js +10 -21
- package/build/lib/rpc/index.js.map +1 -1
- package/build/lib/rpc/remote-messages.d.ts +51 -0
- package/build/lib/rpc/remote-messages.d.ts.map +1 -0
- package/build/lib/rpc/remote-messages.js +203 -224
- package/build/lib/rpc/remote-messages.js.map +1 -1
- package/build/lib/rpc/rpc-client-real-device.d.ts +6 -0
- package/build/lib/rpc/rpc-client-real-device.d.ts.map +1 -0
- package/build/lib/rpc/rpc-client-real-device.js +43 -49
- package/build/lib/rpc/rpc-client-real-device.js.map +1 -1
- package/build/lib/rpc/rpc-client-simulator.d.ts +15 -0
- package/build/lib/rpc/rpc-client-simulator.d.ts.map +1 -0
- package/build/lib/rpc/rpc-client-simulator.js +138 -125
- package/build/lib/rpc/rpc-client-simulator.js.map +1 -1
- package/build/lib/rpc/rpc-client.d.ts +142 -0
- package/build/lib/rpc/rpc-client.d.ts.map +1 -0
- package/build/lib/rpc/rpc-client.js +559 -418
- package/build/lib/rpc/rpc-client.js.map +1 -1
- package/build/lib/rpc/rpc-message-handler.d.ts +13 -0
- package/build/lib/rpc/rpc-message-handler.d.ts.map +1 -0
- package/build/lib/rpc/rpc-message-handler.js +181 -166
- package/build/lib/rpc/rpc-message-handler.js.map +1 -1
- package/build/lib/utils.d.ts +61 -0
- package/build/lib/utils.d.ts.map +1 -0
- package/build/lib/utils.js +241 -155
- package/build/lib/utils.js.map +1 -1
- package/lib/atoms.js +25 -4
- package/lib/mixins/connect.js +102 -7
- package/lib/mixins/execute.js +46 -13
- package/lib/mixins/message-handlers.js +44 -1
- package/lib/mixins/navigate.js +55 -3
- package/lib/remote-debugger.js +112 -0
- package/lib/rpc/rpc-client-real-device.js +1 -6
- package/lib/rpc/rpc-client-simulator.js +7 -1
- package/lib/rpc/rpc-client.js +106 -6
- package/lib/rpc/rpc-message-handler.js +1 -1
- package/lib/utils.js +31 -1
- package/package.json +26 -16
package/CHANGELOG.md
CHANGED
|
@@ -1,3 +1,17 @@
|
|
|
1
|
+
## [10.1.0](https://github.com/appium/appium-remote-debugger/compare/v10.0.3...v10.1.0) (2023-08-30)
|
|
2
|
+
|
|
3
|
+
|
|
4
|
+
### Features
|
|
5
|
+
|
|
6
|
+
* Switch babel to typescript ([#318](https://github.com/appium/appium-remote-debugger/issues/318)) ([f19984e](https://github.com/appium/appium-remote-debugger/commit/f19984e37471949057fbdf4333b816c8132fbc87)), closes [#319](https://github.com/appium/appium-remote-debugger/issues/319)
|
|
7
|
+
|
|
8
|
+
## [10.0.3](https://github.com/appium/appium-remote-debugger/compare/v10.0.2...v10.0.3) (2023-08-28)
|
|
9
|
+
|
|
10
|
+
|
|
11
|
+
### Miscellaneous Chores
|
|
12
|
+
|
|
13
|
+
* **deps-dev:** bump conventional-changelog-conventionalcommits ([#319](https://github.com/appium/appium-remote-debugger/issues/319)) ([75d2307](https://github.com/appium/appium-remote-debugger/commit/75d230754e49a015fc68a1f9a131970c16751d44))
|
|
14
|
+
|
|
1
15
|
## [10.0.2](https://github.com/appium/appium-remote-debugger/compare/v10.0.1...v10.0.2) (2023-08-25)
|
|
2
16
|
|
|
3
17
|
|
package/build/index.js
CHANGED
|
@@ -1,36 +1,21 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
});
|
|
13
|
-
Object.defineProperty(exports, "RemoteDebugger", {
|
|
14
|
-
enumerable: true,
|
|
15
|
-
get: function () {
|
|
16
|
-
return _remoteDebugger.RemoteDebugger;
|
|
17
|
-
}
|
|
18
|
-
});
|
|
19
|
-
Object.defineProperty(exports, "RemoteDebuggerRealDevice", {
|
|
20
|
-
enumerable: true,
|
|
21
|
-
get: function () {
|
|
22
|
-
return _remoteDebuggerRealDevice.default;
|
|
23
|
-
}
|
|
24
|
-
});
|
|
25
|
-
exports.createRemoteDebugger = createRemoteDebugger;
|
|
26
|
-
require("source-map-support/register");
|
|
27
|
-
var _remoteDebugger = require("./lib/remote-debugger");
|
|
28
|
-
var _remoteDebuggerRealDevice = _interopRequireDefault(require("./lib/remote-debugger-real-device"));
|
|
2
|
+
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
3
|
+
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
|
+
};
|
|
5
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
+
exports.REMOTE_DEBUGGER_PORT = exports.RemoteDebuggerRealDevice = exports.RemoteDebugger = exports.createRemoteDebugger = void 0;
|
|
7
|
+
const remote_debugger_1 = require("./lib/remote-debugger");
|
|
8
|
+
Object.defineProperty(exports, "RemoteDebugger", { enumerable: true, get: function () { return remote_debugger_1.RemoteDebugger; } });
|
|
9
|
+
Object.defineProperty(exports, "REMOTE_DEBUGGER_PORT", { enumerable: true, get: function () { return remote_debugger_1.REMOTE_DEBUGGER_PORT; } });
|
|
10
|
+
const remote_debugger_real_device_1 = __importDefault(require("./lib/remote-debugger-real-device"));
|
|
11
|
+
exports.RemoteDebuggerRealDevice = remote_debugger_real_device_1.default;
|
|
29
12
|
function createRemoteDebugger(opts, realDevice = false) {
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
13
|
+
if (realDevice) {
|
|
14
|
+
return new remote_debugger_real_device_1.default(opts);
|
|
15
|
+
}
|
|
16
|
+
else {
|
|
17
|
+
return new remote_debugger_1.RemoteDebugger(opts);
|
|
18
|
+
}
|
|
35
19
|
}
|
|
36
|
-
|
|
20
|
+
exports.createRemoteDebugger = createRemoteDebugger;
|
|
21
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
export default getAtom;
|
|
2
|
+
/**
|
|
3
|
+
*
|
|
4
|
+
* @param {string} atomName
|
|
5
|
+
* @returns {Promise<Buffer>}
|
|
6
|
+
*/
|
|
7
|
+
export function getAtom(atomName: string): Promise<Buffer>;
|
|
8
|
+
/**
|
|
9
|
+
*
|
|
10
|
+
* @param {string} atom
|
|
11
|
+
* @param {any[]} [args]
|
|
12
|
+
* @param {string[]} [frames]
|
|
13
|
+
* @param {string?} [asyncCallBack]
|
|
14
|
+
* @returns {Promise<string>}
|
|
15
|
+
*/
|
|
16
|
+
export function getScriptForAtom(atom: string, args?: any[] | undefined, frames?: string[] | undefined, asyncCallBack?: string | null | undefined): Promise<string>;
|
|
17
|
+
//# sourceMappingURL=atoms.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"atoms.d.ts","sourceRoot":"","sources":["../../lib/atoms.js"],"names":[],"mappings":";AAmBA;;;;GAIG;AACH,kCAHW,MAAM,GACJ,QAAQ,MAAM,CAAC,CAc3B;AAcD;;;;;;;GAOG;AACH,uCANW,MAAM,uGAIJ,QAAQ,MAAM,CAAC,CAwB3B"}
|
package/build/lib/atoms.js
CHANGED
|
@@ -1,61 +1,86 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
require("
|
|
11
|
-
|
|
12
|
-
var _path = _interopRequireDefault(require("path"));
|
|
13
|
-
var _lodash = _interopRequireDefault(require("lodash"));
|
|
14
|
-
var _logger = _interopRequireDefault(require("./logger"));
|
|
15
|
-
var _utils = require("./utils");
|
|
2
|
+
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
3
|
+
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
|
+
};
|
|
5
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
+
exports.getScriptForAtom = exports.getAtom = void 0;
|
|
7
|
+
const support_1 = require("@appium/support");
|
|
8
|
+
const path_1 = __importDefault(require("path"));
|
|
9
|
+
const lodash_1 = __importDefault(require("lodash"));
|
|
10
|
+
const logger_1 = __importDefault(require("./logger"));
|
|
11
|
+
const utils_1 = require("./utils");
|
|
16
12
|
const ATOMS_CACHE = {};
|
|
13
|
+
/**
|
|
14
|
+
* @param {any} obj
|
|
15
|
+
* @returns {string}
|
|
16
|
+
*/
|
|
17
17
|
function atomsStringify(obj) {
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
18
|
+
if (typeof obj === 'undefined') {
|
|
19
|
+
return 'undefined';
|
|
20
|
+
}
|
|
21
|
+
return JSON.stringify(obj);
|
|
22
22
|
}
|
|
23
|
+
/**
|
|
24
|
+
*
|
|
25
|
+
* @param {string} atomName
|
|
26
|
+
* @returns {Promise<Buffer>}
|
|
27
|
+
*/
|
|
23
28
|
async function getAtom(atomName) {
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
29
|
+
// check if we have already loaded and cached this atom
|
|
30
|
+
if (!lodash_1.default.has(ATOMS_CACHE, atomName)) {
|
|
31
|
+
const atomFileName = path_1.default.resolve((0, utils_1.getModuleRoot)(), 'atoms', `${atomName}.js`);
|
|
32
|
+
try {
|
|
33
|
+
ATOMS_CACHE[atomName] = await support_1.fs.readFile(atomFileName);
|
|
34
|
+
}
|
|
35
|
+
catch (e) {
|
|
36
|
+
throw new Error(`Unable to load Atom '${atomName}' from file '${atomFileName}'`);
|
|
37
|
+
}
|
|
30
38
|
}
|
|
31
|
-
|
|
32
|
-
return ATOMS_CACHE[atomName];
|
|
39
|
+
return ATOMS_CACHE[atomName];
|
|
33
40
|
}
|
|
41
|
+
exports.getAtom = getAtom;
|
|
42
|
+
/**
|
|
43
|
+
* @param {string} script
|
|
44
|
+
* @param {string} frame
|
|
45
|
+
* @returns {Promise<string>}
|
|
46
|
+
*/
|
|
34
47
|
async function wrapScriptForFrame(script, frame) {
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
48
|
+
logger_1.default.debug(`Wrapping script for frame '${frame}'`);
|
|
49
|
+
const elFromCache = await getAtom('get_element_from_cache');
|
|
50
|
+
return `(function (window) { var document = window.document; ` +
|
|
51
|
+
`return (${script}); })((${elFromCache.toString('utf8')})(${atomsStringify(frame)}))`;
|
|
38
52
|
}
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
53
|
+
/**
|
|
54
|
+
*
|
|
55
|
+
* @param {string} atom
|
|
56
|
+
* @param {any[]} [args]
|
|
57
|
+
* @param {string[]} [frames]
|
|
58
|
+
* @param {string?} [asyncCallBack]
|
|
59
|
+
* @returns {Promise<string>}
|
|
60
|
+
*/
|
|
61
|
+
async function getScriptForAtom(atom, args = [], frames = [], asyncCallBack = null) {
|
|
62
|
+
const atomSrc = (await getAtom(atom)).toString('utf8');
|
|
63
|
+
let script;
|
|
64
|
+
if (frames.length > 0) {
|
|
65
|
+
script = atomSrc;
|
|
66
|
+
for (const frame of frames) {
|
|
67
|
+
script = await wrapScriptForFrame(script, frame);
|
|
68
|
+
}
|
|
46
69
|
}
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
70
|
+
else {
|
|
71
|
+
logger_1.default.debug(`Executing '${atom}' atom in default context`);
|
|
72
|
+
script = `(${atomSrc})`;
|
|
73
|
+
}
|
|
74
|
+
// add the arguments, as strings
|
|
75
|
+
args = args.map(atomsStringify);
|
|
76
|
+
if (asyncCallBack) {
|
|
77
|
+
script += `(${args.join(',')}, ${asyncCallBack}, true)`;
|
|
78
|
+
}
|
|
79
|
+
else {
|
|
80
|
+
script += `(${args.join(',')})`;
|
|
81
|
+
}
|
|
82
|
+
return script;
|
|
58
83
|
}
|
|
59
|
-
|
|
60
|
-
exports.default =
|
|
61
|
-
//# sourceMappingURL=
|
|
84
|
+
exports.getScriptForAtom = getScriptForAtom;
|
|
85
|
+
exports.default = getAtom;
|
|
86
|
+
//# sourceMappingURL=atoms.js.map
|
package/build/lib/atoms.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"atoms.js","
|
|
1
|
+
{"version":3,"file":"atoms.js","sourceRoot":"","sources":["../../lib/atoms.js"],"names":[],"mappings":";;;;;;AAAA,6CAAqC;AACrC,gDAAwB;AACxB,oDAAuB;AACvB,sDAA2B;AAC3B,mCAAwC;AAExC,MAAM,WAAW,GAAG,EAAE,CAAC;AAEvB;;;GAGG;AACH,SAAS,cAAc,CAAC,GAAG;IACzB,IAAI,OAAO,GAAG,KAAK,WAAW,EAAE;QAC9B,OAAO,WAAW,CAAC;KACpB;IACD,OAAO,IAAI,CAAC,SAAS,CAAC,GAAG,CAAC,CAAC;AAC7B,CAAC;AAED;;;;GAIG;AACH,KAAK,UAAU,OAAO,CAAE,QAAQ;IAC9B,uDAAuD;IACvD,IAAI,CAAC,gBAAC,CAAC,GAAG,CAAC,WAAW,EAAE,QAAQ,CAAC,EAAE;QACjC,MAAM,YAAY,GAAG,cAAI,CAAC,OAAO,CAAC,IAAA,qBAAa,GAAE,EAAE,OAAO,EAAE,GAAG,QAAQ,KAAK,CAAC,CAAC;QAC9E,IAAI;YACF,WAAW,CAAC,QAAQ,CAAC,GAAG,MAAM,YAAE,CAAC,QAAQ,CAAC,YAAY,CAAC,CAAC;SACzD;QAAC,OAAO,CAAC,EAAE;YACV,MAAM,IAAI,KAAK,CAAC,wBAAwB,QAAQ,gBAAgB,YAAY,GAAG,CAAC,CAAC;SAClF;KACF;IAED,OAAO,WAAW,CAAC,QAAQ,CAAC,CAAC;AAC/B,CAAC;AA8CQ,0BAAO;AA5ChB;;;;GAIG;AACH,KAAK,UAAU,kBAAkB,CAAE,MAAM,EAAE,KAAK;IAC9C,gBAAG,CAAC,KAAK,CAAC,8BAA8B,KAAK,GAAG,CAAC,CAAC;IAClD,MAAM,WAAW,GAAG,MAAM,OAAO,CAAC,wBAAwB,CAAC,CAAC;IAC5D,OAAO,uDAAuD;QAC5D,WAAW,MAAM,UAAU,WAAW,CAAC,QAAQ,CAAC,MAAM,CAAC,KAAK,cAAc,CAAC,KAAK,CAAC,IAAI,CAAC;AAC1F,CAAC;AAED;;;;;;;GAOG;AACH,KAAK,UAAU,gBAAgB,CAAE,IAAI,EAAE,IAAI,GAAG,EAAE,EAAE,MAAM,GAAG,EAAE,EAAE,aAAa,GAAG,IAAI;IACjF,MAAM,OAAO,GAAG,CAAC,MAAM,OAAO,CAAC,IAAI,CAAC,CAAC,CAAC,QAAQ,CAAC,MAAM,CAAC,CAAC;IACvD,IAAI,MAAM,CAAC;IACX,IAAI,MAAM,CAAC,MAAM,GAAG,CAAC,EAAE;QACrB,MAAM,GAAG,OAAO,CAAC;QACjB,KAAK,MAAM,KAAK,IAAI,MAAM,EAAE;YAC1B,MAAM,GAAG,MAAM,kBAAkB,CAAC,MAAM,EAAE,KAAK,CAAC,CAAC;SAClD;KACF;SAAM;QACL,gBAAG,CAAC,KAAK,CAAC,cAAc,IAAI,2BAA2B,CAAC,CAAC;QACzD,MAAM,GAAG,IAAI,OAAO,GAAG,CAAC;KACzB;IAED,gCAAgC;IAChC,IAAI,GAAG,IAAI,CAAC,GAAG,CAAC,cAAc,CAAC,CAAC;IAChC,IAAI,aAAa,EAAE;QACjB,MAAM,IAAI,IAAI,IAAI,CAAC,IAAI,CAAC,GAAG,CAAC,KAAK,aAAa,SAAS,CAAC;KACzD;SAAM;QACL,MAAM,IAAI,IAAI,IAAI,CAAC,IAAI,CAAC,GAAG,CAAC,GAAG,CAAC;KACjC;IAED,OAAO,MAAM,CAAC;AAChB,CAAC;AAEiB,4CAAgB;AAClC,kBAAe,OAAO,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"logger.d.ts","sourceRoot":"","sources":["../../lib/logger.js"],"names":[],"mappings":";AAGA,wDAA+C"}
|
package/build/lib/logger.js
CHANGED
|
@@ -1,12 +1,6 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
require("source-map-support/register");
|
|
8
|
-
var _support = require("@appium/support");
|
|
9
|
-
const log = _support.logger.getLogger('RemoteDebugger');
|
|
10
|
-
var _default = log;
|
|
11
|
-
exports.default = _default;
|
|
12
|
-
//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJuYW1lcyI6WyJfc3VwcG9ydCIsInJlcXVpcmUiLCJsb2ciLCJsb2dnZXIiLCJnZXRMb2dnZXIiLCJfZGVmYXVsdCIsImV4cG9ydHMiLCJkZWZhdWx0Il0sInNvdXJjZXMiOlsiLi4vLi4vbGliL2xvZ2dlci5qcyJdLCJzb3VyY2VzQ29udGVudCI6WyJpbXBvcnQgeyBsb2dnZXIgfSBmcm9tICdAYXBwaXVtL3N1cHBvcnQnO1xuXG5cbmNvbnN0IGxvZyA9IGxvZ2dlci5nZXRMb2dnZXIoJ1JlbW90ZURlYnVnZ2VyJyk7XG5cbmV4cG9ydCBkZWZhdWx0IGxvZztcbiJdLCJtYXBwaW5ncyI6Ijs7Ozs7OztBQUFBLElBQUFBLFFBQUEsR0FBQUMsT0FBQTtBQUdBLE1BQU1DLEdBQUcsR0FBR0MsZUFBTSxDQUFDQyxTQUFTLENBQUMsZ0JBQWdCLENBQUM7QUFBQyxJQUFBQyxRQUFBLEdBRWhDSCxHQUFHO0FBQUFJLE9BQUEsQ0FBQUMsT0FBQSxHQUFBRixRQUFBIn0=
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
const support_1 = require("@appium/support");
|
|
4
|
+
const log = support_1.logger.getLogger('RemoteDebugger');
|
|
5
|
+
exports.default = log;
|
|
6
|
+
//# sourceMappingURL=logger.js.map
|
package/build/lib/logger.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"logger.js","
|
|
1
|
+
{"version":3,"file":"logger.js","sourceRoot":"","sources":["../../lib/logger.js"],"names":[],"mappings":";;AAAA,6CAAyC;AAGzC,MAAM,GAAG,GAAG,gBAAM,CAAC,SAAS,CAAC,gBAAgB,CAAC,CAAC;AAE/C,kBAAe,GAAG,CAAC"}
|
|
@@ -0,0 +1,125 @@
|
|
|
1
|
+
declare namespace _default {
|
|
2
|
+
export { setConnectionKey };
|
|
3
|
+
export { connect };
|
|
4
|
+
export { disconnect };
|
|
5
|
+
export { selectApp };
|
|
6
|
+
export { searchForApp };
|
|
7
|
+
export { searchForPage };
|
|
8
|
+
export { selectPage };
|
|
9
|
+
export { updateAppsWithDict };
|
|
10
|
+
}
|
|
11
|
+
export default _default;
|
|
12
|
+
export type AppPages = {
|
|
13
|
+
appIdKey: string;
|
|
14
|
+
pageDict: Record<string, any>;
|
|
15
|
+
};
|
|
16
|
+
export type App = {
|
|
17
|
+
id: string;
|
|
18
|
+
bundleId: string;
|
|
19
|
+
};
|
|
20
|
+
/**
|
|
21
|
+
* @typedef {Object} AppPages
|
|
22
|
+
* @property {string} appIdKey
|
|
23
|
+
* @property {Record<string, any>} pageDict
|
|
24
|
+
*/
|
|
25
|
+
/**
|
|
26
|
+
* @typedef {Object} App
|
|
27
|
+
* @property {string} id
|
|
28
|
+
* @property {string} bundleId
|
|
29
|
+
*/
|
|
30
|
+
/**
|
|
31
|
+
*
|
|
32
|
+
* @this {import('../remote-debugger').RemoteDebugger}
|
|
33
|
+
*/
|
|
34
|
+
declare function setConnectionKey(this: import("../remote-debugger").default): Promise<void>;
|
|
35
|
+
/**
|
|
36
|
+
*
|
|
37
|
+
* @this {import('../remote-debugger').RemoteDebugger}
|
|
38
|
+
*/
|
|
39
|
+
declare function connect(this: import("../remote-debugger").default, timeout?: number): Promise<Record<string, any>>;
|
|
40
|
+
/**
|
|
41
|
+
*
|
|
42
|
+
* @this {import('../remote-debugger').RemoteDebugger}
|
|
43
|
+
* @returns {Promise<void>}
|
|
44
|
+
*/
|
|
45
|
+
declare function disconnect(this: import("../remote-debugger").default): Promise<void>;
|
|
46
|
+
/**
|
|
47
|
+
*
|
|
48
|
+
* @this {import('../remote-debugger').RemoteDebugger}
|
|
49
|
+
* @param {string?} currentUrl
|
|
50
|
+
* @param {number} [maxTries]
|
|
51
|
+
* @param {boolean} [ignoreAboutBlankUrl]
|
|
52
|
+
* @returns {Promise<AppPages[]>}
|
|
53
|
+
*/
|
|
54
|
+
declare function selectApp(this: import("../remote-debugger").default, currentUrl?: string | null, maxTries?: number | undefined, ignoreAboutBlankUrl?: boolean | undefined): Promise<AppPages[]>;
|
|
55
|
+
declare class selectApp {
|
|
56
|
+
/**
|
|
57
|
+
*
|
|
58
|
+
* @this {import('../remote-debugger').RemoteDebugger}
|
|
59
|
+
* @param {string?} currentUrl
|
|
60
|
+
* @param {number} [maxTries]
|
|
61
|
+
* @param {boolean} [ignoreAboutBlankUrl]
|
|
62
|
+
* @returns {Promise<AppPages[]>}
|
|
63
|
+
*/
|
|
64
|
+
constructor(this: import("../remote-debugger").default, currentUrl?: string | null, maxTries?: number | undefined, ignoreAboutBlankUrl?: boolean | undefined);
|
|
65
|
+
appIdKey: any;
|
|
66
|
+
}
|
|
67
|
+
/**
|
|
68
|
+
*
|
|
69
|
+
* @this {import('../remote-debugger').RemoteDebugger}
|
|
70
|
+
* @param {string?} currentUrl
|
|
71
|
+
* @param {number} maxTries
|
|
72
|
+
* @param {boolean} ignoreAboutBlankUrl
|
|
73
|
+
* @returns {Promise<AppPages?>}
|
|
74
|
+
*/
|
|
75
|
+
declare function searchForApp(this: import("../remote-debugger").default, currentUrl: string | null, maxTries: number, ignoreAboutBlankUrl: boolean): Promise<AppPages | null>;
|
|
76
|
+
/**
|
|
77
|
+
*
|
|
78
|
+
* @this {import('../remote-debugger').RemoteDebugger}
|
|
79
|
+
* @param {Record<string, any>} appsDict
|
|
80
|
+
* @param {string?} currentUrl
|
|
81
|
+
* @param {boolean} [ignoreAboutBlankUrl]
|
|
82
|
+
* @returns {AppPages?}
|
|
83
|
+
*/
|
|
84
|
+
declare function searchForPage(this: import("../remote-debugger").default, appsDict: Record<string, any>, currentUrl?: string | null, ignoreAboutBlankUrl?: boolean | undefined): AppPages | null;
|
|
85
|
+
/**
|
|
86
|
+
*
|
|
87
|
+
* @this {import('../remote-debugger').RemoteDebugger}
|
|
88
|
+
* @param {string} appIdKey
|
|
89
|
+
* @param {string} pageIdKey
|
|
90
|
+
* @param {boolean} [skipReadyCheck]
|
|
91
|
+
* @returns {Promise<void>}
|
|
92
|
+
*/
|
|
93
|
+
declare function selectPage(this: import("../remote-debugger").default, appIdKey: string, pageIdKey: string, skipReadyCheck?: boolean | undefined): Promise<void>;
|
|
94
|
+
declare class selectPage {
|
|
95
|
+
/**
|
|
96
|
+
*
|
|
97
|
+
* @this {import('../remote-debugger').RemoteDebugger}
|
|
98
|
+
* @param {string} appIdKey
|
|
99
|
+
* @param {string} pageIdKey
|
|
100
|
+
* @param {boolean} [skipReadyCheck]
|
|
101
|
+
* @returns {Promise<void>}
|
|
102
|
+
*/
|
|
103
|
+
constructor(this: import("../remote-debugger").default, appIdKey: string, pageIdKey: string, skipReadyCheck?: boolean | undefined);
|
|
104
|
+
appIdKey: string;
|
|
105
|
+
pageIdKey: string;
|
|
106
|
+
}
|
|
107
|
+
/**
|
|
108
|
+
*
|
|
109
|
+
* @this {import('../remote-debugger').RemoteDebugger}
|
|
110
|
+
* @param {Record<string, any>} dict
|
|
111
|
+
* @returns {void}
|
|
112
|
+
*/
|
|
113
|
+
declare function updateAppsWithDict(this: import("../remote-debugger").default, dict: Record<string, any>): void;
|
|
114
|
+
declare class updateAppsWithDict {
|
|
115
|
+
/**
|
|
116
|
+
*
|
|
117
|
+
* @this {import('../remote-debugger').RemoteDebugger}
|
|
118
|
+
* @param {Record<string, any>} dict
|
|
119
|
+
* @returns {void}
|
|
120
|
+
*/
|
|
121
|
+
constructor(this: import("../remote-debugger").default, dict: Record<string, any>);
|
|
122
|
+
appDict: Record<string, any>;
|
|
123
|
+
appIdKey: string | undefined;
|
|
124
|
+
}
|
|
125
|
+
//# sourceMappingURL=connect.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"connect.d.ts","sourceRoot":"","sources":["../../../lib/mixins/connect.js"],"names":[],"mappings":";;;;;;;;;;;;cAoBc,MAAM;cACN,OAAO,MAAM,EAAE,GAAG,CAAC;;;QAKnB,MAAM;cACN,MAAM;;AATpB;;;;GAIG;AAEH;;;;GAIG;AAGH;;;GAGG;AACH,6FASC;AAED;;;GAGG;AACH,qHA2CC;AAED;;;;GAIG;AACH,yEAFa,QAAQ,IAAI,CAAC,CAQzB;AAED;;;;;;;GAOG;AACH,oFALW,MAAM,oFAGJ,QAAQ,QAAQ,EAAE,CAAC,CA0D/B;;IAhED;;;;;;;OAOG;IACH,qEALW,MAAM,mFA6DhB;IAhCK,cAAwB;;AAkC9B;;;;;;;GAOG;AACH,sFALW,MAAM,mBACN,MAAM,uBACN,OAAO,GACL,QAAQ,QAAQ,QAAE,CAyD9B;AAED;;;;;;;GAOG;AACH,qFALW,OAAO,MAAM,EAAE,GAAG,CAAC,eACnB,MAAM,qDAEJ,QAAQ,QAgBpB;AAED;;;;;;;GAOG;AACH,kFALW,MAAM,aACN,MAAM,yCAEJ,QAAQ,IAAI,CAAC,CAqBzB;;IA3BD;;;;;;;OAOG;IACH,kEALW,MAAM,aACN,MAAM,wCAuBhB;IAlBC,iBAAiC;IACjC,kBAA0B;;AAyD5B;;;;;GAKG;AACH,sFAHW,OAAO,MAAM,EAAE,GAAG,CAAC,GACjB,IAAI,CAsBhB;;IA1BD;;;;;OAKG;IACH,8DAHW,OAAO,MAAM,EAAE,GAAG,CAAC,EAuB7B;IAjBC,6BAAiC;IAe/B,6BAA8D"}
|