@applitools/eyes 1.1.4 → 1.2.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/dist/Eyes.js +7 -2
- package/package.json +3 -3
package/dist/Eyes.js
CHANGED
|
@@ -33,6 +33,7 @@ const TestFailedError_1 = require("./errors/TestFailedError");
|
|
|
33
33
|
const CheckSettings_1 = require("./input/CheckSettings");
|
|
34
34
|
const Configuration_1 = require("./input/Configuration");
|
|
35
35
|
const RectangleSize_1 = require("./input/RectangleSize");
|
|
36
|
+
const Region_1 = require("./input/Region");
|
|
36
37
|
const LogHandler_1 = require("./input/LogHandler");
|
|
37
38
|
const MatchResult_1 = require("./output/MatchResult");
|
|
38
39
|
const TestResults_1 = require("./output/TestResults");
|
|
@@ -49,7 +50,7 @@ class Eyes {
|
|
|
49
50
|
const client = await core.getECClient({
|
|
50
51
|
settings: {
|
|
51
52
|
proxy: config === null || config === void 0 ? void 0 : config.proxy,
|
|
52
|
-
|
|
53
|
+
options: { eyesServerUrl: config === null || config === void 0 ? void 0 : config.serverUrl, apiKey: config === null || config === void 0 ? void 0 : config.apiKey },
|
|
53
54
|
},
|
|
54
55
|
});
|
|
55
56
|
client.unref();
|
|
@@ -278,7 +279,11 @@ class Eyes {
|
|
|
278
279
|
if (!this.isOpen)
|
|
279
280
|
throw new EyesError_1.EyesError('Eyes not open');
|
|
280
281
|
const config = this._config.toJSON();
|
|
281
|
-
|
|
282
|
+
const results = await this._core.locate({ target: this._driver, settings: { ...this._state, ...settings }, config });
|
|
283
|
+
return Object.entries(results).reduce((results, [key, regions]) => {
|
|
284
|
+
results[key] = regions.map(region => new Region_1.RegionData(region));
|
|
285
|
+
return results;
|
|
286
|
+
}, {});
|
|
282
287
|
}
|
|
283
288
|
async extractTextRegions(targetOrSettings, settings) {
|
|
284
289
|
if (this._config.isDisabled)
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@applitools/eyes",
|
|
3
|
-
"version": "1.
|
|
3
|
+
"version": "1.2.0",
|
|
4
4
|
"keywords": [
|
|
5
5
|
"applitools",
|
|
6
6
|
"eyes",
|
|
@@ -53,13 +53,13 @@
|
|
|
53
53
|
"postversion": "bongo postversion"
|
|
54
54
|
},
|
|
55
55
|
"dependencies": {
|
|
56
|
-
"@applitools/core": "2.
|
|
56
|
+
"@applitools/core": "2.5.0",
|
|
57
57
|
"@applitools/logger": "1.1.48",
|
|
58
58
|
"@applitools/utils": "1.3.32"
|
|
59
59
|
},
|
|
60
60
|
"devDependencies": {
|
|
61
61
|
"@applitools/bongo": "^3.0.3",
|
|
62
|
-
"@applitools/req": "^1.1.
|
|
62
|
+
"@applitools/req": "^1.1.35",
|
|
63
63
|
"@types/node": "^12.20.55"
|
|
64
64
|
},
|
|
65
65
|
"engines": {
|