detox 20.0.5-breaking.new-global-lifecycle.0 → 20.0.6-breaking.new-global-lifecycle.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (44) hide show
  1. package/Detox-android/com/wix/detox/{20.0.5-breaking.new-global-lifecycle.0/detox-20.0.5-breaking.new-global-lifecycle.0-javadoc.jar → 20.0.6-breaking.new-global-lifecycle.0/detox-20.0.6-breaking.new-global-lifecycle.0-javadoc.jar} +0 -0
  2. package/Detox-android/com/wix/detox/20.0.6-breaking.new-global-lifecycle.0/detox-20.0.6-breaking.new-global-lifecycle.0-javadoc.jar.md5 +1 -0
  3. package/Detox-android/com/wix/detox/20.0.6-breaking.new-global-lifecycle.0/detox-20.0.6-breaking.new-global-lifecycle.0-javadoc.jar.sha1 +1 -0
  4. package/Detox-android/com/wix/detox/20.0.6-breaking.new-global-lifecycle.0/detox-20.0.6-breaking.new-global-lifecycle.0-javadoc.jar.sha256 +1 -0
  5. package/Detox-android/com/wix/detox/20.0.6-breaking.new-global-lifecycle.0/detox-20.0.6-breaking.new-global-lifecycle.0-javadoc.jar.sha512 +1 -0
  6. package/Detox-android/com/wix/detox/{20.0.5-breaking.new-global-lifecycle.0/detox-20.0.5-breaking.new-global-lifecycle.0-sources.jar → 20.0.6-breaking.new-global-lifecycle.0/detox-20.0.6-breaking.new-global-lifecycle.0-sources.jar} +0 -0
  7. package/Detox-android/com/wix/detox/20.0.6-breaking.new-global-lifecycle.0/detox-20.0.6-breaking.new-global-lifecycle.0-sources.jar.md5 +1 -0
  8. package/Detox-android/com/wix/detox/20.0.6-breaking.new-global-lifecycle.0/detox-20.0.6-breaking.new-global-lifecycle.0-sources.jar.sha1 +1 -0
  9. package/Detox-android/com/wix/detox/20.0.6-breaking.new-global-lifecycle.0/detox-20.0.6-breaking.new-global-lifecycle.0-sources.jar.sha256 +1 -0
  10. package/Detox-android/com/wix/detox/20.0.6-breaking.new-global-lifecycle.0/detox-20.0.6-breaking.new-global-lifecycle.0-sources.jar.sha512 +1 -0
  11. package/Detox-android/com/wix/detox/{20.0.5-breaking.new-global-lifecycle.0/detox-20.0.5-breaking.new-global-lifecycle.0.aar → 20.0.6-breaking.new-global-lifecycle.0/detox-20.0.6-breaking.new-global-lifecycle.0.aar} +0 -0
  12. package/Detox-android/com/wix/detox/{20.0.5-breaking.new-global-lifecycle.0/detox-20.0.5-breaking.new-global-lifecycle.0.aar.md5 → 20.0.6-breaking.new-global-lifecycle.0/detox-20.0.6-breaking.new-global-lifecycle.0.aar.md5} +0 -0
  13. package/Detox-android/com/wix/detox/{20.0.5-breaking.new-global-lifecycle.0/detox-20.0.5-breaking.new-global-lifecycle.0.aar.sha1 → 20.0.6-breaking.new-global-lifecycle.0/detox-20.0.6-breaking.new-global-lifecycle.0.aar.sha1} +0 -0
  14. package/Detox-android/com/wix/detox/{20.0.5-breaking.new-global-lifecycle.0/detox-20.0.5-breaking.new-global-lifecycle.0.aar.sha256 → 20.0.6-breaking.new-global-lifecycle.0/detox-20.0.6-breaking.new-global-lifecycle.0.aar.sha256} +0 -0
  15. package/Detox-android/com/wix/detox/{20.0.5-breaking.new-global-lifecycle.0/detox-20.0.5-breaking.new-global-lifecycle.0.aar.sha512 → 20.0.6-breaking.new-global-lifecycle.0/detox-20.0.6-breaking.new-global-lifecycle.0.aar.sha512} +0 -0
  16. package/Detox-android/com/wix/detox/{20.0.5-breaking.new-global-lifecycle.0/detox-20.0.5-breaking.new-global-lifecycle.0.pom → 20.0.6-breaking.new-global-lifecycle.0/detox-20.0.6-breaking.new-global-lifecycle.0.pom} +1 -1
  17. package/Detox-android/com/wix/detox/20.0.6-breaking.new-global-lifecycle.0/detox-20.0.6-breaking.new-global-lifecycle.0.pom.md5 +1 -0
  18. package/Detox-android/com/wix/detox/20.0.6-breaking.new-global-lifecycle.0/detox-20.0.6-breaking.new-global-lifecycle.0.pom.sha1 +1 -0
  19. package/Detox-android/com/wix/detox/20.0.6-breaking.new-global-lifecycle.0/detox-20.0.6-breaking.new-global-lifecycle.0.pom.sha256 +1 -0
  20. package/Detox-android/com/wix/detox/20.0.6-breaking.new-global-lifecycle.0/detox-20.0.6-breaking.new-global-lifecycle.0.pom.sha512 +1 -0
  21. package/Detox-android/com/wix/detox/maven-metadata.xml +4 -4
  22. package/Detox-android/com/wix/detox/maven-metadata.xml.md5 +1 -1
  23. package/Detox-android/com/wix/detox/maven-metadata.xml.sha1 +1 -1
  24. package/Detox-android/com/wix/detox/maven-metadata.xml.sha256 +1 -1
  25. package/Detox-android/com/wix/detox/maven-metadata.xml.sha512 +1 -1
  26. package/Detox-ios-src.tbz +0 -0
  27. package/Detox-ios.tbz +0 -0
  28. package/local-cli/testCommand/TestRunnerCommand.js +6 -4
  29. package/package.json +2 -2
  30. package/runners/jest/testEnvironment/index.js +1 -1
  31. package/src/logger/DetoxLogger.js +16 -16
  32. package/src/realms/DetoxPrimaryContext.js +19 -6
  33. package/Detox-android/com/wix/detox/20.0.5-breaking.new-global-lifecycle.0/detox-20.0.5-breaking.new-global-lifecycle.0-javadoc.jar.md5 +0 -1
  34. package/Detox-android/com/wix/detox/20.0.5-breaking.new-global-lifecycle.0/detox-20.0.5-breaking.new-global-lifecycle.0-javadoc.jar.sha1 +0 -1
  35. package/Detox-android/com/wix/detox/20.0.5-breaking.new-global-lifecycle.0/detox-20.0.5-breaking.new-global-lifecycle.0-javadoc.jar.sha256 +0 -1
  36. package/Detox-android/com/wix/detox/20.0.5-breaking.new-global-lifecycle.0/detox-20.0.5-breaking.new-global-lifecycle.0-javadoc.jar.sha512 +0 -1
  37. package/Detox-android/com/wix/detox/20.0.5-breaking.new-global-lifecycle.0/detox-20.0.5-breaking.new-global-lifecycle.0-sources.jar.md5 +0 -1
  38. package/Detox-android/com/wix/detox/20.0.5-breaking.new-global-lifecycle.0/detox-20.0.5-breaking.new-global-lifecycle.0-sources.jar.sha1 +0 -1
  39. package/Detox-android/com/wix/detox/20.0.5-breaking.new-global-lifecycle.0/detox-20.0.5-breaking.new-global-lifecycle.0-sources.jar.sha256 +0 -1
  40. package/Detox-android/com/wix/detox/20.0.5-breaking.new-global-lifecycle.0/detox-20.0.5-breaking.new-global-lifecycle.0-sources.jar.sha512 +0 -1
  41. package/Detox-android/com/wix/detox/20.0.5-breaking.new-global-lifecycle.0/detox-20.0.5-breaking.new-global-lifecycle.0.pom.md5 +0 -1
  42. package/Detox-android/com/wix/detox/20.0.5-breaking.new-global-lifecycle.0/detox-20.0.5-breaking.new-global-lifecycle.0.pom.sha1 +0 -1
  43. package/Detox-android/com/wix/detox/20.0.5-breaking.new-global-lifecycle.0/detox-20.0.5-breaking.new-global-lifecycle.0.pom.sha256 +0 -1
  44. package/Detox-android/com/wix/detox/20.0.5-breaking.new-global-lifecycle.0/detox-20.0.5-breaking.new-global-lifecycle.0.pom.sha512 +0 -1
@@ -0,0 +1 @@
1
+ c78417c3025b0c430f0270d630bd8cc3d680cbd413481ce57f63f44f682fa734
@@ -0,0 +1 @@
1
+ 2ed2683d4799f88018b813696666c11fceba5be25b261a780fba9b4f85fa52518577315762760f2c5898bb75dfd8b9f7141a4fe276f17dbf431f4db2f8972b62
@@ -0,0 +1 @@
1
+ 88cf8c98c0342ba8052e6483f32c0b21c55e8b49e3e821a8ab7f4d1241f3ac95
@@ -0,0 +1 @@
1
+ 086ec58c930ddd33b055906bc7baeab54bf0c61e824168e714542b3c12435765ea79207f73084cf9f865d5afd4d0d277454bad7df260d91904fc839068ba3345
@@ -3,7 +3,7 @@
3
3
  <modelVersion>4.0.0</modelVersion>
4
4
  <groupId>com.wix</groupId>
5
5
  <artifactId>detox</artifactId>
6
- <version>20.0.5-breaking.new-global-lifecycle.0</version>
6
+ <version>20.0.6-breaking.new-global-lifecycle.0</version>
7
7
  <packaging>aar</packaging>
8
8
  <name>Detox</name>
9
9
  <description>Gray box end-to-end testing and automation library for mobile apps</description>
@@ -0,0 +1 @@
1
+ 33f28069a49462150368c6c44ea5644083c155771aefdd51f0e41858dc43e61d
@@ -0,0 +1 @@
1
+ 6d57cb6061f616f09785d65238df8c1bb4751a95e65f1dd038b4c4b7d7b72a5d6572fc49ee4085c26a44407219a8c952e46263457fee030a17b3767654557da6
@@ -3,11 +3,11 @@
3
3
  <groupId>com.wix</groupId>
4
4
  <artifactId>detox</artifactId>
5
5
  <versioning>
6
- <latest>20.0.5-breaking.new-global-lifecycle.0</latest>
7
- <release>20.0.5-breaking.new-global-lifecycle.0</release>
6
+ <latest>20.0.6-breaking.new-global-lifecycle.0</latest>
7
+ <release>20.0.6-breaking.new-global-lifecycle.0</release>
8
8
  <versions>
9
- <version>20.0.5-breaking.new-global-lifecycle.0</version>
9
+ <version>20.0.6-breaking.new-global-lifecycle.0</version>
10
10
  </versions>
11
- <lastUpdated>20220904154935</lastUpdated>
11
+ <lastUpdated>20220905115247</lastUpdated>
12
12
  </versioning>
13
13
  </metadata>
@@ -1 +1 @@
1
- 90746dab45626ae5891c33be157b7921
1
+ 97dde91895b9c45b58fb7cc6364a9e8d
@@ -1 +1 @@
1
- 81eeaefaf3b36e2c9883bcf08e42f41532e2007a
1
+ 11290dd2dfe8f2c159e0e12f674e42613903c592
@@ -1 +1 @@
1
- 07a51f70f99dd28e9f3bee0eb85dbb265fc16087a96ebed98c654855c2cca88b
1
+ 077984469b0de32349680ac5d31fd15ad7f4bc9bbcb81cc9e6a1138a14c5ad57
@@ -1 +1 @@
1
- 01e0caff588c876ccc96cbad6c8d317178f6fdac4a9c4468134ace9997090a7862a80df9de8634c6d1db0c9e956b91af5828760fd928eda3e725c101017ac794
1
+ 15ce6f12a05807a757acb5ae887aac0ffac8cc2738327275ada27b3b4849662a832fce5203d3a5aca7223b49b438176e990204726878456f5cb9dadb0f1a38d9
package/Detox-ios-src.tbz CHANGED
Binary file
package/Detox-ios.tbz CHANGED
Binary file
@@ -105,11 +105,13 @@ class TestRunnerCommand {
105
105
  throw e;
106
106
  }
107
107
 
108
- this._argv._ = testFilesToRetry.splice(0, Infinity);
109
- // @ts-ignore
110
- detox.session.testSessionIndex++; // it is always a primary context, so we can update it
108
+ if (--runsLeft > 0) {
109
+ this._argv._ = testFilesToRetry.splice(0, Infinity);
110
+ // @ts-ignore
111
+ detox.session.testSessionIndex++; // it is always a primary context, so we can update it
112
+ }
111
113
  }
112
- } while (launchError && --runsLeft > 0);
114
+ } while (launchError && runsLeft > 0);
113
115
 
114
116
  if (launchError) {
115
117
  throw launchError;
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "detox",
3
3
  "description": "E2E tests and automation for mobile",
4
- "version": "20.0.5-breaking.new-global-lifecycle.0",
4
+ "version": "20.0.6-breaking.new-global-lifecycle.0",
5
5
  "bin": {
6
6
  "detox": "local-cli/cli.js"
7
7
  },
@@ -184,5 +184,5 @@
184
184
  }
185
185
  }
186
186
  },
187
- "gitHead": "e299576e350a493084cf00a3007e5dd1ae03c3d5"
187
+ "gitHead": "29baf7cab1ff919fd57d11f5e41664e741777f76"
188
188
  }
@@ -129,7 +129,7 @@ class DetoxCircusEnvironment extends NodeEnvironment {
129
129
  async initDetox() {
130
130
  const opts = {
131
131
  global: this.global,
132
- workerId: `worker-${process.env.JEST_WORKER_ID}`,
132
+ workerId: `w${process.env.JEST_WORKER_ID}`,
133
133
  };
134
134
 
135
135
  if (this._shouldManageDetox) {
@@ -34,6 +34,22 @@ class DetoxLogger {
34
34
  */
35
35
  this._sharedConfig = sharedConfig;
36
36
 
37
+ /** @type {object | undefined} */
38
+ this._context = context;
39
+
40
+ /** @public */
41
+ this.fatal = this._setupLogMethod('fatal');
42
+ /** @public */
43
+ this.error = this._setupLogMethod('error');
44
+ /** @public */
45
+ this.warn = this._setupLogMethod('warn');
46
+ /** @public */
47
+ this.info = this._setupLogMethod('info');
48
+ /** @public */
49
+ this.debug = this._setupLogMethod('debug');
50
+ /** @public */
51
+ this.trace = this._setupLogMethod('trace');
52
+
37
53
  if (!context) {
38
54
  // In this branch, `this` refers to the first (root) logger instance.
39
55
 
@@ -76,22 +92,6 @@ class DetoxLogger {
76
92
 
77
93
  this.overrideConsole();
78
94
  }
79
-
80
- /** @type {object | undefined} */
81
- this._context = context;
82
-
83
- /** @public */
84
- this.fatal = this._setupLogMethod('fatal');
85
- /** @public */
86
- this.error = this._setupLogMethod('error');
87
- /** @public */
88
- this.warn = this._setupLogMethod('warn');
89
- /** @public */
90
- this.info = this._setupLogMethod('info');
91
- /** @public */
92
- this.debug = this._setupLogMethod('debug');
93
- /** @public */
94
- this.trace = this._setupLogMethod('trace');
95
95
  }
96
96
 
97
97
  /**
@@ -53,7 +53,7 @@ class DetoxPrimaryContext extends DetoxContext {
53
53
  }
54
54
 
55
55
  async [symbols.resolveConfig](opts = {}) {
56
- const session = this[symbols.session];
56
+ const session = this[$sessionState];
57
57
  if (!session.detoxConfig) {
58
58
  const configuration = require('../configuration');
59
59
  session.detoxConfig = await configuration.composeDetoxConfig(opts);
@@ -229,7 +229,7 @@ class DetoxPrimaryContext extends DetoxContext {
229
229
  return;
230
230
  }
231
231
 
232
- if (this[_areLogsEnabled]) {
232
+ if (this[_areLogsEnabled]()) {
233
233
  const streamUtils = require('../utils/streamUtils');
234
234
  const { rootDir } = this[symbols.config].artifacts;
235
235
 
@@ -256,7 +256,10 @@ class DetoxPrimaryContext extends DetoxContext {
256
256
  const logsEnabled = this[_areLogsEnabled]();
257
257
 
258
258
  const { rootDir } = this[symbols.config].artifacts;
259
- fs.mkdirpSync(rootDir);
259
+
260
+ if (logsEnabled) {
261
+ fs.mkdirpSync(rootDir);
262
+ }
260
263
 
261
264
  const sessionId = this[$sessionState].id;
262
265
  const logs = globSync(temporary.for.jsonl(`${sessionId}.*`));
@@ -272,10 +275,20 @@ class DetoxPrimaryContext extends DetoxContext {
272
275
 
273
276
  [_areLogsEnabled]() {
274
277
  const { rootDir, plugins } = this[symbols.config].artifacts || {};
275
- const logConfig = plugins && plugins.log || 'none';
276
- const enabled = rootDir && (typeof logConfig === 'string' ? logConfig !== 'none' : logConfig.enabled);
278
+ if (!rootDir || !plugins) {
279
+ return false;
280
+ }
281
+
282
+ if (!plugins.log.enabled) {
283
+ return false;
284
+ }
285
+
286
+ if (!plugins.log.keepOnlyFailedTestsArtifacts) {
287
+ return true;
288
+ }
277
289
 
278
- return enabled;
290
+ const { failedTestFiles, testFilesToRetry } = this[$sessionState];
291
+ return failedTestFiles.length + testFilesToRetry.length > 0;
279
292
  }
280
293
 
281
294
  async[_resetLockFile]() {
@@ -1 +0,0 @@
1
- 274e47fbbdbe85abdf2ebfd4c76e00ef33ad353309da375460f71f9f6fe04c2a
@@ -1 +0,0 @@
1
- 063f4a5549133b4d661a7677d68a91473877b26ed3e29ef9d7502a83c179810d68f15dd9e35399b5bab23f3c97f96ee875a80abcb07d1dfa57a6177399dcc347
@@ -1 +0,0 @@
1
- 4a344c3b3b5597488fece53c9cc7358705e6d40116b0779122428094bd021db7
@@ -1 +0,0 @@
1
- 93443f0d56c9f84ec24523b954e6e9782652c4bd5d8c94bf558812fade6750beb49f4678dcbaef53e1948edcf5fb5e35c47efb49c7acc79cd2ffa0fea2b287bd
@@ -1 +0,0 @@
1
- b9ea5a9228c8248ce58fcfc5eb12983b642c2240ae61fd0929cfdafb664cc9a6
@@ -1 +0,0 @@
1
- 7d5986795398d9c6021a9d4085a4e1b2c3e794e51fb873ddfefc596d2f8b3a04a58c553fdb4202f6bd5fa4bbbf36373b318a7497a66e345b6f8f23bfee8b4145