ava 7.0.0 → 8.0.1

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.
Files changed (61) hide show
  1. package/entrypoints/{eslint-plugin-helper.cjs → eslint-plugin-helper.js} +10 -13
  2. package/entrypoints/{internal.d.mts → internal.d.ts} +1 -1
  3. package/entrypoints/{main.d.mts → main.d.ts} +5 -5
  4. package/entrypoints/{main.mjs → main.js} +1 -1
  5. package/entrypoints/{plugin.d.cts → plugin.d.ts} +2 -2
  6. package/entrypoints/plugin.js +1 -0
  7. package/index.d.ts +2 -2
  8. package/lib/api-event-iterator.js +2 -2
  9. package/lib/api.js +6 -6
  10. package/lib/assert.js +6 -5
  11. package/lib/cli.js +7 -27
  12. package/lib/create-chain.js +68 -25
  13. package/lib/extensions.js +5 -7
  14. package/lib/fork.js +3 -3
  15. package/lib/{glob-helpers.cjs → glob-helpers.js} +16 -30
  16. package/lib/globs.js +3 -3
  17. package/lib/{ipc-flow-control.cjs → ipc-flow-control.js} +1 -4
  18. package/lib/load-config.js +2 -3
  19. package/lib/{now-and-timers.cjs → now-and-timers.js} +11 -8
  20. package/lib/pkg.js +1 -0
  21. package/lib/plugin-support/shared-worker-loader.js +2 -2
  22. package/lib/plugin-support/shared-workers.js +3 -3
  23. package/lib/provider-manager.js +6 -5
  24. package/lib/reporters/default.js +1 -1
  25. package/lib/reporters/improper-usage-messages.js +1 -1
  26. package/lib/reporters/tap.js +10 -4
  27. package/lib/runner.js +5 -5
  28. package/lib/scheduler.js +1 -1
  29. package/lib/snapshot-manager.js +43 -12
  30. package/lib/test.js +15 -8
  31. package/lib/watcher.js +10 -18
  32. package/lib/worker/base.js +17 -41
  33. package/lib/worker/{channel.cjs → channel.js} +21 -25
  34. package/lib/worker/completion-handlers.js +3 -3
  35. package/lib/worker/{guard-environment.cjs → guard-environment.js} +4 -5
  36. package/lib/worker/line-numbers.js +3 -7
  37. package/lib/worker/main.js +11 -0
  38. package/lib/worker/{options.cjs → options.js} +4 -5
  39. package/lib/worker/{plugin.cjs → plugin.js} +8 -10
  40. package/lib/worker/state.js +5 -0
  41. package/lib/worker/utils.js +5 -0
  42. package/package.json +30 -38
  43. package/plugin.d.ts +1 -1
  44. package/types/{test-fn.d.cts → test-fn.d.ts} +24 -3
  45. package/types/{try-fn.d.cts → try-fn.d.ts} +1 -2
  46. package/entrypoints/main.cjs +0 -2
  47. package/entrypoints/main.d.cts +0 -12
  48. package/entrypoints/plugin.cjs +0 -2
  49. package/entrypoints/plugin.d.mts +0 -6
  50. package/entrypoints/plugin.mjs +0 -4
  51. package/lib/module-types.js +0 -85
  52. package/lib/pkg.cjs +0 -2
  53. package/lib/slash.cjs +0 -36
  54. package/lib/worker/main.cjs +0 -12
  55. package/lib/worker/state.cjs +0 -6
  56. package/lib/worker/utils.cjs +0 -6
  57. /package/entrypoints/{cli.mjs → cli.js} +0 -0
  58. /package/types/{assertions.d.cts → assertions.d.ts} +0 -0
  59. /package/types/{shared-worker.d.cts → shared-worker.d.ts} +0 -0
  60. /package/types/{state-change-events.d.cts → state-change-events.d.ts} +0 -0
  61. /package/types/{subscribable.d.cts → subscribable.d.ts} +0 -0
package/lib/slash.cjs DELETED
@@ -1,36 +0,0 @@
1
- /*
2
- Inlined from
3
- <https://github.com/sindresorhus/slash/blob/98b618f5a3bfcb5dd374b204868818845b87bb2f/index.js>,
4
- since we need a CJS version.
5
-
6
- Copyright 2023 Sindre Sorhus
7
-
8
- Permission is hereby granted, free of charge, to any person obtaining a copy of
9
- this software and associated documentation files (the “Software”), to deal in
10
- the Software without restriction, including without limitation the rights to
11
- use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of
12
- the Software, and to permit persons to whom the Software is furnished to do so,
13
- subject to the following conditions:
14
-
15
- The above copyright notice and this permission notice shall be included in all
16
- copies or substantial portions of the Software.
17
-
18
- THE SOFTWARE IS PROVIDED “AS IS”, WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
19
- IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS
20
- FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR
21
- COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER
22
- IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
23
- CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
24
- */
25
-
26
- function slash(path) {
27
- const isExtendedLengthPath = path.startsWith('\\\\?\\');
28
-
29
- if (isExtendedLengthPath) {
30
- return path;
31
- }
32
-
33
- return path.replaceAll('\\', '/');
34
- }
35
-
36
- module.exports = slash;
@@ -1,12 +0,0 @@
1
- 'use strict';
2
- require('./guard-environment.cjs'); // eslint-disable-line import-x/no-unassigned-import
3
-
4
- const assert = require('node:assert');
5
-
6
- const {flags, refs} = require('./state.cjs');
7
-
8
- assert(refs.runnerChain);
9
-
10
- flags.loadedMain = true;
11
-
12
- module.exports = refs.runnerChain;
@@ -1,6 +0,0 @@
1
- 'use strict';
2
- exports.flags = {loadedMain: false};
3
- exports.refs = {runnerChain: null};
4
- exports.completionHandlers = [];
5
- exports.sharedWorkerTeardowns = [];
6
- exports.waitForReady = [];
@@ -1,6 +0,0 @@
1
- 'use strict';
2
- const process = require('node:process');
3
- const {isMainThread} = require('node:worker_threads');
4
-
5
- exports.isRunningInThread = isMainThread === false;
6
- exports.isRunningInChildProcess = typeof process.send === 'function';
File without changes
File without changes
File without changes