@applitools/eyes-cypress 3.24.0-beta.3 → 3.24.0-beta.4

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/README.md CHANGED
@@ -522,11 +522,15 @@ cy.eyesClose();
522
522
  #### GetAllTestResults
523
523
 
524
524
  Returns an object with the applitools test results from a given test / test file.
525
- This should be called after `close`
525
+ This should be called after `close`. For example:
526
526
 
527
527
  ```js
528
- cy.eyesGetAllTestResults()
529
- ```
528
+ after(() => {
529
+ cy.eyesGetAllTestResults().then(results => {
530
+ console.log(results)
531
+ })
532
+ })
533
+ ```
530
534
 
531
535
  ## Concurrency
532
536
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@applitools/eyes-cypress",
3
- "version": "3.24.0-beta.3",
3
+ "version": "3.24.0-beta.4",
4
4
  "main": "index.js",
5
5
  "license": "SEE LICENSE IN LICENSE",
6
6
  "bin": {
@@ -32,14 +32,17 @@ const shouldUseBrowserHooks =
32
32
  (getGlobalConfigProperty('isInteractive') ||
33
33
  !getGlobalConfigProperty('eyesIsGlobalHooksSupported'));
34
34
 
35
- Cypress.Commands.add('eyesGetAllTestResults', async () => {
36
- if (isCurrentTestDisabled) {
37
- isCurrentTestDisabled = false;
38
- return;
39
- }
40
- await Promise.all(closePromiseArr);
41
- return socket.request('EyesManager.closeAllEyes', {manager, throwErr});
35
+ Cypress.Commands.add('eyesGetAllTestResults', () => {
36
+ return cy.then({timeout: 86400000}, async () => {
37
+ if (isCurrentTestDisabled) {
38
+ isCurrentTestDisabled = false;
39
+ return;
40
+ }
41
+ await Promise.all(closePromiseArr);
42
+ return socket.request('EyesManager.closeAllEyes', {manager, throwErr});
43
+ })
42
44
  });
45
+
43
46
 
44
47
  if (shouldUseBrowserHooks) {
45
48
  after(() => {