@applitools/driver
Advanced tools
Comparing version 1.2.4 to 1.2.5
@@ -7,3 +7,3 @@ { | ||
"version": "file:../dry-run.tgz", | ||
"integrity": "sha512-bWybD9hKoQqS6LFHBKDpgE42vtg3QfQzm9PqlNtvDVhsKFFFZs0ZekT3Kiz8Dbi15T5ELubrwtRSjN4oBjg1AQ==", | ||
"integrity": "sha512-JKhrl6Y6SNt1ar1BnCiFsgPsXQwXQeYx3Dig8043bpNXUJsGaWMMsLwVuYkUz335/rrsRyKZ/lir1w8TvtXrJA==", | ||
"requires": { | ||
@@ -10,0 +10,0 @@ "@applitools/snippets": "2.1.7", |
@@ -6,2 +6,6 @@ # Change Log | ||
## 1.2.5 - 2021/10/5 | ||
- fix issue with wrong user agent overrides valid driver info | ||
## 1.2.4 - 2021/9/24 | ||
@@ -8,0 +12,0 @@ |
@@ -128,3 +128,3 @@ "use strict"; | ||
async init() { | ||
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p, _q, _r; | ||
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p, _q, _r, _s, _t, _u, _v, _w, _x; | ||
this._driverInfo = await ((_b = (_a = this._spec).getDriverInfo) === null || _b === void 0 ? void 0 : _b.call(_a, this.target)); | ||
@@ -135,3 +135,7 @@ if (this.isWeb) { | ||
const userAgentInfo = userAgent ? user_agent_1.parseUserAgent(userAgent) : {}; | ||
this._driverInfo = Object.assign(Object.assign({}, this._driverInfo), { isMobile: (_h = (_g = this._driverInfo) === null || _g === void 0 ? void 0 : _g.isMobile) !== null && _h !== void 0 ? _h : ['iOS', 'Android'].includes(userAgentInfo.platformName), platformName: (_j = userAgentInfo.platformName) !== null && _j !== void 0 ? _j : (_k = this._driverInfo) === null || _k === void 0 ? void 0 : _k.platformName, platformVersion: (_l = userAgentInfo.platformVersion) !== null && _l !== void 0 ? _l : (_m = this._driverInfo) === null || _m === void 0 ? void 0 : _m.platformVersion, browserName: (_o = userAgentInfo.browserName) !== null && _o !== void 0 ? _o : (_p = this._driverInfo) === null || _p === void 0 ? void 0 : _p.browserName, browserVersion: (_q = userAgentInfo.browserVersion) !== null && _q !== void 0 ? _q : (_r = this._driverInfo) === null || _r === void 0 ? void 0 : _r.browserVersion, userAgent, | ||
this._driverInfo = Object.assign(Object.assign({}, this._driverInfo), { isMobile: (_h = (_g = this._driverInfo) === null || _g === void 0 ? void 0 : _g.isMobile) !== null && _h !== void 0 ? _h : ['iOS', 'Android'].includes(userAgentInfo.platformName), platformName: ((_j = this._driverInfo) === null || _j === void 0 ? void 0 : _j.isMobile) | ||
? (_l = (_k = this._driverInfo) === null || _k === void 0 ? void 0 : _k.platformName) !== null && _l !== void 0 ? _l : userAgentInfo.platformName | ||
: (_m = userAgentInfo.platformName) !== null && _m !== void 0 ? _m : (_o = this._driverInfo) === null || _o === void 0 ? void 0 : _o.platformName, platformVersion: ((_p = this._driverInfo) === null || _p === void 0 ? void 0 : _p.isMobile) | ||
? (_r = (_q = this._driverInfo) === null || _q === void 0 ? void 0 : _q.platformVersion) !== null && _r !== void 0 ? _r : userAgentInfo.platformVersion | ||
: (_s = userAgentInfo.platformVersion) !== null && _s !== void 0 ? _s : (_t = this._driverInfo) === null || _t === void 0 ? void 0 : _t.platformVersion, browserName: (_u = userAgentInfo.browserName) !== null && _u !== void 0 ? _u : (_v = this._driverInfo) === null || _v === void 0 ? void 0 : _v.browserName, browserVersion: (_w = userAgentInfo.browserVersion) !== null && _w !== void 0 ? _w : (_x = this._driverInfo) === null || _x === void 0 ? void 0 : _x.browserVersion, userAgent, | ||
pixelRatio }); | ||
@@ -138,0 +142,0 @@ } |
{ | ||
"name": "@applitools/driver", | ||
"version": "1.2.4", | ||
"version": "1.2.5", | ||
"description": "Applitools universal framework wrapper", | ||
@@ -5,0 +5,0 @@ "keywords": [ |
@@ -125,4 +125,8 @@ import type * as types from '@applitools/types' | ||
isMobile: this._driverInfo?.isMobile ?? ['iOS', 'Android'].includes(userAgentInfo.platformName), | ||
platformName: userAgentInfo.platformName ?? this._driverInfo?.platformName, | ||
platformVersion: userAgentInfo.platformVersion ?? this._driverInfo?.platformVersion, | ||
platformName: this._driverInfo?.isMobile | ||
? this._driverInfo?.platformName ?? userAgentInfo.platformName | ||
: userAgentInfo.platformName ?? this._driverInfo?.platformName, | ||
platformVersion: this._driverInfo?.isMobile | ||
? this._driverInfo?.platformVersion ?? userAgentInfo.platformVersion | ||
: userAgentInfo.platformVersion ?? this._driverInfo?.platformVersion, | ||
browserName: userAgentInfo.browserName ?? this._driverInfo?.browserName, | ||
@@ -129,0 +133,0 @@ browserVersion: userAgentInfo.browserVersion ?? this._driverInfo?.browserVersion, |
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
Native code
Supply chain riskContains native code (e.g., compiled binaries or shared libraries). Including native code can obscure malicious behavior.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
251927
4529
1