@applitools/ec-client 1.7.9 → 1.7.10
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/CHANGELOG.md +76 -0
- package/dist/commands/find-element.js +5 -3
- package/package.json +9 -9
- package/types/utils/queue.d.ts +15 -0
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,81 @@
|
|
|
1
1
|
# Changelog
|
|
2
2
|
|
|
3
|
+
## [1.7.10](https://github.com/applitools/eyes.sdk.javascript1/compare/js/ec-client@1.7.9...js/ec-client@1.7.10) (2023-09-25)
|
|
4
|
+
|
|
5
|
+
|
|
6
|
+
### Code Refactoring
|
|
7
|
+
|
|
8
|
+
* use Uint8Array instead of Buffer for binary data representation ([#1928](https://github.com/applitools/eyes.sdk.javascript1/issues/1928)) ([d1472ab](https://github.com/applitools/eyes.sdk.javascript1/commit/d1472ab8fd49e9a240e99a44dbf1d180b6c7a54b))
|
|
9
|
+
|
|
10
|
+
|
|
11
|
+
### Dependencies
|
|
12
|
+
|
|
13
|
+
* @applitools/utils bumped to 1.6.1
|
|
14
|
+
#### Bug Fixes
|
|
15
|
+
|
|
16
|
+
* add browser entry point declaration and test ([#1933](https://github.com/applitools/eyes.sdk.javascript1/issues/1933)) ([5ba0720](https://github.com/applitools/eyes.sdk.javascript1/commit/5ba0720d62a9af8a9a2e1c2437c569e6ab19afd8))
|
|
17
|
+
|
|
18
|
+
|
|
19
|
+
#### Code Refactoring
|
|
20
|
+
|
|
21
|
+
* use Uint8Array instead of Buffer for binary data representation ([#1928](https://github.com/applitools/eyes.sdk.javascript1/issues/1928)) ([d1472ab](https://github.com/applitools/eyes.sdk.javascript1/commit/d1472ab8fd49e9a240e99a44dbf1d180b6c7a54b))
|
|
22
|
+
* @applitools/logger bumped to 2.0.11
|
|
23
|
+
#### Bug Fixes
|
|
24
|
+
|
|
25
|
+
* add browser entry point declaration and test ([#1933](https://github.com/applitools/eyes.sdk.javascript1/issues/1933)) ([5ba0720](https://github.com/applitools/eyes.sdk.javascript1/commit/5ba0720d62a9af8a9a2e1c2437c569e6ab19afd8))
|
|
26
|
+
|
|
27
|
+
|
|
28
|
+
|
|
29
|
+
* @applitools/socket bumped to 1.1.11
|
|
30
|
+
#### Code Refactoring
|
|
31
|
+
|
|
32
|
+
* use Uint8Array instead of Buffer for binary data representation ([#1928](https://github.com/applitools/eyes.sdk.javascript1/issues/1928)) ([d1472ab](https://github.com/applitools/eyes.sdk.javascript1/commit/d1472ab8fd49e9a240e99a44dbf1d180b6c7a54b))
|
|
33
|
+
|
|
34
|
+
|
|
35
|
+
|
|
36
|
+
* @applitools/req bumped to 1.6.1
|
|
37
|
+
#### Bug Fixes
|
|
38
|
+
|
|
39
|
+
* add browser entry point declaration and test ([#1933](https://github.com/applitools/eyes.sdk.javascript1/issues/1933)) ([5ba0720](https://github.com/applitools/eyes.sdk.javascript1/commit/5ba0720d62a9af8a9a2e1c2437c569e6ab19afd8))
|
|
40
|
+
|
|
41
|
+
|
|
42
|
+
|
|
43
|
+
* @applitools/image bumped to 1.1.6
|
|
44
|
+
#### Code Refactoring
|
|
45
|
+
|
|
46
|
+
* use Uint8Array instead of Buffer for binary data representation ([#1928](https://github.com/applitools/eyes.sdk.javascript1/issues/1928)) ([d1472ab](https://github.com/applitools/eyes.sdk.javascript1/commit/d1472ab8fd49e9a240e99a44dbf1d180b6c7a54b))
|
|
47
|
+
|
|
48
|
+
|
|
49
|
+
|
|
50
|
+
* @applitools/spec-driver-webdriver bumped to 1.0.46
|
|
51
|
+
|
|
52
|
+
* @applitools/driver bumped to 1.14.2
|
|
53
|
+
#### Code Refactoring
|
|
54
|
+
|
|
55
|
+
* use Uint8Array instead of Buffer for binary data representation ([#1928](https://github.com/applitools/eyes.sdk.javascript1/issues/1928)) ([d1472ab](https://github.com/applitools/eyes.sdk.javascript1/commit/d1472ab8fd49e9a240e99a44dbf1d180b6c7a54b))
|
|
56
|
+
|
|
57
|
+
|
|
58
|
+
|
|
59
|
+
* @applitools/tunnel-client bumped to 1.2.3
|
|
60
|
+
#### Code Refactoring
|
|
61
|
+
|
|
62
|
+
* use Uint8Array instead of Buffer for binary data representation ([#1928](https://github.com/applitools/eyes.sdk.javascript1/issues/1928)) ([d1472ab](https://github.com/applitools/eyes.sdk.javascript1/commit/d1472ab8fd49e9a240e99a44dbf1d180b6c7a54b))
|
|
63
|
+
|
|
64
|
+
|
|
65
|
+
|
|
66
|
+
* @applitools/core-base bumped to 1.6.1
|
|
67
|
+
#### Reverts
|
|
68
|
+
|
|
69
|
+
* perform major changes ([994cd70](https://github.com/applitools/eyes.sdk.javascript1/commit/994cd703ebe891bf68aecd49d77b5fb119f6ebe8))
|
|
70
|
+
|
|
71
|
+
|
|
72
|
+
#### Code Refactoring
|
|
73
|
+
|
|
74
|
+
* use Uint8Array instead of Buffer for binary data representation ([#1928](https://github.com/applitools/eyes.sdk.javascript1/issues/1928)) ([d1472ab](https://github.com/applitools/eyes.sdk.javascript1/commit/d1472ab8fd49e9a240e99a44dbf1d180b6c7a54b))
|
|
75
|
+
|
|
76
|
+
|
|
77
|
+
|
|
78
|
+
|
|
3
79
|
## [1.7.9](https://github.com/applitools/eyes.sdk.javascript1/compare/js/ec-client@1.7.8...js/ec-client@1.7.9) (2023-09-21)
|
|
4
80
|
|
|
5
81
|
|
|
@@ -10,8 +10,8 @@ function makeFindElement({ req }) {
|
|
|
10
10
|
io: { request, response, handle: false },
|
|
11
11
|
logger,
|
|
12
12
|
});
|
|
13
|
-
const responseBody =
|
|
14
|
-
const parsed = JSON.parse(
|
|
13
|
+
const responseBody = new Uint8Array(await proxyResponse.arrayBuffer());
|
|
14
|
+
const parsed = JSON.parse(new TextDecoder().decode(responseBody));
|
|
15
15
|
if ((_b = (_a = parsed === null || parsed === void 0 ? void 0 : parsed.appliCustomData) === null || _a === void 0 ? void 0 : _a.selfHealing) === null || _b === void 0 ? void 0 : _b.successfulSelector) {
|
|
16
16
|
logger.log('Self-healed locators detected', parsed.appliCustomData.selfHealing);
|
|
17
17
|
(_c = session.metadata) !== null && _c !== void 0 ? _c : (session.metadata = []);
|
|
@@ -20,7 +20,9 @@ function makeFindElement({ req }) {
|
|
|
20
20
|
else {
|
|
21
21
|
logger.log('No self-healing metadata found');
|
|
22
22
|
}
|
|
23
|
-
response
|
|
23
|
+
response
|
|
24
|
+
.writeHead(proxyResponse.status, Object.fromEntries(proxyResponse.headers.entries()))
|
|
25
|
+
.end(Buffer.from(responseBody));
|
|
24
26
|
};
|
|
25
27
|
}
|
|
26
28
|
exports.makeFindElement = makeFindElement;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@applitools/ec-client",
|
|
3
|
-
"version": "1.7.
|
|
3
|
+
"version": "1.7.10",
|
|
4
4
|
"homepage": "https://applitools.com",
|
|
5
5
|
"bugs": {
|
|
6
6
|
"url": "https://github.com/applitools/eyes.sdk.javascript1/issues"
|
|
@@ -52,14 +52,14 @@
|
|
|
52
52
|
"test:it": "MOCHA_GROUP=it run --top-level mocha './test/it/*.spec.ts'"
|
|
53
53
|
},
|
|
54
54
|
"dependencies": {
|
|
55
|
-
"@applitools/core-base": "1.6.
|
|
56
|
-
"@applitools/driver": "1.14.
|
|
57
|
-
"@applitools/logger": "2.0.
|
|
58
|
-
"@applitools/req": "1.6.
|
|
59
|
-
"@applitools/socket": "1.1.
|
|
60
|
-
"@applitools/spec-driver-webdriver": "1.0.
|
|
61
|
-
"@applitools/tunnel-client": "1.2.
|
|
62
|
-
"@applitools/utils": "1.6.
|
|
55
|
+
"@applitools/core-base": "1.6.1",
|
|
56
|
+
"@applitools/driver": "1.14.2",
|
|
57
|
+
"@applitools/logger": "2.0.11",
|
|
58
|
+
"@applitools/req": "1.6.1",
|
|
59
|
+
"@applitools/socket": "1.1.11",
|
|
60
|
+
"@applitools/spec-driver-webdriver": "1.0.46",
|
|
61
|
+
"@applitools/tunnel-client": "1.2.3",
|
|
62
|
+
"@applitools/utils": "1.6.1",
|
|
63
63
|
"abort-controller": "3.0.0",
|
|
64
64
|
"webdriver": "7.31.1",
|
|
65
65
|
"yargs": "^17.7.2"
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
import { type Logger } from '@applitools/logger';
|
|
2
|
+
import { type AbortSignal } from 'abort-controller';
|
|
3
|
+
export type Queue = {
|
|
4
|
+
readonly corked: boolean;
|
|
5
|
+
readonly pause: never;
|
|
6
|
+
run<TResult>(task: Task<TResult>): Promise<TResult>;
|
|
7
|
+
cancel(task: (signal: AbortSignal) => Promise<any>): void;
|
|
8
|
+
cork(): void;
|
|
9
|
+
uncork(): void;
|
|
10
|
+
};
|
|
11
|
+
type Task<TResult> = (signal: AbortSignal) => Promise<TResult>;
|
|
12
|
+
export declare function makeQueue({ logger }: {
|
|
13
|
+
logger: Logger;
|
|
14
|
+
}): Queue;
|
|
15
|
+
export {};
|