@appium/base-driver 8.7.1 → 8.7.3

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.
Files changed (84) hide show
  1. package/build/lib/basedriver/capabilities.d.ts +207 -42
  2. package/build/lib/basedriver/capabilities.d.ts.map +1 -1
  3. package/build/lib/basedriver/capabilities.js +39 -44
  4. package/build/lib/basedriver/capabilities.js.map +1 -0
  5. package/build/lib/basedriver/commands/event.js +3 -3
  6. package/build/lib/basedriver/commands/event.js.map +1 -0
  7. package/build/lib/basedriver/commands/execute.js +3 -3
  8. package/build/lib/basedriver/commands/execute.js.map +1 -0
  9. package/build/lib/basedriver/commands/find.js.map +1 -0
  10. package/build/lib/basedriver/commands/index.js.map +1 -0
  11. package/build/lib/basedriver/commands/log.js +3 -3
  12. package/build/lib/basedriver/commands/log.js.map +1 -0
  13. package/build/lib/basedriver/commands/session.js +3 -3
  14. package/build/lib/basedriver/commands/session.js.map +1 -0
  15. package/build/lib/basedriver/commands/settings.js.map +1 -0
  16. package/build/lib/basedriver/commands/timeout.js +3 -3
  17. package/build/lib/basedriver/commands/timeout.js.map +1 -0
  18. package/build/lib/basedriver/core.d.ts +171 -20
  19. package/build/lib/basedriver/core.d.ts.map +1 -1
  20. package/build/lib/basedriver/core.js +4 -6
  21. package/build/lib/basedriver/core.js.map +1 -0
  22. package/build/lib/basedriver/desired-caps.d.ts +0 -2
  23. package/build/lib/basedriver/desired-caps.d.ts.map +1 -1
  24. package/build/lib/basedriver/desired-caps.js +4 -53
  25. package/build/lib/basedriver/desired-caps.js.map +1 -0
  26. package/build/lib/basedriver/device-settings.js +3 -3
  27. package/build/lib/basedriver/device-settings.js.map +1 -0
  28. package/build/lib/basedriver/driver.d.ts +323 -28
  29. package/build/lib/basedriver/driver.d.ts.map +1 -1
  30. package/build/lib/basedriver/driver.js +27 -30
  31. package/build/lib/basedriver/driver.js.map +1 -0
  32. package/build/lib/basedriver/helpers.d.ts +1 -1
  33. package/build/lib/basedriver/helpers.d.ts.map +1 -1
  34. package/build/lib/basedriver/helpers.js +3 -3
  35. package/build/lib/basedriver/helpers.js.map +1 -0
  36. package/build/lib/basedriver/logger.js.map +1 -0
  37. package/build/lib/constants.js.map +1 -0
  38. package/build/lib/express/crash.js.map +1 -0
  39. package/build/lib/express/express-logging.js +3 -3
  40. package/build/lib/express/express-logging.js.map +1 -0
  41. package/build/lib/express/idempotency.js +3 -3
  42. package/build/lib/express/idempotency.js.map +1 -0
  43. package/build/lib/express/logger.js.map +1 -0
  44. package/build/lib/express/middleware.js +3 -3
  45. package/build/lib/express/middleware.js.map +1 -0
  46. package/build/lib/express/server.js +3 -3
  47. package/build/lib/express/server.js.map +1 -0
  48. package/build/lib/express/static.js +3 -3
  49. package/build/lib/express/static.js.map +1 -0
  50. package/build/lib/express/websocket.js +3 -3
  51. package/build/lib/express/websocket.js.map +1 -0
  52. package/build/lib/helpers/capabilities.d.ts +66 -5
  53. package/build/lib/helpers/capabilities.d.ts.map +1 -1
  54. package/build/lib/helpers/capabilities.js +7 -7
  55. package/build/lib/helpers/capabilities.js.map +1 -0
  56. package/build/lib/index.d.ts +1 -1
  57. package/build/lib/index.d.ts.map +1 -1
  58. package/build/lib/index.js +10 -3
  59. package/build/lib/index.js.map +1 -0
  60. package/build/lib/jsonwp-proxy/protocol-converter.js +3 -3
  61. package/build/lib/jsonwp-proxy/protocol-converter.js.map +1 -0
  62. package/build/lib/jsonwp-proxy/proxy.js +3 -3
  63. package/build/lib/jsonwp-proxy/proxy.js.map +1 -0
  64. package/build/lib/jsonwp-status/status.js +3 -3
  65. package/build/lib/jsonwp-status/status.js.map +1 -0
  66. package/build/lib/protocol/errors.js +3 -3
  67. package/build/lib/protocol/errors.js.map +1 -0
  68. package/build/lib/protocol/helpers.js +3 -3
  69. package/build/lib/protocol/helpers.js.map +1 -0
  70. package/build/lib/protocol/index.js.map +1 -0
  71. package/build/lib/protocol/protocol.js +3 -3
  72. package/build/lib/protocol/protocol.js.map +1 -0
  73. package/build/lib/protocol/routes.js +3 -3
  74. package/build/lib/protocol/routes.js.map +1 -0
  75. package/build/lib/protocol/validators.js +3 -3
  76. package/build/lib/protocol/validators.js.map +1 -0
  77. package/build/tsconfig.tsbuildinfo +1 -1
  78. package/lib/basedriver/capabilities.js +151 -93
  79. package/lib/basedriver/core.js +34 -18
  80. package/lib/basedriver/desired-caps.js +1 -53
  81. package/lib/basedriver/driver.js +113 -51
  82. package/lib/helpers/capabilities.js +19 -9
  83. package/lib/index.js +1 -0
  84. package/package.json +9 -10
@@ -0,0 +1 @@
1
+ {"version":3,"file":"device-settings.js","names":["MAX_SETTINGS_SIZE","DeviceSettings","_settings","_onSettingsUpdate","constructor","defaultSettings","onSettingsUpdate","update","newSettings","_","isPlainObject","errors","InvalidArgumentError","JSON","stringify","node","getObjectSize","util","toReadableSizeString","props","keys","prop","isUndefined","log","debug","getSettings"],"sources":["../../../lib/basedriver/device-settings.js"],"sourcesContent":["import _ from 'lodash';\nimport log from './logger';\nimport {node, util} from '@appium/support';\nimport {errors} from '../protocol/errors';\n\n/**\n * Maximum size (in bytes) of a given driver's settings object (which is internal to {@linkcode DriverSettings}).\n */\nexport const MAX_SETTINGS_SIZE = 20 * 1024 * 1024; // 20 MB\n\n/**\n * @template T\n * @implements {IDeviceSettings<T>}\n */\nclass DeviceSettings {\n /**\n * @protected\n * @type {Record<string,T>}\n */\n _settings;\n\n /**\n * @protected\n * @type {import('@appium/types').SettingsUpdateListener<T>}\n */\n _onSettingsUpdate;\n\n /**\n * Creates a _shallow copy_ of the `defaultSettings` parameter!\n * @param {Record<string,T>} [defaultSettings]\n * @param {import('@appium/types').SettingsUpdateListener<T>} [onSettingsUpdate]\n */\n constructor(defaultSettings = {}, onSettingsUpdate = async () => {}) {\n this._settings = {...defaultSettings};\n this._onSettingsUpdate = onSettingsUpdate;\n }\n\n /**\n * calls updateSettings from implementing driver every time a setting is changed.\n * @param {Record<string,T>} newSettings\n */\n async update(newSettings) {\n if (!_.isPlainObject(newSettings)) {\n throw new errors.InvalidArgumentError(\n `Settings update should be called with valid JSON. Got ` +\n `${JSON.stringify(newSettings)} instead`\n );\n }\n\n if (node.getObjectSize({...this._settings, ...newSettings}) >= MAX_SETTINGS_SIZE) {\n throw new errors.InvalidArgumentError(\n `New settings cannot be applied, because the overall ` +\n `object size exceeds the allowed limit of ${util.toReadableSizeString(MAX_SETTINGS_SIZE)}`\n );\n }\n\n const props = /** @type {(keyof T & string)[]} */ (_.keys(newSettings));\n for (const prop of props) {\n if (!_.isUndefined(this._settings[prop])) {\n if (this._settings[prop] === newSettings[prop]) {\n log.debug(`The value of '${prop}' setting did not change. Skipping the update for it`);\n continue;\n }\n }\n await this._onSettingsUpdate(prop, newSettings[prop], this._settings[prop]);\n this._settings[prop] = newSettings[prop];\n }\n }\n\n getSettings() {\n return this._settings;\n }\n}\n\nexport default DeviceSettings;\nexport {DeviceSettings};\n\n/**\n * @template T\n * @typedef {import('@appium/types').DeviceSettings<T>} IDeviceSettings\n */\n"],"mappings":";;;;;;;;;AAAA;;AACA;;AACA;;AACA;;;;AAKO,MAAMA,iBAAiB,GAAG,KAAK,IAAL,GAAY,IAAtC;;;AAMP,MAAMC,cAAN,CAAqB;EAKnBC,SAAS;EAMTC,iBAAiB;;EAOjBC,WAAW,CAACC,eAAe,GAAG,EAAnB,EAAuBC,gBAAgB,GAAG,YAAY,CAAE,CAAxD,EAA0D;IACnE,KAAKJ,SAAL,GAAiB,EAAC,GAAGG;IAAJ,CAAjB;IACA,KAAKF,iBAAL,GAAyBG,gBAAzB;EACD;;EAMW,MAANC,MAAM,CAACC,WAAD,EAAc;IACxB,IAAI,CAACC,eAAA,CAAEC,aAAF,CAAgBF,WAAhB,CAAL,EAAmC;MACjC,MAAM,IAAIG,cAAA,CAAOC,oBAAX,CACH,wDAAD,GACG,GAAEC,IAAI,CAACC,SAAL,CAAeN,WAAf,CAA4B,UAF7B,CAAN;IAID;;IAED,IAAIO,aAAA,CAAKC,aAAL,CAAmB,EAAC,GAAG,KAAKd,SAAT;MAAoB,GAAGM;IAAvB,CAAnB,KAA2DR,iBAA/D,EAAkF;MAChF,MAAM,IAAIW,cAAA,CAAOC,oBAAX,CACH,sDAAD,GACG,4CAA2CK,aAAA,CAAKC,oBAAL,CAA0BlB,iBAA1B,CAA6C,EAFvF,CAAN;IAID;;IAED,MAAMmB,KAAK,GAAwCV,eAAA,CAAEW,IAAF,CAAOZ,WAAP,CAAnD;;IACA,KAAK,MAAMa,IAAX,IAAmBF,KAAnB,EAA0B;MACxB,IAAI,CAACV,eAAA,CAAEa,WAAF,CAAc,KAAKpB,SAAL,CAAemB,IAAf,CAAd,CAAL,EAA0C;QACxC,IAAI,KAAKnB,SAAL,CAAemB,IAAf,MAAyBb,WAAW,CAACa,IAAD,CAAxC,EAAgD;UAC9CE,eAAA,CAAIC,KAAJ,CAAW,iBAAgBH,IAAK,sDAAhC;;UACA;QACD;MACF;;MACD,MAAM,KAAKlB,iBAAL,CAAuBkB,IAAvB,EAA6Bb,WAAW,CAACa,IAAD,CAAxC,EAAgD,KAAKnB,SAAL,CAAemB,IAAf,CAAhD,CAAN;MACA,KAAKnB,SAAL,CAAemB,IAAf,IAAuBb,WAAW,CAACa,IAAD,CAAlC;IACD;EACF;;EAEDI,WAAW,GAAG;IACZ,OAAO,KAAKvB,SAAZ;EACD;;AAzDkB;;;eA4DND,c"}
@@ -1,10 +1,147 @@
1
1
  /**
2
- * @implements {SessionHandler}
2
+ * @implements {SessionHandler<C>}
3
+ * @template {Constraints} C
4
+ * @template {StringRecord} [CArgs=StringRecord]
5
+ * @extends {DriverCore<C>}
3
6
  */
4
- export class BaseDriverCore extends DriverCore implements SessionHandler {
5
- _constraints: import("@appium/types").Constraints;
6
- /** @type {Record<string,any>|undefined} */
7
- cliArgs: Record<string, any> | undefined;
7
+ export class BaseDriverCore<C extends Readonly<Record<string, import("@appium/types").Constraint>>, CArgs extends import("@appium/types").StringRecord = import("@appium/types").StringRecord> extends DriverCore<C> implements SessionHandler<C> {
8
+ static BASE_DESIRED_CAP_CONSTRAINTS: {
9
+ readonly platformName: {
10
+ readonly presence: true;
11
+ readonly isString: true;
12
+ };
13
+ readonly app: {
14
+ readonly isString: true;
15
+ };
16
+ readonly deviceName: {
17
+ readonly isString: true;
18
+ };
19
+ readonly platformVersion: {
20
+ readonly isString: true;
21
+ };
22
+ readonly newCommandTimeout: {
23
+ readonly isNumber: true;
24
+ };
25
+ readonly automationName: {
26
+ readonly isString: true;
27
+ };
28
+ readonly autoLaunch: {
29
+ readonly isBoolean: true;
30
+ };
31
+ readonly udid: {
32
+ readonly isString: true;
33
+ };
34
+ readonly orientation: {
35
+ readonly inclusion: readonly ["LANDSCAPE", "PORTRAIT"];
36
+ };
37
+ readonly autoWebview: {
38
+ readonly isBoolean: true;
39
+ };
40
+ readonly noReset: {
41
+ readonly isBoolean: true;
42
+ };
43
+ readonly fullReset: {
44
+ readonly isBoolean: true;
45
+ };
46
+ readonly language: {
47
+ readonly isString: true;
48
+ };
49
+ readonly locale: {
50
+ readonly isString: true;
51
+ };
52
+ readonly eventTimings: {
53
+ readonly isBoolean: true;
54
+ };
55
+ readonly printPageSourceOnFindFailure: {
56
+ readonly isBoolean: true;
57
+ };
58
+ };
59
+ /**
60
+ *
61
+ * @param {DriverOpts<C>} opts
62
+ * @param {boolean} shouldValidateCaps
63
+ */
64
+ constructor(opts?: DriverOpts<C>, shouldValidateCaps?: boolean);
65
+ /**
66
+ * @type {CArgs & ServerArgs}
67
+ */
68
+ cliArgs: CArgs & ServerArgs;
69
+ /**
70
+ * @type {Capabilities<C>}
71
+ */
72
+ caps: Capabilities<C>;
73
+ /**
74
+ * @type {W3CCapabilities<C>}
75
+ */
76
+ originalCaps: W3CCapabilities<C>;
77
+ /**
78
+ * @type {C}
79
+ */
80
+ desiredCapConstraints: C;
81
+ /**
82
+ * @type {DriverOpts<C> & DriverOpts<BaseDriverCapConstraints>}
83
+ */
84
+ opts: DriverOpts<C> & DriverOpts<BaseDriverCapConstraints>;
85
+ /**
86
+ * Contains the base constraints plus whatever the subclass wants to add.
87
+ *
88
+ * Subclasses _shouldn't_ need to use this. If you need to use this, please create
89
+ * an issue:
90
+ * @see https://github.com/appium/appium/issues/new
91
+ * @type {Readonly<BaseDriverCapConstraints & C>}
92
+ * @protected
93
+ */
94
+ protected get _desiredCapConstraints(): Readonly<{
95
+ readonly platformName: {
96
+ readonly presence: true;
97
+ readonly isString: true;
98
+ };
99
+ readonly app: {
100
+ readonly isString: true;
101
+ };
102
+ readonly deviceName: {
103
+ readonly isString: true;
104
+ };
105
+ readonly platformVersion: {
106
+ readonly isString: true;
107
+ };
108
+ readonly newCommandTimeout: {
109
+ readonly isNumber: true;
110
+ };
111
+ readonly automationName: {
112
+ readonly isString: true;
113
+ };
114
+ readonly autoLaunch: {
115
+ readonly isBoolean: true;
116
+ };
117
+ readonly udid: {
118
+ readonly isString: true;
119
+ };
120
+ readonly orientation: {
121
+ readonly inclusion: readonly ["LANDSCAPE", "PORTRAIT"];
122
+ };
123
+ readonly autoWebview: {
124
+ readonly isBoolean: true;
125
+ };
126
+ readonly noReset: {
127
+ readonly isBoolean: true;
128
+ };
129
+ readonly fullReset: {
130
+ readonly isBoolean: true;
131
+ };
132
+ readonly language: {
133
+ readonly isString: true;
134
+ };
135
+ readonly locale: {
136
+ readonly isString: true;
137
+ };
138
+ readonly eventTimings: {
139
+ readonly isBoolean: true;
140
+ };
141
+ readonly printPageSourceOnFindFailure: {
142
+ readonly isBoolean: true;
143
+ };
144
+ } & C>;
8
145
  /**
9
146
  * @param {string} cmd
10
147
  * @param {...any} args
@@ -13,9 +150,9 @@ export class BaseDriverCore extends DriverCore implements SessionHandler {
13
150
  executeCommand(cmd: string, ...args: any[]): Promise<any>;
14
151
  /**
15
152
  *
16
- * @param {Error} err
153
+ * @param {Error|import('../protocol/errors').NoSuchDriverError} err
17
154
  */
18
- startUnexpectedShutdown(err?: Error): Promise<void>;
155
+ startUnexpectedShutdown(err?: Error | import('../protocol/errors').NoSuchDriverError): Promise<void>;
19
156
  startNewCommandTimeout(): Promise<void>;
20
157
  /**
21
158
  *
@@ -37,13 +174,13 @@ export class BaseDriverCore extends DriverCore implements SessionHandler {
37
174
  * Appium 2 has dropped the support of these, so now we only accept capability
38
175
  * objects in W3C format and thus allow any of the three arguments to represent
39
176
  * the latter.
40
- * @param {W3CCapabilities} w3cCapabilities1
41
- * @param {W3CCapabilities} [w3cCapabilities2]
42
- * @param {W3CCapabilities} [w3cCapabilities]
177
+ * @param {W3CCapabilities<C>} w3cCapabilities1
178
+ * @param {W3CCapabilities<C>} [w3cCapabilities2]
179
+ * @param {W3CCapabilities<C>} [w3cCapabilities]
43
180
  * @param {DriverData[]} [driverData]
44
- * @returns {Promise<[string,object]>}
181
+ * @returns {Promise<[string,Capabilities<C>]>}
45
182
  */
46
- createSession(w3cCapabilities1: W3CCapabilities, w3cCapabilities2?: W3CCapabilities | undefined, w3cCapabilities?: W3CCapabilities | undefined, driverData?: import("@appium/types").DriverData[] | undefined): Promise<[string, object]>;
183
+ createSession(w3cCapabilities1: W3CCapabilities<C>, w3cCapabilities2?: W3CCapabilities<C, void> | undefined, w3cCapabilities?: W3CCapabilities<C, void> | undefined, driverData?: import("@appium/types").DriverData[] | undefined): Promise<[string, Capabilities<C>]>;
47
184
  /**
48
185
  *
49
186
  * @param {string} [sessionId]
@@ -55,34 +192,192 @@ export class BaseDriverCore extends DriverCore implements SessionHandler {
55
192
  *
56
193
  * @param {Capabilities} caps
57
194
  */
58
- logExtraCaps(caps: Partial<import("@wdio/types/build/Capabilities").Capabilities & import("@wdio/types/build/Capabilities").AppiumCapabilities & {
59
- [x: string]: any;
60
- }>): void;
195
+ logExtraCaps(caps: Capabilities): void;
61
196
  /**
62
197
  *
63
- * @param {Capabilities} caps
198
+ * @param {Capabilities<C>} caps
64
199
  * @returns {boolean}
65
200
  */
66
- validateDesiredCaps(caps: Capabilities): boolean;
67
- set desiredCapConstraints(arg: import("@appium/types").Constraints);
68
- get desiredCapConstraints(): import("@appium/types").Constraints;
201
+ validateDesiredCaps(caps: Capabilities<C>): boolean;
202
+ }
203
+ declare const BaseDriver_base: import("./commands/execute").ExecuteBase;
204
+ /**
205
+ * This ensures that all of the mixins correctly implement the interface described in {@linkcode Driver}.
206
+ * @template {Constraints} [C={}]
207
+ * @implements {Driver<C>}
208
+ */
209
+ export class BaseDriver<C extends Readonly<Record<string, import("@appium/types").Constraint>> = {}> extends BaseDriver_base implements Driver<C> {
210
+ constructor(...arguments_: any[]);
69
211
  }
70
212
  export default BaseDriver;
71
213
  export type HTTPMethod = import('@appium/types').HTTPMethod;
72
- export type Driver = import('@appium/types').Driver;
73
214
  export type ExternalDriver = import('@appium/types').ExternalDriver;
74
- export type Capabilities = import('@appium/types').Capabilities;
75
- export type W3CCapabilities = import('@appium/types').W3CCapabilities;
76
215
  export type DriverData = import('@appium/types').DriverData;
216
+ export type Constraints = import('@appium/types').Constraints;
217
+ export type Constraint = import('@appium/types').Constraint;
218
+ export type StringRecord = import('@appium/types').StringRecord;
219
+ export type BaseDriverCapConstraints = import('@appium/types').BaseDriverCapConstraints;
220
+ export type ServerArgs = import('@appium/types').ServerArgs;
77
221
  export type UpdateServerCallback = (app: import('express').Express, httpServer: import('@appium/types').AppiumServer) => import('type-fest').Promisable<void>;
78
222
  /**
79
223
  * This is used to extend {@linkcode BaseDriverCore } by the mixins and also external drivers.
80
224
  */
81
- export type BaseDriverBase<Proto = {}, Static = {}> = import('@appium/types').Class<BaseDriverCore & Proto, import('@appium/types').DriverStatic & Static>;
82
- export type SessionHandler = import('@appium/types').SessionHandler<[string, object], void>;
225
+ export type BaseDriverBase<Proto = {}, Static = {}> = import('@appium/types').Class<BaseDriverCore<any, import("@appium/types").StringRecord> & Proto, import('@appium/types').DriverStatic & Static>;
226
+ export type SessionHandler<C extends Readonly<Record<string, import("@appium/types").Constraint>> = {
227
+ readonly platformName: {
228
+ readonly presence: true;
229
+ readonly isString: true;
230
+ };
231
+ readonly app: {
232
+ readonly isString: true;
233
+ };
234
+ readonly deviceName: {
235
+ readonly isString: true;
236
+ };
237
+ readonly platformVersion: {
238
+ readonly isString: true;
239
+ };
240
+ readonly newCommandTimeout: {
241
+ readonly isNumber: true;
242
+ };
243
+ readonly automationName: {
244
+ readonly isString: true;
245
+ };
246
+ readonly autoLaunch: {
247
+ readonly isBoolean: true;
248
+ };
249
+ readonly udid: {
250
+ readonly isString: true;
251
+ };
252
+ readonly orientation: {
253
+ readonly inclusion: readonly ["LANDSCAPE", "PORTRAIT"];
254
+ };
255
+ readonly autoWebview: {
256
+ readonly isBoolean: true;
257
+ };
258
+ readonly noReset: {
259
+ readonly isBoolean: true;
260
+ };
261
+ readonly fullReset: {
262
+ readonly isBoolean: true;
263
+ };
264
+ readonly language: {
265
+ readonly isString: true;
266
+ };
267
+ readonly locale: {
268
+ readonly isString: true;
269
+ };
270
+ readonly eventTimings: {
271
+ readonly isBoolean: true;
272
+ };
273
+ readonly printPageSourceOnFindFailure: {
274
+ readonly isBoolean: true;
275
+ };
276
+ }> = import('@appium/types').SessionHandler<[string, object], void, C>;
277
+ export type Capabilities<C extends Readonly<Record<string, import("@appium/types").Constraint>> = {
278
+ readonly platformName: {
279
+ readonly presence: true;
280
+ readonly isString: true;
281
+ };
282
+ readonly app: {
283
+ readonly isString: true;
284
+ };
285
+ readonly deviceName: {
286
+ readonly isString: true;
287
+ };
288
+ readonly platformVersion: {
289
+ readonly isString: true;
290
+ };
291
+ readonly newCommandTimeout: {
292
+ readonly isNumber: true;
293
+ };
294
+ readonly automationName: {
295
+ readonly isString: true;
296
+ };
297
+ readonly autoLaunch: {
298
+ readonly isBoolean: true;
299
+ };
300
+ readonly udid: {
301
+ readonly isString: true;
302
+ };
303
+ readonly orientation: {
304
+ readonly inclusion: readonly ["LANDSCAPE", "PORTRAIT"];
305
+ };
306
+ readonly autoWebview: {
307
+ readonly isBoolean: true;
308
+ };
309
+ readonly noReset: {
310
+ readonly isBoolean: true;
311
+ };
312
+ readonly fullReset: {
313
+ readonly isBoolean: true;
314
+ };
315
+ readonly language: {
316
+ readonly isString: true;
317
+ };
318
+ readonly locale: {
319
+ readonly isString: true;
320
+ };
321
+ readonly eventTimings: {
322
+ readonly isBoolean: true;
323
+ };
324
+ readonly printPageSourceOnFindFailure: {
325
+ readonly isBoolean: true;
326
+ };
327
+ }, Extra extends void | import("@appium/types").StringRecord = void> = import('@appium/types').Capabilities<C, Extra>;
328
+ export type W3CCapabilities<C extends Readonly<Record<string, import("@appium/types").Constraint>> = {
329
+ readonly platformName: {
330
+ readonly presence: true;
331
+ readonly isString: true;
332
+ };
333
+ readonly app: {
334
+ readonly isString: true;
335
+ };
336
+ readonly deviceName: {
337
+ readonly isString: true;
338
+ };
339
+ readonly platformVersion: {
340
+ readonly isString: true;
341
+ };
342
+ readonly newCommandTimeout: {
343
+ readonly isNumber: true;
344
+ };
345
+ readonly automationName: {
346
+ readonly isString: true;
347
+ };
348
+ readonly autoLaunch: {
349
+ readonly isBoolean: true;
350
+ };
351
+ readonly udid: {
352
+ readonly isString: true;
353
+ };
354
+ readonly orientation: {
355
+ readonly inclusion: readonly ["LANDSCAPE", "PORTRAIT"];
356
+ };
357
+ readonly autoWebview: {
358
+ readonly isBoolean: true;
359
+ };
360
+ readonly noReset: {
361
+ readonly isBoolean: true;
362
+ };
363
+ readonly fullReset: {
364
+ readonly isBoolean: true;
365
+ };
366
+ readonly language: {
367
+ readonly isString: true;
368
+ };
369
+ readonly locale: {
370
+ readonly isString: true;
371
+ };
372
+ readonly eventTimings: {
373
+ readonly isBoolean: true;
374
+ };
375
+ readonly printPageSourceOnFindFailure: {
376
+ readonly isBoolean: true;
377
+ };
378
+ }, Extra extends void | import("@appium/types").StringRecord = void> = import('@appium/types').W3CCapabilities<C, Extra>;
379
+ export type ConstraintsToCaps<C extends Readonly<Record<string, import("@appium/types").Constraint>>> = import('@appium/types').ConstraintsToCaps<C>;
380
+ export type Driver<C extends Readonly<Record<string, import("@appium/types").Constraint>>> = import('@appium/types').Driver<C>;
381
+ export type DriverOpts<C extends Readonly<Record<string, import("@appium/types").Constraint>>> = import('@appium/types').DriverOpts<C>;
83
382
  import { DriverCore } from "./core";
84
- /**
85
- * @type {import('@appium/types').DriverClass<Driver>}
86
- */
87
- export const BaseDriver: import('@appium/types').DriverClass<Driver>;
88
383
  //# sourceMappingURL=driver.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"driver.d.ts","sourceRoot":"","sources":["../../../lib/basedriver/driver.js"],"names":[],"mappings":"AA0BA;;GAEG;AACH;IACE,kDAAyD;IAEzD,2CAA2C;IAC3C,SADW,OAAO,MAAM,EAAC,GAAG,CAAC,GAAC,SAAS,CAC/B;IAMR;;;;OAIG;IACH,oBAJW,MAAM,WACF,GAAG,KACL,QAAQ,GAAG,CAAC,CAsExB;IAED;;;OAGG;IACH,8BAFW,KAAK,iBAcf;IAED,wCAmBC;IAED;;;;;;OAMG;IACH,qBALW,OAAO,eAAe,EAAE,YAAY,QACpC,MAAM,QACN,MAAM,QACN,MAAM,QAOhB;IAJC,yDAAoB;IACpB,+BAAsB;IACtB,+BAAsB;IACtB,+BAAsB;IAOxB,uBA+BC;IAfC,oDAAyC;IAiB3C;;;;;;;;;;;OAWG;IACH,gCANW,eAAe,iKAIb,QAAQ,CAAC,MAAM,EAAC,MAAM,CAAC,CAAC,CAoFpC;IAED;;;;;OAKG;IACH,8GAFa,QAAQ,IAAI,CAAC,CAczB;IAED;;;OAGG;IACH;;cAUC;IAED;;;;OAIG;IACH,0BAHW,YAAY,GACV,OAAO,CAqBnB;IAGD,oEAWC;IAED,iEAEC;CACF;;yBAiBY,OAAO,eAAe,EAAE,UAAU;qBAClC,OAAO,eAAe,EAAE,MAAM;6BAC9B,OAAO,eAAe,EAAE,cAAc;2BACtC,OAAO,eAAe,EAAE,YAAY;8BACpC,OAAO,eAAe,EAAE,eAAe;yBACvC,OAAO,eAAe,EAAE,UAAU;yCAKpC,OAAO,SAAS,EAAE,OAAO,cACzB,OAAO,eAAe,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