@testim/testim-cli 3.210.0 → 3.211.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.
@@ -2509,9 +2509,9 @@
2509
2509
  },
2510
2510
  "dependencies": {
2511
2511
  "@types/node": {
2512
- "version": "17.0.1",
2513
- "resolved": "https://registry.npmjs.org/@types/node/-/node-17.0.1.tgz",
2514
- "integrity": "sha512-NXKvBVUzIbs6ylBwmOwHFkZS2EXCcjnqr8ZCRNaXBkHAf+3mn/rPcJxwrzuc6movh8fxQAsUUfYklJ/EG+hZqQ=="
2512
+ "version": "17.0.2",
2513
+ "resolved": "https://registry.npmjs.org/@types/node/-/node-17.0.2.tgz",
2514
+ "integrity": "sha512-JepeIUPFDARgIs0zD/SKPgFsJEAF0X5/qO80llx59gOxFTboS9Amv3S+QfB7lqBId5sFXJ99BN0J6zFRvL9dDA=="
2515
2515
  },
2516
2516
  "mkdirp": {
2517
2517
  "version": "0.5.5",
@@ -3501,9 +3501,9 @@
3501
3501
  "integrity": "sha512-GJCAeDBKfREgkBtgrYSf9hQy9kTb3helv0zGdzqhM7iAkW8FA/ZF97VQDbwFiwIT8MQLLOe5VlPZOEvZAqtUAQ=="
3502
3502
  },
3503
3503
  "electron-to-chromium": {
3504
- "version": "1.4.24",
3505
- "resolved": "https://registry.npmjs.org/electron-to-chromium/-/electron-to-chromium-1.4.24.tgz",
3506
- "integrity": "sha512-erwx5r69B/WFfFuF2jcNN0817BfDBdC4765kQ6WltOMuwsimlQo3JTEq0Cle+wpHralwdeX3OfAtw/mHxPK0Wg==",
3504
+ "version": "1.4.25",
3505
+ "resolved": "https://registry.npmjs.org/electron-to-chromium/-/electron-to-chromium-1.4.25.tgz",
3506
+ "integrity": "sha512-bTwub9Y/76EiNmfaiJih+hAy6xn7Ns95S4KvI2NuKNOz8TEEKKQUu44xuy0PYMudjM9zdjKRS1bitsUvHTfuUg==",
3507
3507
  "dev": true
3508
3508
  },
3509
3509
  "emoji-regex": {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@testim/testim-cli",
3
- "version": "3.210.0",
3
+ "version": "3.211.0",
4
4
  "description": "Command line interface for running Testing on your CI",
5
5
  "author": "Oren Rubin",
6
6
  "contributors": [{
@@ -290,7 +290,7 @@ ImageCaptureUtils.prototype = {
290
290
  }
291
291
 
292
292
  return Promise.all([windowUtil.getFullPageSize(), windowUtil.getViewportSize()])
293
- .spread((fullPageSize, viewPortSize) => createStitchImage(fullPageSize, viewPortSize));
293
+ .then(([fullPageSize, viewPortSize]) => createStitchImage(fullPageSize, viewPortSize));
294
294
  },
295
295
  };
296
296
 
@@ -1,10 +1,10 @@
1
- "use strict";
1
+ 'use strict';
2
2
 
3
3
  const Promise = require('bluebird');
4
4
  const utils = require('../../utils');
5
5
 
6
6
  class ScreenshotUtils {
7
- constructor(tabId, driver, options = { takeScreenshots: true}){
7
+ constructor(tabId, driver, options = { takeScreenshots: true }) {
8
8
  this.tabId = tabId;
9
9
  this.driver = driver;
10
10
  this.options = options;
@@ -30,12 +30,12 @@ class ScreenshotUtils {
30
30
  const devicePixelRatioPromise = this.currentDevicePixelRatio ? Promise.resolve(this.currentDevicePixelRatio) : this.getDevicePixelRatio();
31
31
  const getScreenshot = () => Promise.all([devicePixelRatioPromise, this.driver.takeScreenshot()]);
32
32
  return utils.runWithRetries(getScreenshot, MAX_RETRY_COUNT, SCREENSHOT_RETRY_DELAY)
33
- .spread((devicePixelRatio, image) => {
33
+ .then(([devicePixelRatio, image]) => {
34
34
  const base64 = image ? image.value : '';
35
- const dataUrl = "data:image/png;base64," + this.base64AddPadding(base64.replace(/[\r\n]/g, ''));
35
+ const dataUrl = `data:image/png;base64,${this.base64AddPadding(base64.replace(/[\r\n]/g, ''))}`;
36
36
  return {
37
37
  image: dataUrl,
38
- devicePixelRatio: devicePixelRatio
38
+ devicePixelRatio,
39
39
  };
40
40
  });
41
41
  }
@@ -52,7 +52,7 @@ class ScreenshotUtils {
52
52
  return this.driver.executeJS(devicePixelRatioJS).then(result => Promise.resolve(result.value));
53
53
  }
54
54
 
55
- forcePixelRatio(forceRatio = 1){
55
+ forcePixelRatio(forceRatio = 1) {
56
56
  this.currentDevicePixelRatio = forceRatio;
57
57
  return Promise.resolve();
58
58
  }