appium-android-driver 5.14.7 → 6.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/build/index.d.ts +282 -0
- package/build/index.d.ts.map +1 -0
- package/build/index.js.map +1 -0
- package/build/lib/commands/actions.d.ts +6 -224
- package/build/lib/commands/actions.d.ts.map +1 -1
- package/build/lib/commands/actions.js +306 -405
- package/build/lib/commands/actions.js.map +1 -1
- package/build/lib/commands/alert.d.ts +7 -9
- package/build/lib/commands/alert.d.ts.map +1 -1
- package/build/lib/commands/alert.js +24 -18
- package/build/lib/commands/alert.js.map +1 -1
- package/build/lib/commands/app-management.d.ts +7 -313
- package/build/lib/commands/app-management.d.ts.map +1 -1
- package/build/lib/commands/app-management.js +135 -293
- package/build/lib/commands/app-management.js.map +1 -1
- package/build/lib/commands/context.d.ts +8 -92
- package/build/lib/commands/context.d.ts.map +1 -1
- package/build/lib/commands/context.js +381 -439
- package/build/lib/commands/context.js.map +1 -1
- package/build/lib/commands/element.d.ts +8 -35
- package/build/lib/commands/element.d.ts.map +1 -1
- package/build/lib/commands/element.js +153 -136
- package/build/lib/commands/element.js.map +1 -1
- package/build/lib/commands/emu-console.d.ts +6 -48
- package/build/lib/commands/emu-console.d.ts.map +1 -1
- package/build/lib/commands/emu-console.js +19 -34
- package/build/lib/commands/emu-console.js.map +1 -1
- package/build/lib/commands/execute.d.ts +6 -5
- package/build/lib/commands/execute.d.ts.map +1 -1
- package/build/lib/commands/execute.js +77 -66
- package/build/lib/commands/execute.js.map +1 -1
- package/build/lib/commands/file-actions.d.ts +7 -128
- package/build/lib/commands/file-actions.d.ts.map +1 -1
- package/build/lib/commands/file-actions.js +183 -219
- package/build/lib/commands/file-actions.js.map +1 -1
- package/build/lib/commands/find.d.ts +8 -12
- package/build/lib/commands/find.d.ts.map +1 -1
- package/build/lib/commands/find.js +19 -23
- package/build/lib/commands/find.js.map +1 -1
- package/build/lib/commands/general.d.ts +9 -132
- package/build/lib/commands/general.d.ts.map +1 -1
- package/build/lib/commands/general.js +281 -312
- package/build/lib/commands/general.js.map +1 -1
- package/build/lib/commands/ime.d.ts +7 -10
- package/build/lib/commands/ime.d.ts.map +1 -1
- package/build/lib/commands/ime.js +47 -35
- package/build/lib/commands/ime.js.map +1 -1
- package/build/lib/commands/index.d.ts +27 -2
- package/build/lib/commands/index.d.ts.map +1 -1
- package/build/lib/commands/index.js +41 -19
- package/build/lib/commands/index.js.map +1 -1
- package/build/lib/commands/intent.d.ts +7 -417
- package/build/lib/commands/intent.d.ts.map +1 -1
- package/build/lib/commands/intent.js +104 -216
- package/build/lib/commands/intent.js.map +1 -1
- package/build/lib/commands/keyboard.d.ts +6 -5
- package/build/lib/commands/keyboard.d.ts.map +1 -1
- package/build/lib/commands/keyboard.js +16 -8
- package/build/lib/commands/keyboard.js.map +1 -1
- package/build/lib/commands/log.d.ts +7 -44
- package/build/lib/commands/log.d.ts.map +1 -1
- package/build/lib/commands/log.js +146 -108
- package/build/lib/commands/log.js.map +1 -1
- package/build/lib/commands/media-projection.d.ts +7 -143
- package/build/lib/commands/media-projection.d.ts.map +1 -1
- package/build/lib/commands/media-projection.js +113 -140
- package/build/lib/commands/media-projection.js.map +1 -1
- package/build/lib/commands/mixins.d.ts +740 -0
- package/build/lib/commands/mixins.d.ts.map +1 -0
- package/build/lib/commands/mixins.js +19 -0
- package/build/lib/commands/mixins.js.map +1 -0
- package/build/lib/commands/network.d.ts +7 -138
- package/build/lib/commands/network.d.ts.map +1 -1
- package/build/lib/commands/network.js +212 -254
- package/build/lib/commands/network.js.map +1 -1
- package/build/lib/commands/performance.d.ts +24 -70
- package/build/lib/commands/performance.d.ts.map +1 -1
- package/build/lib/commands/performance.js +144 -100
- package/build/lib/commands/performance.js.map +1 -1
- package/build/lib/commands/permissions.d.ts +8 -92
- package/build/lib/commands/permissions.d.ts.map +1 -1
- package/build/lib/commands/permissions.js +75 -87
- package/build/lib/commands/permissions.js.map +1 -1
- package/build/lib/commands/recordscreen.d.ts +7 -193
- package/build/lib/commands/recordscreen.d.ts.map +1 -1
- package/build/lib/commands/recordscreen.js +151 -182
- package/build/lib/commands/recordscreen.js.map +1 -1
- package/build/lib/commands/shell.d.ts +7 -7
- package/build/lib/commands/shell.d.ts.map +1 -1
- package/build/lib/commands/shell.js +40 -33
- package/build/lib/commands/shell.js.map +1 -1
- package/build/lib/commands/streamscreen.d.ts +9 -103
- package/build/lib/commands/streamscreen.d.ts.map +1 -1
- package/build/lib/commands/streamscreen.js +261 -218
- package/build/lib/commands/streamscreen.js.map +1 -1
- package/build/lib/commands/system-bars.d.ts +22 -90
- package/build/lib/commands/system-bars.d.ts.map +1 -1
- package/build/lib/commands/system-bars.js +76 -74
- package/build/lib/commands/system-bars.js.map +1 -1
- package/build/lib/commands/touch.d.ts +10 -29
- package/build/lib/commands/touch.d.ts.map +1 -1
- package/build/lib/commands/touch.js +301 -285
- package/build/lib/commands/touch.js.map +1 -1
- package/build/lib/commands/types.d.ts +978 -0
- package/build/lib/commands/types.d.ts.map +1 -0
- package/build/lib/commands/types.js +3 -0
- package/build/lib/commands/types.js.map +1 -0
- package/build/lib/constraints.d.ts +291 -0
- package/build/lib/constraints.d.ts.map +1 -0
- package/build/lib/constraints.js +300 -0
- package/build/lib/constraints.js.map +1 -0
- package/build/lib/driver.d.ts +68 -37
- package/build/lib/driver.d.ts.map +1 -1
- package/build/lib/driver.js +123 -80
- package/build/lib/driver.js.map +1 -1
- package/build/lib/helpers/android.d.ts +164 -0
- package/build/lib/helpers/android.d.ts.map +1 -0
- package/build/lib/helpers/android.js +819 -0
- package/build/lib/helpers/android.js.map +1 -0
- package/build/lib/helpers/index.d.ts +7 -0
- package/build/lib/helpers/index.d.ts.map +1 -0
- package/build/lib/helpers/index.js +29 -0
- package/build/lib/helpers/index.js.map +1 -0
- package/build/lib/helpers/types.d.ts +121 -0
- package/build/lib/helpers/types.d.ts.map +1 -0
- package/build/lib/helpers/types.js +3 -0
- package/build/lib/helpers/types.js.map +1 -0
- package/build/lib/helpers/unlock.d.ts +32 -0
- package/build/lib/helpers/unlock.d.ts.map +1 -0
- package/build/lib/helpers/unlock.js +273 -0
- package/build/lib/helpers/unlock.js.map +1 -0
- package/build/lib/helpers/webview.d.ts +74 -0
- package/build/lib/helpers/webview.d.ts.map +1 -0
- package/build/lib/helpers/webview.js +421 -0
- package/build/lib/helpers/webview.js.map +1 -0
- package/build/lib/index.d.ts +9 -0
- package/build/lib/index.d.ts.map +1 -0
- package/build/lib/index.js +37 -0
- package/build/lib/index.js.map +1 -0
- package/build/lib/method-map.d.ts +0 -8
- package/build/lib/method-map.d.ts.map +1 -1
- package/build/lib/method-map.js +63 -74
- package/build/lib/method-map.js.map +1 -1
- package/build/lib/stubs.d.ts +0 -1
- package/build/lib/stubs.d.ts.map +1 -1
- package/build/lib/stubs.js +1 -0
- package/build/lib/stubs.js.map +1 -1
- package/build/lib/utils.d.ts +1 -1
- package/build/lib/utils.d.ts.map +1 -1
- package/lib/commands/actions.js +351 -464
- package/lib/commands/alert.js +27 -17
- package/lib/commands/app-management.js +156 -314
- package/lib/commands/context.js +457 -441
- package/lib/commands/element.js +201 -157
- package/lib/commands/emu-console.js +25 -45
- package/lib/commands/execute.js +106 -90
- package/lib/commands/file-actions.js +222 -240
- package/lib/commands/find.ts +103 -0
- package/lib/commands/general.js +327 -339
- package/lib/commands/ime.js +50 -34
- package/lib/commands/{index.js → index.ts} +20 -24
- package/lib/commands/intent.js +108 -249
- package/lib/commands/keyboard.js +20 -8
- package/lib/commands/log.js +172 -116
- package/lib/commands/media-projection.js +134 -161
- package/lib/commands/mixins.ts +966 -0
- package/lib/commands/network.js +252 -281
- package/lib/commands/performance.js +203 -132
- package/lib/commands/permissions.js +108 -109
- package/lib/commands/recordscreen.js +212 -209
- package/lib/commands/shell.js +51 -40
- package/lib/commands/streamscreen.js +355 -289
- package/lib/commands/system-bars.js +92 -83
- package/lib/commands/touch.js +357 -294
- package/lib/commands/types.ts +1097 -0
- package/lib/{desired-caps.js → constraints.ts} +106 -103
- package/lib/{driver.js → driver.ts} +278 -132
- package/lib/helpers/android.ts +1143 -0
- package/lib/helpers/index.ts +6 -0
- package/lib/helpers/types.ts +134 -0
- package/lib/helpers/unlock.ts +329 -0
- package/lib/helpers/webview.ts +582 -0
- package/lib/index.ts +18 -0
- package/lib/method-map.js +87 -98
- package/lib/stubs.ts +0 -1
- package/package.json +27 -20
- package/index.js +0 -24
- package/lib/android-helpers.js +0 -983
- package/lib/commands/coverage.js +0 -18
- package/lib/commands/find.js +0 -82
- package/lib/unlock-helpers.js +0 -278
- package/lib/webview-helpers.js +0 -602
package/lib/method-map.js
CHANGED
|
@@ -1,169 +1,164 @@
|
|
|
1
1
|
export const newMethodMap = /** @type {const} */ ({
|
|
2
2
|
'/session/:sessionId/timeouts/implicit_wait': {
|
|
3
|
-
POST: {
|
|
3
|
+
POST: {command: 'implicitWait', payloadParams: {required: ['ms']}},
|
|
4
4
|
},
|
|
5
|
-
'/session/:sessionId/ime/available_engines': {
|
|
6
|
-
'/session/:sessionId/ime/active_engine': {
|
|
7
|
-
'/session/:sessionId/ime/activated': {
|
|
8
|
-
'/session/:sessionId/ime/deactivate': {
|
|
5
|
+
'/session/:sessionId/ime/available_engines': {GET: {command: 'availableIMEEngines'}},
|
|
6
|
+
'/session/:sessionId/ime/active_engine': {GET: {command: 'getActiveIMEEngine'}},
|
|
7
|
+
'/session/:sessionId/ime/activated': {GET: {command: 'isIMEActivated'}},
|
|
8
|
+
'/session/:sessionId/ime/deactivate': {POST: {command: 'deactivateIMEEngine'}},
|
|
9
9
|
'/session/:sessionId/ime/activate': {
|
|
10
10
|
POST: {
|
|
11
11
|
command: 'activateIMEEngine',
|
|
12
|
-
payloadParams: {
|
|
13
|
-
}
|
|
12
|
+
payloadParams: {required: ['engine']},
|
|
13
|
+
},
|
|
14
14
|
},
|
|
15
|
-
'/session/:sessionId/window/:windowhandle/size': {
|
|
15
|
+
'/session/:sessionId/window/:windowhandle/size': {GET: {command: 'getWindowSize'}},
|
|
16
16
|
'/session/:sessionId/keys': {
|
|
17
|
-
POST: {
|
|
17
|
+
POST: {command: 'keys', payloadParams: {required: ['value']}},
|
|
18
18
|
},
|
|
19
|
-
'/session/:sessionId/element/:elementId/location': {
|
|
20
|
-
'/session/:sessionId/element/:elementId/location_in_view': {
|
|
21
|
-
'/session/:sessionId/element/:elementId/size': {
|
|
19
|
+
'/session/:sessionId/element/:elementId/location': {GET: {command: 'getLocation'}},
|
|
20
|
+
'/session/:sessionId/element/:elementId/location_in_view': {GET: {command: 'getLocationInView'}},
|
|
21
|
+
'/session/:sessionId/element/:elementId/size': {GET: {command: 'getSize'}},
|
|
22
22
|
'/session/:sessionId/touch/click': {
|
|
23
|
-
POST: {
|
|
23
|
+
POST: {command: 'click', payloadParams: {required: ['element']}},
|
|
24
24
|
},
|
|
25
25
|
'/session/:sessionId/touch/down': {
|
|
26
|
-
POST: {
|
|
26
|
+
POST: {command: 'touchDown', payloadParams: {required: ['x', 'y']}},
|
|
27
27
|
},
|
|
28
28
|
'/session/:sessionId/touch/up': {
|
|
29
|
-
POST: {
|
|
29
|
+
POST: {command: 'touchUp', payloadParams: {required: ['x', 'y']}},
|
|
30
30
|
},
|
|
31
31
|
'/session/:sessionId/touch/move': {
|
|
32
|
-
POST: {
|
|
32
|
+
POST: {command: 'touchMove', payloadParams: {required: ['x', 'y']}},
|
|
33
33
|
},
|
|
34
34
|
'/session/:sessionId/touch/longclick': {
|
|
35
35
|
POST: {
|
|
36
36
|
command: 'touchLongClick',
|
|
37
|
-
payloadParams: {
|
|
38
|
-
}
|
|
37
|
+
payloadParams: {required: ['elements']},
|
|
38
|
+
},
|
|
39
39
|
},
|
|
40
40
|
'/session/:sessionId/touch/flick': {
|
|
41
41
|
POST: {
|
|
42
42
|
command: 'flick',
|
|
43
43
|
payloadParams: {
|
|
44
|
-
optional: [
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
'yspeed',
|
|
48
|
-
'xoffset',
|
|
49
|
-
'yoffset',
|
|
50
|
-
'speed'
|
|
51
|
-
]
|
|
52
|
-
}
|
|
53
|
-
}
|
|
44
|
+
optional: ['element', 'xspeed', 'yspeed', 'xoffset', 'yoffset', 'speed'],
|
|
45
|
+
},
|
|
46
|
+
},
|
|
54
47
|
},
|
|
55
48
|
'/session/:sessionId/touch/perform': {
|
|
56
49
|
POST: {
|
|
57
50
|
command: 'performTouch',
|
|
58
|
-
payloadParams: {
|
|
59
|
-
}
|
|
51
|
+
payloadParams: {wrap: 'actions', required: ['actions']},
|
|
52
|
+
},
|
|
60
53
|
},
|
|
61
54
|
'/session/:sessionId/touch/multi/perform': {
|
|
62
55
|
POST: {
|
|
63
56
|
command: 'performMultiAction',
|
|
64
|
-
payloadParams: {
|
|
65
|
-
}
|
|
57
|
+
payloadParams: {required: ['actions'], optional: ['elementId']},
|
|
58
|
+
},
|
|
66
59
|
},
|
|
67
60
|
'/session/:sessionId/appium/device/lock': {
|
|
68
|
-
POST: {
|
|
61
|
+
POST: {command: 'lock', payloadParams: {optional: ['seconds']}},
|
|
69
62
|
},
|
|
70
|
-
'/session/:sessionId/appium/device/unlock': {
|
|
71
|
-
'/session/:sessionId/appium/device/is_locked': {
|
|
63
|
+
'/session/:sessionId/appium/device/unlock': {POST: {command: 'unlock'}},
|
|
64
|
+
'/session/:sessionId/appium/device/is_locked': {POST: {command: 'isLocked'}},
|
|
72
65
|
'/session/:sessionId/appium/start_recording_screen': {
|
|
73
66
|
POST: {
|
|
74
67
|
command: 'startRecordingScreen',
|
|
75
|
-
payloadParams: {
|
|
76
|
-
}
|
|
68
|
+
payloadParams: {optional: ['options']},
|
|
69
|
+
},
|
|
77
70
|
},
|
|
78
71
|
'/session/:sessionId/appium/stop_recording_screen': {
|
|
79
72
|
POST: {
|
|
80
73
|
command: 'stopRecordingScreen',
|
|
81
|
-
payloadParams: {
|
|
82
|
-
}
|
|
74
|
+
payloadParams: {optional: ['options']},
|
|
75
|
+
},
|
|
83
76
|
},
|
|
84
|
-
'/session/:sessionId/appium/performanceData/types': {
|
|
77
|
+
'/session/:sessionId/appium/performanceData/types': {POST: {command: 'getPerformanceDataTypes'}},
|
|
85
78
|
'/session/:sessionId/appium/getPerformanceData': {
|
|
86
79
|
POST: {
|
|
87
80
|
command: 'getPerformanceData',
|
|
88
81
|
payloadParams: {
|
|
89
82
|
required: ['packageName', 'dataType'],
|
|
90
|
-
optional: ['dataReadTimeout']
|
|
91
|
-
}
|
|
92
|
-
}
|
|
83
|
+
optional: ['dataReadTimeout'],
|
|
84
|
+
},
|
|
85
|
+
},
|
|
93
86
|
},
|
|
94
87
|
'/session/:sessionId/appium/device/press_keycode': {
|
|
95
88
|
POST: {
|
|
96
89
|
command: 'pressKeyCode',
|
|
97
|
-
payloadParams: {
|
|
98
|
-
}
|
|
90
|
+
payloadParams: {required: ['keycode'], optional: ['metastate', 'flags']},
|
|
91
|
+
},
|
|
99
92
|
},
|
|
100
93
|
'/session/:sessionId/appium/device/long_press_keycode': {
|
|
101
94
|
POST: {
|
|
102
95
|
command: 'longPressKeyCode',
|
|
103
|
-
payloadParams: {
|
|
104
|
-
}
|
|
96
|
+
payloadParams: {required: ['keycode'], optional: ['metastate', 'flags']},
|
|
97
|
+
},
|
|
105
98
|
},
|
|
106
99
|
'/session/:sessionId/appium/device/finger_print': {
|
|
107
100
|
POST: {
|
|
108
101
|
command: 'fingerprint',
|
|
109
|
-
payloadParams: {
|
|
110
|
-
}
|
|
102
|
+
payloadParams: {required: ['fingerprintId']},
|
|
103
|
+
},
|
|
111
104
|
},
|
|
112
105
|
'/session/:sessionId/appium/device/send_sms': {
|
|
113
106
|
POST: {
|
|
114
107
|
command: 'sendSMS',
|
|
115
|
-
payloadParams: {
|
|
116
|
-
}
|
|
108
|
+
payloadParams: {required: ['phoneNumber', 'message']},
|
|
109
|
+
},
|
|
117
110
|
},
|
|
118
111
|
'/session/:sessionId/appium/device/gsm_call': {
|
|
119
112
|
POST: {
|
|
120
113
|
command: 'gsmCall',
|
|
121
|
-
payloadParams: {
|
|
122
|
-
}
|
|
114
|
+
payloadParams: {required: ['phoneNumber', 'action']},
|
|
115
|
+
},
|
|
123
116
|
},
|
|
124
117
|
'/session/:sessionId/appium/device/gsm_signal': {
|
|
125
118
|
POST: {
|
|
126
119
|
command: 'gsmSignal',
|
|
127
|
-
payloadParams: {
|
|
128
|
-
}
|
|
120
|
+
payloadParams: {required: ['signalStrength']},
|
|
121
|
+
},
|
|
129
122
|
},
|
|
130
123
|
'/session/:sessionId/appium/device/gsm_voice': {
|
|
131
|
-
POST: {
|
|
124
|
+
POST: {command: 'gsmVoice', payloadParams: {required: ['state']}},
|
|
132
125
|
},
|
|
133
126
|
'/session/:sessionId/appium/device/power_capacity': {
|
|
134
127
|
POST: {
|
|
135
128
|
command: 'powerCapacity',
|
|
136
|
-
payloadParams: {
|
|
137
|
-
}
|
|
129
|
+
payloadParams: {required: ['percent']},
|
|
130
|
+
},
|
|
138
131
|
},
|
|
139
132
|
'/session/:sessionId/appium/device/power_ac': {
|
|
140
|
-
POST: {
|
|
133
|
+
POST: {command: 'powerAC', payloadParams: {required: ['state']}},
|
|
141
134
|
},
|
|
142
135
|
'/session/:sessionId/appium/device/network_speed': {
|
|
143
136
|
POST: {
|
|
144
137
|
command: 'networkSpeed',
|
|
145
|
-
payloadParams: {
|
|
146
|
-
}
|
|
138
|
+
payloadParams: {required: ['netspeed']},
|
|
139
|
+
},
|
|
147
140
|
},
|
|
148
141
|
'/session/:sessionId/appium/device/keyevent': {
|
|
149
142
|
POST: {
|
|
150
143
|
command: 'keyevent',
|
|
151
|
-
payloadParams: {
|
|
152
|
-
}
|
|
144
|
+
payloadParams: {required: ['keycode'], optional: ['metastate']},
|
|
145
|
+
},
|
|
153
146
|
},
|
|
154
|
-
'/session/:sessionId/appium/device/current_activity': {
|
|
155
|
-
'/session/:sessionId/appium/device/current_package': {
|
|
147
|
+
'/session/:sessionId/appium/device/current_activity': {GET: {command: 'getCurrentActivity'}},
|
|
148
|
+
'/session/:sessionId/appium/device/current_package': {GET: {command: 'getCurrentPackage'}},
|
|
156
149
|
'/session/:sessionId/appium/device/app_state': {
|
|
157
150
|
POST: {
|
|
158
151
|
command: 'queryAppState',
|
|
159
|
-
payloadParams: {
|
|
160
|
-
}
|
|
161
|
-
},
|
|
162
|
-
'/session/:sessionId/appium/device/toggle_airplane_mode': {
|
|
163
|
-
'/session/:sessionId/appium/device/toggle_data': {
|
|
164
|
-
'/session/:sessionId/appium/device/toggle_wifi': {
|
|
165
|
-
'/session/:sessionId/appium/device/toggle_location_services': {
|
|
166
|
-
|
|
152
|
+
payloadParams: {required: [['appId'], ['bundleId']]},
|
|
153
|
+
},
|
|
154
|
+
},
|
|
155
|
+
'/session/:sessionId/appium/device/toggle_airplane_mode': {POST: {command: 'toggleFlightMode'}},
|
|
156
|
+
'/session/:sessionId/appium/device/toggle_data': {POST: {command: 'toggleData'}},
|
|
157
|
+
'/session/:sessionId/appium/device/toggle_wifi': {POST: {command: 'toggleWiFi'}},
|
|
158
|
+
'/session/:sessionId/appium/device/toggle_location_services': {
|
|
159
|
+
POST: {command: 'toggleLocationServices'},
|
|
160
|
+
},
|
|
161
|
+
'/session/:sessionId/appium/device/open_notifications': {POST: {command: 'openNotifications'}},
|
|
167
162
|
'/session/:sessionId/appium/device/start_activity': {
|
|
168
163
|
POST: {
|
|
169
164
|
command: 'startActivity',
|
|
@@ -176,44 +171,38 @@ export const newMethodMap = /** @type {const} */ ({
|
|
|
176
171
|
'intentCategory',
|
|
177
172
|
'intentFlags',
|
|
178
173
|
'optionalIntentArguments',
|
|
179
|
-
'dontStopAppOnReset'
|
|
180
|
-
]
|
|
181
|
-
}
|
|
182
|
-
}
|
|
183
|
-
},
|
|
184
|
-
'/session/:sessionId/appium/device/system_bars': {
|
|
185
|
-
'/session/:sessionId/appium/device/display_density': {
|
|
186
|
-
'/session/:sessionId/appium/app/launch': {
|
|
187
|
-
'/session/:sessionId/appium/app/close': {
|
|
188
|
-
'/session/:sessionId/appium/app/reset': {
|
|
174
|
+
'dontStopAppOnReset',
|
|
175
|
+
],
|
|
176
|
+
},
|
|
177
|
+
},
|
|
178
|
+
},
|
|
179
|
+
'/session/:sessionId/appium/device/system_bars': {GET: {command: 'getSystemBars'}},
|
|
180
|
+
'/session/:sessionId/appium/device/display_density': {GET: {command: 'getDisplayDensity'}},
|
|
181
|
+
'/session/:sessionId/appium/app/launch': {POST: {command: 'launchApp'}},
|
|
182
|
+
'/session/:sessionId/appium/app/close': {POST: {command: 'closeApp'}},
|
|
183
|
+
'/session/:sessionId/appium/app/reset': {POST: {command: 'reset'}},
|
|
189
184
|
'/session/:sessionId/appium/app/background': {
|
|
190
185
|
POST: {
|
|
191
186
|
command: 'background',
|
|
192
|
-
payloadParams: {
|
|
193
|
-
}
|
|
194
|
-
},
|
|
195
|
-
'/session/:sessionId/appium/app/end_test_coverage': {
|
|
196
|
-
POST: {
|
|
197
|
-
command: 'endCoverage',
|
|
198
|
-
payloadParams: { required: ['intent', 'path'] }
|
|
199
|
-
}
|
|
187
|
+
payloadParams: {required: ['seconds']},
|
|
188
|
+
},
|
|
200
189
|
},
|
|
201
190
|
'/session/:sessionId/appium/app/strings': {
|
|
202
191
|
POST: {
|
|
203
192
|
command: 'getStrings',
|
|
204
|
-
payloadParams: {
|
|
205
|
-
}
|
|
193
|
+
payloadParams: {optional: ['language', 'stringFile']},
|
|
194
|
+
},
|
|
206
195
|
},
|
|
207
196
|
'/session/:sessionId/appium/element/:elementId/value': {
|
|
208
197
|
POST: {
|
|
209
198
|
command: 'setValueImmediate',
|
|
210
|
-
payloadParams: {
|
|
211
|
-
}
|
|
199
|
+
payloadParams: {required: ['text']},
|
|
200
|
+
},
|
|
212
201
|
},
|
|
213
202
|
'/session/:sessionId/appium/element/:elementId/replace_value': {
|
|
214
203
|
POST: {
|
|
215
204
|
command: 'replaceValue',
|
|
216
|
-
payloadParams: {
|
|
217
|
-
}
|
|
218
|
-
}
|
|
205
|
+
payloadParams: {required: ['text']},
|
|
206
|
+
},
|
|
207
|
+
},
|
|
219
208
|
});
|
package/lib/stubs.ts
CHANGED
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "appium-android-driver",
|
|
3
|
-
"version": "
|
|
3
|
+
"version": "6.0.0",
|
|
4
4
|
"description": "Android UiAutomator and Chrome support for Appium",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"appium",
|
|
@@ -19,18 +19,18 @@
|
|
|
19
19
|
},
|
|
20
20
|
"license": "Apache-2.0",
|
|
21
21
|
"author": "Appium Contributors",
|
|
22
|
-
"main": "./build/index.js",
|
|
22
|
+
"main": "./build/lib/index.js",
|
|
23
23
|
"bin": {},
|
|
24
24
|
"directories": {
|
|
25
25
|
"lib": "lib"
|
|
26
26
|
},
|
|
27
27
|
"files": [
|
|
28
|
-
"index.js",
|
|
29
28
|
"lib",
|
|
30
|
-
"build
|
|
31
|
-
"build/lib",
|
|
29
|
+
"build",
|
|
32
30
|
"bootstrap/bin/AppiumBootstrap.jar",
|
|
33
|
-
"CHANGELOG.md"
|
|
31
|
+
"CHANGELOG.md",
|
|
32
|
+
"!build/test",
|
|
33
|
+
"!build/tsconfig.tsbuildinfo"
|
|
34
34
|
],
|
|
35
35
|
"scripts": {
|
|
36
36
|
"build": "tsc -b",
|
|
@@ -41,8 +41,8 @@
|
|
|
41
41
|
"lint:commit": "commitlint",
|
|
42
42
|
"lint:fix": "npm run lint -- --fix",
|
|
43
43
|
"lint:staged": "lint-staged",
|
|
44
|
-
"prepare": "husky install
|
|
45
|
-
"rebuild": "npm run clean
|
|
44
|
+
"prepare": "husky install; npm run rebuild",
|
|
45
|
+
"rebuild": "npm run clean; npm run build",
|
|
46
46
|
"test": "mocha --exit --timeout 1m \"./test/unit/**/*-specs.js\""
|
|
47
47
|
},
|
|
48
48
|
"lint-staged": {
|
|
@@ -57,8 +57,8 @@
|
|
|
57
57
|
"singleQuote": true
|
|
58
58
|
},
|
|
59
59
|
"dependencies": {
|
|
60
|
-
"appium-adb": "^9.
|
|
61
|
-
"appium-chromedriver": "^5.
|
|
60
|
+
"appium-adb": "^9.12.0",
|
|
61
|
+
"appium-chromedriver": "^5.5.1",
|
|
62
62
|
"asyncbox": "^2.8.0",
|
|
63
63
|
"axios": "^1.x",
|
|
64
64
|
"bluebird": "^3.4.7",
|
|
@@ -73,12 +73,14 @@
|
|
|
73
73
|
"shared-preferences-builder": "^0.x",
|
|
74
74
|
"source-map-support": "^0.x",
|
|
75
75
|
"teen_process": "^2.0.0",
|
|
76
|
+
"type-fest": "^3.11.1",
|
|
76
77
|
"ws": "^8.0.0"
|
|
77
78
|
},
|
|
78
79
|
"devDependencies": {
|
|
79
|
-
"@appium/eslint-config-appium": "^
|
|
80
|
-
"@appium/
|
|
81
|
-
"@appium/
|
|
80
|
+
"@appium/eslint-config-appium": "^8.0.4",
|
|
81
|
+
"@appium/eslint-config-appium-ts": "^0.3.1",
|
|
82
|
+
"@appium/support": "^4.1.2",
|
|
83
|
+
"@appium/test-support": "^3.0.20",
|
|
82
84
|
"@appium/tsconfig": "^0.3.0",
|
|
83
85
|
"@appium/types": "^0.13.4",
|
|
84
86
|
"@commitlint/cli": "^17.6.3",
|
|
@@ -97,16 +99,20 @@
|
|
|
97
99
|
"@types/source-map-support": "^0.5.6",
|
|
98
100
|
"@types/teen_process": "^2.0.0",
|
|
99
101
|
"@types/ws": "^8.5.4",
|
|
102
|
+
"@typescript-eslint/eslint-plugin": "^5.59.5",
|
|
103
|
+
"@typescript-eslint/parser": "^5.59.5",
|
|
100
104
|
"@xmldom/xmldom": "^0.x",
|
|
101
105
|
"android-apidemos": "^4.1.0",
|
|
106
|
+
"appium": "^2.0.0-rc.5",
|
|
102
107
|
"chai": "^4.1.2",
|
|
103
108
|
"chai-as-promised": "^7.1.1",
|
|
104
|
-
"conventional-changelog-conventionalcommits": "^
|
|
105
|
-
"eslint": "^
|
|
106
|
-
"eslint-config-prettier": "^8.
|
|
107
|
-
"eslint-
|
|
108
|
-
"eslint-plugin-
|
|
109
|
-
"eslint-plugin-
|
|
109
|
+
"conventional-changelog-conventionalcommits": "^6.0.0",
|
|
110
|
+
"eslint": "^8.40.0",
|
|
111
|
+
"eslint-config-prettier": "^8.8.0",
|
|
112
|
+
"eslint-import-resolver-typescript": "^3.5.5",
|
|
113
|
+
"eslint-plugin-import": "^2.27.5",
|
|
114
|
+
"eslint-plugin-mocha": "^10.1.0",
|
|
115
|
+
"eslint-plugin-promise": "^6.1.1",
|
|
110
116
|
"husky": "^8.0.3",
|
|
111
117
|
"lint-staged": "^14.0.0",
|
|
112
118
|
"mocha": "^10.0.0",
|
|
@@ -124,5 +130,6 @@
|
|
|
124
130
|
"engines": {
|
|
125
131
|
"node": ">=14",
|
|
126
132
|
"npm": ">=8"
|
|
127
|
-
}
|
|
133
|
+
},
|
|
134
|
+
"types": "./build/lib/index.d.ts"
|
|
128
135
|
}
|
package/index.js
DELETED
|
@@ -1,24 +0,0 @@
|
|
|
1
|
-
#!/usr/bin/env node
|
|
2
|
-
import {install} from 'source-map-support';
|
|
3
|
-
install();
|
|
4
|
-
|
|
5
|
-
import * as driver from './lib/driver';
|
|
6
|
-
import * as androidHelperIndex from './lib/android-helpers';
|
|
7
|
-
import * as commandIndex from './lib/commands/index';
|
|
8
|
-
import * as webview from './lib/webview-helpers';
|
|
9
|
-
import * as caps from './lib/desired-caps';
|
|
10
|
-
|
|
11
|
-
const { AndroidDriver } = driver;
|
|
12
|
-
const { helpers: webviewHelpers, NATIVE_WIN, WEBVIEW_WIN, WEBVIEW_BASE,
|
|
13
|
-
CHROMIUM_WIN } = webview;
|
|
14
|
-
const { commonCapConstraints } = caps;
|
|
15
|
-
const { commands: androidCommands } = commandIndex;
|
|
16
|
-
const { helpers: androidHelpers, SETTINGS_HELPER_PKG_ID } = androidHelperIndex;
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
export default AndroidDriver;
|
|
20
|
-
export {
|
|
21
|
-
androidHelpers, androidCommands, AndroidDriver,
|
|
22
|
-
commonCapConstraints, webviewHelpers, NATIVE_WIN, WEBVIEW_WIN,
|
|
23
|
-
WEBVIEW_BASE, CHROMIUM_WIN, SETTINGS_HELPER_PKG_ID,
|
|
24
|
-
};
|