@rstest/core 0.7.1 → 0.7.2
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/LICENSE.md +1 -1
- package/dist/0~122.js +9 -3
- package/dist/0~151.js +303 -264
- package/dist/0~583.js +1 -1
- package/dist/0~588.js +1 -1
- package/dist/0~62.js +1 -1
- package/dist/0~634.js +3 -3
- package/dist/0~809.js +1 -1
- package/dist/0~835.js +1 -1
- package/dist/0~919.js +65 -33
- package/dist/0~923.js +1 -1
- package/dist/{155.js → 131.js} +12 -12
- package/dist/404.js +210 -0
- package/dist/{362.js → 554.js} +68 -49
- package/dist/734.js +1 -1
- package/dist/946.js +40 -30
- package/dist/index.d.ts +49 -17
- package/dist/index.js +1 -1
- package/dist/worker.d.ts +52 -23
- package/dist/worker.js +1 -1
- package/package.json +7 -6
- package/dist/770.js +0 -167
- /package/dist/{0~454.js → 0~907.js} +0 -0
- /package/dist/{362.js.LICENSE.txt → 554.js.LICENSE.txt} +0 -0
package/LICENSE.md
CHANGED
|
@@ -943,7 +943,7 @@ Licensed under MIT license in the repository at https://github.com/chaijs/loupe.
|
|
|
943
943
|
|
|
944
944
|
### magic-string
|
|
945
945
|
|
|
946
|
-
Licensed under MIT license in the repository at https://github.com/
|
|
946
|
+
Licensed under MIT license in the repository at git+https://github.com/Rich-Harris/magic-string.git.
|
|
947
947
|
|
|
948
948
|
> Copyright 2018 Rich Harris
|
|
949
949
|
>
|
package/dist/0~122.js
CHANGED
|
@@ -5,8 +5,8 @@ import node_events from "node:events";
|
|
|
5
5
|
import { Tinypool } from "tinypool";
|
|
6
6
|
import node_inspector from "node:inspector";
|
|
7
7
|
import { basename, TEMP_RSTEST_OUTPUT_DIR, dirname, posix, resolve as pathe_M_eThtNZ_resolve, serializableConfig, node_process, isBuiltin, castArray, TEMP_RSTEST_OUTPUT_DIR_GLOB, isDebug, ADDITIONAL_NODE_BUILTINS, join, needFlagExperimentalDetectModule } from "./946.js";
|
|
8
|
-
import { node_v8, fileURLToPath, createBirpc } from "./
|
|
9
|
-
import {
|
|
8
|
+
import { node_v8, fileURLToPath, createBirpc } from "./404.js";
|
|
9
|
+
import { core_logger, createRsbuild } from "./131.js";
|
|
10
10
|
const DefaultMaxHeapSize = 1073741824;
|
|
11
11
|
function memory_isMemorySufficient(options) {
|
|
12
12
|
const { memoryThreshold = 0.7, maxHeapSize = DefaultMaxHeapSize } = options || {};
|
|
@@ -185,6 +185,12 @@ const createPool = async ({ context, recommendWorkerCount = 1 / 0 })=>{
|
|
|
185
185
|
context.stateManager.onTestFileStart(test.testPath);
|
|
186
186
|
await Promise.all(reporters.map((reporter)=>reporter.onTestFileStart?.(test)));
|
|
187
187
|
},
|
|
188
|
+
onTestSuiteStart: async (test)=>{
|
|
189
|
+
await Promise.all(reporters.map((reporter)=>reporter.onTestSuiteStart?.(test)));
|
|
190
|
+
},
|
|
191
|
+
onTestSuiteResult: async (result)=>{
|
|
192
|
+
await Promise.all(reporters.map((reporter)=>reporter.onTestSuiteResult?.(result)));
|
|
193
|
+
},
|
|
188
194
|
resolveSnapshotPath: (testPath)=>{
|
|
189
195
|
const snapExtension = '.snap';
|
|
190
196
|
const resolver = context.normalizedConfig.resolveSnapshotPath || (()=>join(dirname(testPath), '__snapshots__', `${basename(testPath)}${snapExtension}`));
|
|
@@ -687,7 +693,7 @@ const isMultiCompiler = (compiler)=>'compilers' in compiler && Array.isArray(com
|
|
|
687
693
|
const prepareRsbuild = async (context, globTestSourceEntries, setupFiles)=>{
|
|
688
694
|
const { command, normalizedConfig: { isolate, dev = {}, coverage } } = context;
|
|
689
695
|
const debugMode = isDebug();
|
|
690
|
-
|
|
696
|
+
core_logger.level = debugMode ? 'verbose' : 'error';
|
|
691
697
|
const writeToDisk = dev.writeToDisk || debugMode;
|
|
692
698
|
const rsbuildInstance = await createRsbuild({
|
|
693
699
|
callerName: 'rstest',
|