@testim/testim-cli 3.269.0 → 3.270.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/cliAgentMode.js CHANGED
@@ -90,15 +90,6 @@ async function runAgentMode(options) {
90
90
  );
91
91
  }
92
92
 
93
- async function hackForCoralogixAndXhr() {
94
- Promise.resolve().then(() => {
95
- // @ts-ignore
96
- global.xhr2 = require('./commons/xhr2'); // this is inside a `then` to not block and let network requests start
97
- });
98
-
99
- // this gets picked up later in sessionPlayerInit
100
- }
101
-
102
93
  let startedWithStart = false;
103
94
 
104
95
  function getStartedWithStart() {
@@ -179,7 +170,6 @@ async function startTestimStandaloneBrowser(options) {
179
170
 
180
171
  let shouldDownloadExtension = !(options.ext || options.extensionPath);
181
172
 
182
- await hackForCoralogixAndXhr();
183
173
  if (shouldDownloadExtension && await fs.pathExists(downloadedExtensionPath)) {
184
174
  const stat = await fs.stat(downloadedExtensionPath);
185
175
  shouldDownloadExtension = (Date.now() - EXTENSION_CACHE_TIME > stat.mtimeMs);
@@ -17,11 +17,6 @@ const PREPARE_MOCK_NETWORK_ERROR_PREFIX = 'JSON file supplied to --mock-network-
17
17
 
18
18
  const logger = require('./logger').getLogger('prepare runner');
19
19
 
20
- Promise.resolve().then(() => {
21
- // @ts-ignore
22
- global.xhr2 = require('./xhr2'); // this is inside a `then` to not block and let network requests start
23
- });
24
-
25
20
  /** @param {import('../runOptions').RunnerOptions} options */
26
21
  async function prepare(options) {
27
22
  /**
@@ -582,6 +582,7 @@ function buildAppiumOptions({ projectType, gridInfo, testRunConfig, nativeApp, o
582
582
  let appCaps = {
583
583
  'headspin:capture': true,
584
584
  'appium:autoAcceptAlerts': true,
585
+ 'appium:noReset': true,
585
586
  };
586
587
  switch (projectType) {
587
588
  case 'ios':
@@ -214,7 +214,7 @@ async function getTestPlanTestList(projectId, names, planIds, branch, intersecti
214
214
  * testConfigIds?: string[];
215
215
  * intersections: import('../runOptions').RunnerOptions['intersections'];
216
216
  * }} param0
217
- * @returns {import('services/src/suite/service').RunListResult}
217
+ * @returns {Promise<import('services/src/suite/service').RunListResult>}
218
218
  */
219
219
  function getSuiteTestList({
220
220
  projectId, labels, testIds, testNames, testConfigNames, suiteNames, suiteIds, branch, rerunFailedByRunId, testConfigIds, intersections,
@@ -234,7 +234,7 @@ function getSuiteTestList({
234
234
  testConfigIds,
235
235
  intersections,
236
236
  },
237
- }), { retries: DEFAULT_REQUEST_RETRY });
237
+ }), { retries: DEFAULT_REQUEST_RETRY, factor: 1 });
238
238
  }
239
239
 
240
240
  async function getAppDetails({ appId, projectId }) {
@@ -1,12 +1,12 @@
1
1
  {
2
2
  "name": "@testim/testim-cli",
3
- "version": "3.269.0",
3
+ "version": "3.270.0",
4
4
  "lockfileVersion": 2,
5
5
  "requires": true,
6
6
  "packages": {
7
7
  "": {
8
8
  "name": "@testim/testim-cli",
9
- "version": "3.269.0",
9
+ "version": "3.270.0",
10
10
  "license": "Proprietary",
11
11
  "dependencies": {
12
12
  "@applitools/eyes-sdk-core": "13.11.21",
@@ -1460,9 +1460,9 @@
1460
1460
  }
1461
1461
  },
1462
1462
  "node_modules/@wdio/types/node_modules/@types/node": {
1463
- "version": "18.11.15",
1464
- "resolved": "https://registry.npmjs.org/@types/node/-/node-18.11.15.tgz",
1465
- "integrity": "sha512-VkhBbVo2+2oozlkdHXLrb3zjsRkpdnaU2bXmX8Wgle3PUi569eLRaHGlgETQHR7lLL1w7GiG3h9SnePhxNDecw=="
1463
+ "version": "18.11.17",
1464
+ "resolved": "https://registry.npmjs.org/@types/node/-/node-18.11.17.tgz",
1465
+ "integrity": "sha512-HJSUJmni4BeDHhfzn6nF0sVmd1SMezP7/4F0Lq+aXzmp2xm9O7WXrUtHW/CHlYVtZUbByEvWidHqRtcJXGF2Ng=="
1466
1466
  },
1467
1467
  "node_modules/@wdio/utils": {
1468
1468
  "version": "7.24.0",
@@ -4416,9 +4416,9 @@
4416
4416
  "integrity": "sha512-+iipnm2hvmlWs4MVNx7HwSTxhDxsXnQyK5F1OalZVXeUhdPgP/23T42NCyg0TK3wL/Yg92SVrSuGKqdg12o54w=="
4417
4417
  },
4418
4418
  "node_modules/devtools/node_modules/@types/node": {
4419
- "version": "18.11.15",
4420
- "resolved": "https://registry.npmjs.org/@types/node/-/node-18.11.15.tgz",
4421
- "integrity": "sha512-VkhBbVo2+2oozlkdHXLrb3zjsRkpdnaU2bXmX8Wgle3PUi569eLRaHGlgETQHR7lLL1w7GiG3h9SnePhxNDecw=="
4419
+ "version": "18.11.17",
4420
+ "resolved": "https://registry.npmjs.org/@types/node/-/node-18.11.17.tgz",
4421
+ "integrity": "sha512-HJSUJmni4BeDHhfzn6nF0sVmd1SMezP7/4F0Lq+aXzmp2xm9O7WXrUtHW/CHlYVtZUbByEvWidHqRtcJXGF2Ng=="
4422
4422
  },
4423
4423
  "node_modules/devtools/node_modules/ua-parser-js": {
4424
4424
  "version": "1.0.32",
@@ -15468,9 +15468,9 @@
15468
15468
  }
15469
15469
  },
15470
15470
  "node_modules/webdriver/node_modules/@types/node": {
15471
- "version": "18.11.15",
15472
- "resolved": "https://registry.npmjs.org/@types/node/-/node-18.11.15.tgz",
15473
- "integrity": "sha512-VkhBbVo2+2oozlkdHXLrb3zjsRkpdnaU2bXmX8Wgle3PUi569eLRaHGlgETQHR7lLL1w7GiG3h9SnePhxNDecw=="
15471
+ "version": "18.11.17",
15472
+ "resolved": "https://registry.npmjs.org/@types/node/-/node-18.11.17.tgz",
15473
+ "integrity": "sha512-HJSUJmni4BeDHhfzn6nF0sVmd1SMezP7/4F0Lq+aXzmp2xm9O7WXrUtHW/CHlYVtZUbByEvWidHqRtcJXGF2Ng=="
15474
15474
  },
15475
15475
  "node_modules/webdriverio": {
15476
15476
  "version": "7.24.0",
@@ -15510,9 +15510,9 @@
15510
15510
  }
15511
15511
  },
15512
15512
  "node_modules/webdriverio/node_modules/@types/node": {
15513
- "version": "18.11.15",
15514
- "resolved": "https://registry.npmjs.org/@types/node/-/node-18.11.15.tgz",
15515
- "integrity": "sha512-VkhBbVo2+2oozlkdHXLrb3zjsRkpdnaU2bXmX8Wgle3PUi569eLRaHGlgETQHR7lLL1w7GiG3h9SnePhxNDecw=="
15513
+ "version": "18.11.17",
15514
+ "resolved": "https://registry.npmjs.org/@types/node/-/node-18.11.17.tgz",
15515
+ "integrity": "sha512-HJSUJmni4BeDHhfzn6nF0sVmd1SMezP7/4F0Lq+aXzmp2xm9O7WXrUtHW/CHlYVtZUbByEvWidHqRtcJXGF2Ng=="
15516
15516
  },
15517
15517
  "node_modules/webdriverio/node_modules/brace-expansion": {
15518
15518
  "version": "2.0.1",
@@ -17129,9 +17129,9 @@
17129
17129
  },
17130
17130
  "dependencies": {
17131
17131
  "@types/node": {
17132
- "version": "18.11.15",
17133
- "resolved": "https://registry.npmjs.org/@types/node/-/node-18.11.15.tgz",
17134
- "integrity": "sha512-VkhBbVo2+2oozlkdHXLrb3zjsRkpdnaU2bXmX8Wgle3PUi569eLRaHGlgETQHR7lLL1w7GiG3h9SnePhxNDecw=="
17132
+ "version": "18.11.17",
17133
+ "resolved": "https://registry.npmjs.org/@types/node/-/node-18.11.17.tgz",
17134
+ "integrity": "sha512-HJSUJmni4BeDHhfzn6nF0sVmd1SMezP7/4F0Lq+aXzmp2xm9O7WXrUtHW/CHlYVtZUbByEvWidHqRtcJXGF2Ng=="
17135
17135
  }
17136
17136
  }
17137
17137
  },
@@ -19496,9 +19496,9 @@
19496
19496
  },
19497
19497
  "dependencies": {
19498
19498
  "@types/node": {
19499
- "version": "18.11.15",
19500
- "resolved": "https://registry.npmjs.org/@types/node/-/node-18.11.15.tgz",
19501
- "integrity": "sha512-VkhBbVo2+2oozlkdHXLrb3zjsRkpdnaU2bXmX8Wgle3PUi569eLRaHGlgETQHR7lLL1w7GiG3h9SnePhxNDecw=="
19499
+ "version": "18.11.17",
19500
+ "resolved": "https://registry.npmjs.org/@types/node/-/node-18.11.17.tgz",
19501
+ "integrity": "sha512-HJSUJmni4BeDHhfzn6nF0sVmd1SMezP7/4F0Lq+aXzmp2xm9O7WXrUtHW/CHlYVtZUbByEvWidHqRtcJXGF2Ng=="
19502
19502
  },
19503
19503
  "ua-parser-js": {
19504
19504
  "version": "1.0.32",
@@ -27994,9 +27994,9 @@
27994
27994
  },
27995
27995
  "dependencies": {
27996
27996
  "@types/node": {
27997
- "version": "18.11.15",
27998
- "resolved": "https://registry.npmjs.org/@types/node/-/node-18.11.15.tgz",
27999
- "integrity": "sha512-VkhBbVo2+2oozlkdHXLrb3zjsRkpdnaU2bXmX8Wgle3PUi569eLRaHGlgETQHR7lLL1w7GiG3h9SnePhxNDecw=="
27997
+ "version": "18.11.17",
27998
+ "resolved": "https://registry.npmjs.org/@types/node/-/node-18.11.17.tgz",
27999
+ "integrity": "sha512-HJSUJmni4BeDHhfzn6nF0sVmd1SMezP7/4F0Lq+aXzmp2xm9O7WXrUtHW/CHlYVtZUbByEvWidHqRtcJXGF2Ng=="
28000
28000
  }
28001
28001
  }
28002
28002
  },
@@ -28035,9 +28035,9 @@
28035
28035
  },
28036
28036
  "dependencies": {
28037
28037
  "@types/node": {
28038
- "version": "18.11.15",
28039
- "resolved": "https://registry.npmjs.org/@types/node/-/node-18.11.15.tgz",
28040
- "integrity": "sha512-VkhBbVo2+2oozlkdHXLrb3zjsRkpdnaU2bXmX8Wgle3PUi569eLRaHGlgETQHR7lLL1w7GiG3h9SnePhxNDecw=="
28038
+ "version": "18.11.17",
28039
+ "resolved": "https://registry.npmjs.org/@types/node/-/node-18.11.17.tgz",
28040
+ "integrity": "sha512-HJSUJmni4BeDHhfzn6nF0sVmd1SMezP7/4F0Lq+aXzmp2xm9O7WXrUtHW/CHlYVtZUbByEvWidHqRtcJXGF2Ng=="
28041
28041
  },
28042
28042
  "brace-expansion": {
28043
28043
  "version": "2.0.1",
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@testim/testim-cli",
3
- "version": "3.269.0",
3
+ "version": "3.270.0",
4
4
  "description": "Command line interface for running Testing on your CI",
5
5
  "author": "Oren Rubin",
6
6
  "contributors": [{
@@ -1 +1,5 @@
1
1
  require('./Array.prototype.at');
2
+ const xhr2 = require('../commons/xhr2');
3
+
4
+ global.xhr2 = xhr2;
5
+ global.XMLHttpRequest = xhr2;
@@ -358,7 +358,7 @@ class TestPlanRunner {
358
358
  const suiteResult = await getSuite(options, branchToUse);
359
359
  perf.log('after getSuite');
360
360
 
361
- if (!suiteResult.tests[0]?.length) {
361
+ if (!suiteResult?.tests[0]?.length) {
362
362
  if (options.rerunFailedByRunId) {
363
363
  throw new ArgError('No failed tests found in the provided run');
364
364
  }
@@ -10,7 +10,6 @@ const { ArgError } = require('../errors');
10
10
  /**
11
11
  * @param {import('../runOptions').RunnerOptions} options
12
12
  * @param {string} branchToUse
13
- * @returns
14
13
  */
15
14
  async function getSuite(options, branchToUse) {
16
15
  if (options.lightweightMode?.onlyTestIdsNoSuite && options.testId) {