@appium/base-driver 9.6.0 → 9.8.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/lib/basedriver/helpers.d.ts.map +1 -1
- package/build/lib/basedriver/helpers.js +207 -119
- package/build/lib/basedriver/helpers.js.map +1 -1
- package/build/lib/express/middleware.d.ts +46 -7
- package/build/lib/express/middleware.d.ts.map +1 -1
- package/build/lib/express/middleware.js +65 -2
- package/build/lib/express/middleware.js.map +1 -1
- package/build/lib/express/server.d.ts +2 -1
- package/build/lib/express/server.d.ts.map +1 -1
- package/build/lib/express/server.js +5 -2
- package/build/lib/express/server.js.map +1 -1
- package/build/lib/express/websocket.d.ts +0 -3
- package/build/lib/express/websocket.d.ts.map +1 -1
- package/build/lib/express/websocket.js +0 -27
- package/build/lib/express/websocket.js.map +1 -1
- package/build/lib/jsonwp-proxy/protocol-converter.d.ts.map +1 -1
- package/build/lib/jsonwp-proxy/protocol-converter.js +6 -6
- package/build/lib/jsonwp-proxy/protocol-converter.js.map +1 -1
- package/lib/basedriver/helpers.js +215 -125
- package/lib/express/middleware.js +70 -16
- package/lib/express/server.js +6 -1
- package/lib/express/websocket.js +0 -27
- package/lib/jsonwp-proxy/protocol-converter.js +10 -6
- package/package.json +8 -8
|
@@ -134,10 +134,12 @@ class ProtocolConverter {
|
|
|
134
134
|
const bodyObj = util.safeJsonParse(body);
|
|
135
135
|
if (_.isPlainObject(bodyObj)) {
|
|
136
136
|
if (this.downstreamProtocol === W3C && _.has(bodyObj, 'name') && !_.has(bodyObj, 'handle')) {
|
|
137
|
-
this.log.debug(
|
|
137
|
+
this.log.debug(
|
|
138
|
+
`Copied 'name' value '${/** @type {import('@appium/types').StringRecord} */ (bodyObj).name}' to 'handle' as per W3C spec`
|
|
139
|
+
);
|
|
138
140
|
return await this.proxyFunc(url, method, {
|
|
139
|
-
|
|
140
|
-
handle: bodyObj.name,
|
|
141
|
+
.../** @type {import('@appium/types').StringRecord} */ (bodyObj),
|
|
142
|
+
handle: /** @type {import('@appium/types').StringRecord} */ (bodyObj).name,
|
|
141
143
|
});
|
|
142
144
|
}
|
|
143
145
|
if (
|
|
@@ -145,10 +147,12 @@ class ProtocolConverter {
|
|
|
145
147
|
_.has(bodyObj, 'handle') &&
|
|
146
148
|
!_.has(bodyObj, 'name')
|
|
147
149
|
) {
|
|
148
|
-
this.log.debug(
|
|
150
|
+
this.log.debug(
|
|
151
|
+
`Copied 'handle' value '${/** @type {import('@appium/types').StringRecord} */ (bodyObj).handle}' to 'name' as per JSONWP spec`
|
|
152
|
+
);
|
|
149
153
|
return await this.proxyFunc(url, method, {
|
|
150
|
-
|
|
151
|
-
name: bodyObj.handle,
|
|
154
|
+
.../** @type {import('@appium/types').StringRecord} */ (bodyObj),
|
|
155
|
+
name: /** @type {import('@appium/types').StringRecord} */ (bodyObj).handle,
|
|
152
156
|
});
|
|
153
157
|
}
|
|
154
158
|
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@appium/base-driver",
|
|
3
|
-
"version": "9.
|
|
3
|
+
"version": "9.8.0",
|
|
4
4
|
"description": "Base driver class for Appium drivers",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"automation",
|
|
@@ -44,30 +44,30 @@
|
|
|
44
44
|
"test:types": "tsd"
|
|
45
45
|
},
|
|
46
46
|
"dependencies": {
|
|
47
|
-
"@appium/support": "^4.
|
|
48
|
-
"@appium/types": "^0.
|
|
47
|
+
"@appium/support": "^4.3.0",
|
|
48
|
+
"@appium/types": "^0.19.0",
|
|
49
49
|
"@colors/colors": "1.6.0",
|
|
50
50
|
"@types/async-lock": "1.4.2",
|
|
51
51
|
"@types/bluebird": "3.5.42",
|
|
52
52
|
"@types/express": "4.17.21",
|
|
53
|
-
"@types/lodash": "4.17.
|
|
53
|
+
"@types/lodash": "4.17.4",
|
|
54
54
|
"@types/method-override": "0.0.35",
|
|
55
55
|
"@types/serve-favicon": "2.5.7",
|
|
56
56
|
"async-lock": "1.4.1",
|
|
57
57
|
"asyncbox": "3.0.0",
|
|
58
|
-
"axios": "1.
|
|
58
|
+
"axios": "1.7.2",
|
|
59
59
|
"bluebird": "3.7.2",
|
|
60
60
|
"body-parser": "1.20.2",
|
|
61
61
|
"express": "4.19.2",
|
|
62
62
|
"http-status-codes": "2.3.0",
|
|
63
63
|
"lodash": "4.17.21",
|
|
64
|
-
"lru-cache": "10.2.
|
|
64
|
+
"lru-cache": "10.2.2",
|
|
65
65
|
"method-override": "3.0.0",
|
|
66
66
|
"morgan": "1.10.0",
|
|
67
67
|
"path-to-regexp": "6.2.2",
|
|
68
68
|
"serve-favicon": "2.5.0",
|
|
69
69
|
"source-map-support": "0.5.21",
|
|
70
|
-
"type-fest": "4.
|
|
70
|
+
"type-fest": "4.19.0",
|
|
71
71
|
"validate.js": "0.13.1"
|
|
72
72
|
},
|
|
73
73
|
"optionalDependencies": {
|
|
@@ -80,7 +80,7 @@
|
|
|
80
80
|
"publishConfig": {
|
|
81
81
|
"access": "public"
|
|
82
82
|
},
|
|
83
|
-
"gitHead": "
|
|
83
|
+
"gitHead": "339acd345fafa1292c8d286261553fcc6b440e46",
|
|
84
84
|
"tsd": {
|
|
85
85
|
"directory": "test/types"
|
|
86
86
|
}
|