vitest 5.0.0-beta.2 → 5.0.0-beta.4
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/dist/browser.d.ts +1 -1
- package/dist/browser.js +1 -1
- package/dist/chunks/{base.Opc_YHkk.js → base.BEGVMQrS.js} +6 -6
- package/dist/chunks/{browser.d.BUhkKcDl.d.ts → browser.d.BGxB4Xum.d.ts} +5 -26
- package/dist/chunks/{cac.8N4bOkkB.js → cac.CyXAEMkE.js} +26 -33
- package/dist/chunks/{cli-api.B0RFke2g.js → cli-api.DJMXq34b.js} +640 -615
- package/dist/chunks/{config.d.D91DHYaD.d.ts → config.d.DXq1aBpy.d.ts} +93 -89
- package/dist/chunks/{creator.BqL2U_x4.js → creator.D66cVXYh.js} +2 -2
- package/dist/chunks/{defaults.szbHWQun.js → defaults.CUUnbOrq.js} +6 -4
- package/dist/chunks/{env.D4Lgay0q.js → env.BKKtU2WC.js} +2 -1
- package/dist/chunks/global.d.BtKPuz2X.d.ts +194 -0
- package/dist/chunks/{globals.EHmmu0nC.js → globals.BuY-yD0m.js} +2 -1
- package/dist/chunks/{index.D_7-4CaB.js → index.CE58PZNH.js} +1660 -701
- package/dist/chunks/{index.CViWo__T.js → index.CcluKS59.js} +4 -4
- package/dist/chunks/{index.CbgUM9E5.js → index.nQFVd50u.js} +2 -1
- package/dist/chunks/{init-forks.DMge3WTt.js → init-forks.Ce3vGWgL.js} +1 -1
- package/dist/chunks/{init-threads.eIoyCTon.js → init-threads.8e1OLv5v.js} +1 -1
- package/dist/chunks/{init.BVd7SaCA.js → init.6qx-LaHs.js} +31 -3
- package/dist/chunks/{nativeModuleMocker.DKpFw0pk.js → nativeModuleMocker.DDZfQXLs.js} +1 -1
- package/dist/chunks/{plugin.d.cIKZEZ16.d.ts → plugin.d.B7MTG_Fe.d.ts} +103 -88
- package/dist/chunks/{rpc.d.7JZuxZ8u.d.ts → rpc.d.OQ_EZi1Z.d.ts} +18 -2
- package/dist/chunks/{setup-common.Hpq30zVk.js → setup-common.DdEF_hkE.js} +1 -1
- package/dist/chunks/{vm.2okbRRME.js → vm.Bu7mmcZq.js} +2 -2
- package/dist/chunks/{worker.d.Bu1kXGw4.d.ts → worker.d.yR22cs6X.d.ts} +3 -2
- package/dist/cli.js +2 -2
- package/dist/config.cjs +1 -1
- package/dist/config.d.ts +7 -10
- package/dist/config.js +2 -2
- package/dist/index.d.ts +24 -41
- package/dist/index.js +2 -1
- package/dist/module-evaluator.d.ts +4 -1
- package/dist/module-evaluator.js +15 -20
- package/dist/node.d.ts +20 -13
- package/dist/node.js +6 -6
- package/dist/runtime.js +2 -2
- package/dist/worker.d.ts +3 -3
- package/dist/worker.js +7 -6
- package/dist/workers/forks.js +8 -7
- package/dist/workers/runVmTests.js +4 -3
- package/dist/workers/threads.js +8 -7
- package/dist/workers/vmForks.js +4 -4
- package/dist/workers/vmThreads.js +4 -4
- package/package.json +20 -21
- package/dist/chunks/global.d.DhbKSQoV.d.ts +0 -99
package/dist/cli.js
CHANGED
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
import { c as createCLI } from './chunks/cac.
|
|
1
|
+
import { c as createCLI } from './chunks/cac.CyXAEMkE.js';
|
|
2
2
|
import '@vitest/utils/helpers';
|
|
3
3
|
import 'events';
|
|
4
4
|
import 'pathe';
|
|
5
5
|
import 'tinyrainbow';
|
|
6
|
-
import './chunks/env.
|
|
6
|
+
import './chunks/env.BKKtU2WC.js';
|
|
7
7
|
import 'std-env';
|
|
8
8
|
import './chunks/constants.-juJ8b_4.js';
|
|
9
9
|
import 'node:assert';
|
package/dist/config.cjs
CHANGED
|
@@ -60,7 +60,7 @@ const configDefaults = Object.freeze({
|
|
|
60
60
|
include: defaultInclude,
|
|
61
61
|
exclude: defaultExclude,
|
|
62
62
|
teardownTimeout: 1e4,
|
|
63
|
-
forceRerunTriggers: ["**/package.json
|
|
63
|
+
forceRerunTriggers: ["**/package.json", "**/{vitest,vite}.config.*"],
|
|
64
64
|
update: false,
|
|
65
65
|
reporters: [stdEnv.isAgent ? "minimal" : "default", ...process.env.GITHUB_ACTIONS === "true" ? ["github-actions"] : []],
|
|
66
66
|
silent: false,
|
package/dist/config.d.ts
CHANGED
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import { HookHandler, UserConfig, ConfigEnv } from 'vite';
|
|
2
2
|
export { ConfigEnv, Plugin, UserConfig as ViteUserConfig, mergeConfig } from 'vite';
|
|
3
|
-
import {
|
|
4
|
-
export {
|
|
5
|
-
import {
|
|
6
|
-
import './chunks/browser.d.
|
|
3
|
+
import { a1 as InlineConfig, aS as VitestPluginContext, I as CoverageOptions, aX as FieldsWithDefaultValues, aO as UserWorkspaceConfig, aY as UserProjectConfigFn, aZ as UserProjectConfigExport } from './chunks/plugin.d.B7MTG_Fe.js';
|
|
4
|
+
export { a_ as TestProjectConfiguration, a$ as TestProjectInlineConfiguration, U as TestUserConfig, aT as WatcherTriggerPattern } from './chunks/plugin.d.B7MTG_Fe.js';
|
|
5
|
+
import { C as Config } from './chunks/config.d.DXq1aBpy.js';
|
|
6
|
+
import './chunks/browser.d.BGxB4Xum.js';
|
|
7
7
|
export { TestTagDefinition } from '@vitest/runner';
|
|
8
8
|
import '@vitest/utils';
|
|
9
9
|
import 'node:stream';
|
|
@@ -11,14 +11,13 @@ import './chunks/general.d.DFAHgpC2.js';
|
|
|
11
11
|
import '@vitest/pretty-format';
|
|
12
12
|
import './chunks/environment.d-DOJxxZV9.d.DOJxxZV9.js';
|
|
13
13
|
import 'node:fs/promises';
|
|
14
|
-
import '@vitest/runner/types';
|
|
15
14
|
import '@vitest/utils/diff';
|
|
16
15
|
import 'chai';
|
|
17
16
|
import 'vitest/optional-types.js';
|
|
18
|
-
import './chunks/worker.d.
|
|
17
|
+
import './chunks/worker.d.yR22cs6X.js';
|
|
19
18
|
import 'vite/module-runner';
|
|
19
|
+
import './chunks/rpc.d.OQ_EZi1Z.js';
|
|
20
20
|
import './chunks/environment.d.CrsxCzP1.js';
|
|
21
|
-
import './chunks/rpc.d.7JZuxZ8u.js';
|
|
22
21
|
import '@vitest/mocker';
|
|
23
22
|
import '@vitest/utils/source-map';
|
|
24
23
|
import 'vitest/browser';
|
|
@@ -28,8 +27,6 @@ import 'node:fs';
|
|
|
28
27
|
import '@vitest/spy';
|
|
29
28
|
import 'tinyrainbow';
|
|
30
29
|
import '@vitest/utils/display';
|
|
31
|
-
import '@vitest/runner/utils';
|
|
32
|
-
import 'tinybench';
|
|
33
30
|
|
|
34
31
|
type VitestInlineConfig = InlineConfig;
|
|
35
32
|
declare module "vite" {
|
|
@@ -76,7 +73,7 @@ declare const configDefaults: Readonly<{
|
|
|
76
73
|
include: never[];
|
|
77
74
|
};
|
|
78
75
|
coverage: CoverageOptions;
|
|
79
|
-
fakeTimers:
|
|
76
|
+
fakeTimers: Config;
|
|
80
77
|
maxConcurrency: number;
|
|
81
78
|
dangerouslyIgnoreUnhandledErrors: boolean;
|
|
82
79
|
typecheck: {
|
package/dist/config.js
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
export { c as configDefaults, a as coverageConfigDefaults, d as defaultExclude, b as defaultInclude } from './chunks/defaults.
|
|
1
|
+
export { c as configDefaults, a as coverageConfigDefaults, d as defaultExclude, b as defaultInclude } from './chunks/defaults.CUUnbOrq.js';
|
|
2
2
|
export { mergeConfig } from 'vite';
|
|
3
3
|
export { d as defaultBrowserPort } from './chunks/constants.-juJ8b_4.js';
|
|
4
4
|
import 'node:os';
|
|
5
|
-
import './chunks/env.
|
|
5
|
+
import './chunks/env.BKKtU2WC.js';
|
|
6
6
|
import 'std-env';
|
|
7
7
|
|
|
8
8
|
function defineConfig(config) {
|
package/dist/index.d.ts
CHANGED
|
@@ -1,26 +1,25 @@
|
|
|
1
|
-
import { M as ModuleDefinitionDurationsDiagnostic, U as UntrackedModuleDefinitionDiagnostic, S as SerializedTestSpecification, E as ExpectStatic, a as MatcherState, b as SyncExpectationResult, A as AsyncExpectationResult, c as ExpectationResult,
|
|
2
|
-
export {
|
|
3
|
-
|
|
4
|
-
import { File, TestAnnotation, TestArtifact, TaskResultPack, TaskEventPack, Test, TaskPopulated, VitestRunner, VitestRunnerImportSource, Suite, Task, CancelReason, TestContext, ImportDuration, createTaskCollector, getCurrentSuite, getCurrentTest, getHooks, getFn } from '@vitest/runner';
|
|
5
|
-
export { CancelReason, ImportDuration, OnTestFailedHandler, OnTestFinishedHandler, RunMode, Task as RunnerTask, TaskBase as RunnerTaskBase, TaskEventPack as RunnerTaskEventPack, TaskResult as RunnerTaskResult, TaskResultPack as RunnerTaskResultPack, Test as RunnerTestCase, File as RunnerTestFile, Suite as RunnerTestSuite, SuiteAPI, SuiteCollector, SuiteFactory, SuiteOptions, TaskCustomOptions, TaskMeta, TaskState, TestAPI, TestAnnotation, TestAnnotationArtifact, TestArtifact, TestArtifactBase, TestArtifactLocation, TestArtifactRegistry, TestAttachment, TestContext, TestFunction, TestOptions, VitestRunnerConfig as TestRunnerConfig, TestTagDefinition, TestTags, VitestRunner as VitestTestRunner, afterAll, afterEach, aroundAll, aroundEach, beforeAll, beforeEach, describe, it, onTestFailed, onTestFinished, recordArtifact, suite, test } from '@vitest/runner';
|
|
1
|
+
import { M as ModuleDefinitionDurationsDiagnostic, U as UntrackedModuleDefinitionDiagnostic, S as SerializedTestSpecification, E as ExpectStatic, a as MatcherState, b as SyncExpectationResult, A as AsyncExpectationResult, c as ExpectationResult, d as ModuleDefinitionDiagnostic, e as ModuleDefinitionLocation, f as SourceModuleDiagnostic, g as SourceModuleLocations } from './chunks/browser.d.BGxB4Xum.js';
|
|
2
|
+
export { h as Assertion, i as AsymmetricMatchersContaining, B as BrowserTesterOptions, D as DeeplyAllowMatchers, J as JestAssertion, R as Matcher, j as Matchers, k as MatchersObject } from './chunks/browser.d.BGxB4Xum.js';
|
|
3
|
+
export { B as Bench, a as BenchFnOptions, b as BenchFromSource, c as BenchRegistration, d as BenchResult, e as BenchStorage } from './chunks/global.d.BtKPuz2X.js';
|
|
4
|
+
import { File, TestAnnotation, TestArtifact, TaskResultPack, TaskEventPack, Test, TaskPopulated, VitestRunner, VitestRunnerImportSource, Suite, Task, CancelReason, TestTryOptions, TestContext, ImportDuration, createTaskCollector, getCurrentSuite, getCurrentTest, getHooks, getFn } from '@vitest/runner';
|
|
5
|
+
export { BaselineData, CancelReason, ImportDuration, OnTestFailedHandler, OnTestFinishedHandler, RunMode, Task as RunnerTask, TaskBase as RunnerTaskBase, TaskEventPack as RunnerTaskEventPack, TaskResult as RunnerTaskResult, TaskResultPack as RunnerTaskResultPack, Test as RunnerTestCase, File as RunnerTestFile, Suite as RunnerTestSuite, SuiteAPI, SuiteCollector, SuiteFactory, SuiteOptions, TaskCustomOptions, TaskMeta, TaskState, TestAPI, TestAnnotation, TestAnnotationArtifact, TestArtifact, TestArtifactBase, TestArtifactLocation, TestArtifactRegistry, TestAttachment, TestBenchmark, TestBenchmarkTask, TestContext, TestFunction, TestOptions, VitestRunnerConfig as TestRunnerConfig, TestTagDefinition, TestTags, VitestRunner as VitestTestRunner, afterAll, afterEach, aroundAll, aroundEach, beforeAll, beforeEach, describe, it, onTestFailed, onTestFinished, recordArtifact, suite, test } from '@vitest/runner';
|
|
6
6
|
import { Awaitable } from '@vitest/utils';
|
|
7
7
|
export { ParsedStack, SerializedError, TestError } from '@vitest/utils';
|
|
8
|
-
import { B as BirpcReturn } from './chunks/worker.d.
|
|
9
|
-
export { C as ContextRPC, a as ContextTestEnvironment, T as TestExecutionMethod, W as WorkerGlobalState } from './chunks/worker.d.
|
|
10
|
-
import { S as SerializedRootConfig,
|
|
11
|
-
export { b as RuntimeConfig, c as SerializedCoverageConfig } from './chunks/config.d.
|
|
8
|
+
import { B as BirpcReturn } from './chunks/worker.d.yR22cs6X.js';
|
|
9
|
+
export { C as ContextRPC, a as ContextTestEnvironment, T as TestExecutionMethod, W as WorkerGlobalState } from './chunks/worker.d.yR22cs6X.js';
|
|
10
|
+
import { S as SerializedRootConfig, C as Config, R as RuntimeOptions, a as SerializedConfig } from './chunks/config.d.DXq1aBpy.js';
|
|
11
|
+
export { b as RuntimeConfig, c as SerializedCoverageConfig } from './chunks/config.d.DXq1aBpy.js';
|
|
12
12
|
import { U as UserConsoleLog, L as LabelColor, M as ModuleGraphData, P as ProvidedContext, D as DomainSnapshotAdapter } from './chunks/general.d.DFAHgpC2.js';
|
|
13
13
|
export { A as AfterSuiteRunMeta, a as DomainMatchResult, S as SnapshotData, b as SnapshotMatchOptions, c as SnapshotResult, d as SnapshotSerializer, e as SnapshotStateOptions, f as SnapshotSummary, g as SnapshotUpdateState, h as UncheckedSnapshot } from './chunks/general.d.DFAHgpC2.js';
|
|
14
14
|
import { spyOn, fn, MaybeMockedDeep, MaybeMocked, MaybePartiallyMocked, MaybePartiallyMockedDeep, MockInstance } from '@vitest/spy';
|
|
15
15
|
export { Mock, MockContext, MockInstance, MockResult, MockResultIncomplete, MockResultReturn, MockResultThrow, MockSettledResult, MockSettledResultFulfilled, MockSettledResultIncomplete, MockSettledResultRejected, Mocked, MockedClass, MockedFunction, MockedObject } from '@vitest/spy';
|
|
16
16
|
import { Disposable } from 'vitest/optional-runtime-types.js';
|
|
17
17
|
import { ModuleMockFactoryWithHelper, ModuleMockOptions } from '@vitest/mocker';
|
|
18
|
-
import * as tinybench from 'tinybench';
|
|
19
|
-
import { Options } from 'tinybench';
|
|
20
|
-
export { Bench as BenchFactory, Options as BenchOptions, Task as BenchTask, TaskResult as BenchTaskResult } from 'tinybench';
|
|
21
18
|
export { V as EvaluatedModules } from './chunks/evaluatedModules.d.BxJ5omdx.js';
|
|
22
|
-
import {
|
|
23
|
-
export {
|
|
19
|
+
import { Bench, Task as Task$1 } from 'tinybench';
|
|
20
|
+
export { BenchOptions as BenchCompareOptions } from 'tinybench';
|
|
21
|
+
import { T as Traces } from './chunks/rpc.d.OQ_EZi1Z.js';
|
|
22
|
+
export { R as RunnerRPC, a as RuntimeRPC } from './chunks/rpc.d.OQ_EZi1Z.js';
|
|
24
23
|
import { createChainable, matchesTags } from '@vitest/runner/utils';
|
|
25
24
|
export { ExpectTypeOf, expectTypeOf } from 'expect-type';
|
|
26
25
|
export { DiffOptions } from '@vitest/utils/diff';
|
|
@@ -71,8 +70,8 @@ interface WebSocketHandlers {
|
|
|
71
70
|
name: string;
|
|
72
71
|
color?: LabelColor;
|
|
73
72
|
}[];
|
|
74
|
-
getModuleGraph: (projectName: string, id: string
|
|
75
|
-
getTransformResult: (projectName: string, id: string, testFileId: string
|
|
73
|
+
getModuleGraph: (projectName: string, id: string) => Promise<ModuleGraphData>;
|
|
74
|
+
getTransformResult: (projectName: string, id: string, testFileId: string) => Promise<TransformResultWithSource | undefined>;
|
|
76
75
|
getExternalResult: (id: string, testFileId: string) => Promise<ExternalResult | undefined>;
|
|
77
76
|
readTestFile: (id: string) => Promise<string | null>;
|
|
78
77
|
saveTestFile: (id: string, content: string) => Promise<void>;
|
|
@@ -221,7 +220,7 @@ interface VitestUtils {
|
|
|
221
220
|
/**
|
|
222
221
|
* This method wraps all further calls to timers until [`vi.useRealTimers()`](https://vitest.dev/api/vi#vi-userealtimers) is called.
|
|
223
222
|
*/
|
|
224
|
-
useFakeTimers: (config?:
|
|
223
|
+
useFakeTimers: (config?: Config) => VitestUtils;
|
|
225
224
|
/**
|
|
226
225
|
* Restores mocked timers to their original implementations. All timers that were scheduled before will be discarded.
|
|
227
226
|
*/
|
|
@@ -625,20 +624,6 @@ interface VitestUtils {
|
|
|
625
624
|
declare const vitest: VitestUtils;
|
|
626
625
|
declare const vi: VitestUtils;
|
|
627
626
|
|
|
628
|
-
declare function getBenchOptions(key: Test): Options;
|
|
629
|
-
declare function getBenchFn(key: Test): BenchFunction;
|
|
630
|
-
declare const bench: BenchmarkAPI;
|
|
631
|
-
|
|
632
|
-
declare class NodeBenchmarkRunner implements VitestRunner {
|
|
633
|
-
config: SerializedConfig;
|
|
634
|
-
private moduleRunner;
|
|
635
|
-
constructor(config: SerializedConfig);
|
|
636
|
-
importTinybench(): Promise<typeof tinybench>;
|
|
637
|
-
importFile(filepath: string, source: VitestRunnerImportSource): unknown;
|
|
638
|
-
runSuite(suite: Suite): Promise<void>;
|
|
639
|
-
runTask(): Promise<void>;
|
|
640
|
-
}
|
|
641
|
-
|
|
642
627
|
declare class TestRunner implements VitestRunner {
|
|
643
628
|
config: SerializedConfig;
|
|
644
629
|
private snapshotClient;
|
|
@@ -646,22 +631,22 @@ declare class TestRunner implements VitestRunner {
|
|
|
646
631
|
private moduleRunner;
|
|
647
632
|
private cancelRun;
|
|
648
633
|
private assertionsErrors;
|
|
634
|
+
private benchInstances;
|
|
649
635
|
pool: string;
|
|
650
|
-
private _otel;
|
|
651
636
|
viteEnvironment: string;
|
|
652
637
|
private viteModuleRunner;
|
|
653
638
|
constructor(config: SerializedConfig);
|
|
654
639
|
importFile(filepath: string, source: VitestRunnerImportSource): unknown;
|
|
655
640
|
onCollectStart(file: File): void;
|
|
656
641
|
onCleanupWorkerContext(listener: () => unknown): void;
|
|
657
|
-
onAfterRunFiles(): void;
|
|
642
|
+
onAfterRunFiles(_files: File[]): void;
|
|
658
643
|
onAfterRunSuite(suite: Suite): Promise<void>;
|
|
659
644
|
onAfterRunTask(test: Task): void;
|
|
660
645
|
cancel(_reason: CancelReason): void;
|
|
661
646
|
injectValue(key: string): any;
|
|
662
647
|
onBeforeRunTask(test: Task): Promise<void>;
|
|
663
648
|
onBeforeRunSuite(suite: Suite): Promise<void>;
|
|
664
|
-
onBeforeTryTask(test: Task): void;
|
|
649
|
+
onBeforeTryTask(test: Task, _options: TestTryOptions): void;
|
|
665
650
|
onAfterTryTask(test: Test): void;
|
|
666
651
|
extendTaskContext(context: TestContext): TestContext;
|
|
667
652
|
getImportDurations(): Record<string, ImportDuration>;
|
|
@@ -677,13 +662,11 @@ declare class TestRunner implements VitestRunner {
|
|
|
677
662
|
static setTestFn: typeof getFn;
|
|
678
663
|
static matchesTags: typeof matchesTags;
|
|
679
664
|
/**
|
|
680
|
-
* @
|
|
681
|
-
|
|
682
|
-
|
|
683
|
-
/**
|
|
684
|
-
* @deprecated
|
|
665
|
+
* @experimental
|
|
666
|
+
* A function that runs tinybench tasks.
|
|
667
|
+
* Can be overriden to run tasks in a special environment.
|
|
685
668
|
*/
|
|
686
|
-
static
|
|
669
|
+
static runBenchmarks(tinybench: Bench): Promise<Task$1[]>;
|
|
687
670
|
}
|
|
688
671
|
|
|
689
672
|
interface AssertType {
|
|
@@ -700,5 +683,5 @@ declare namespace Experimental {
|
|
|
700
683
|
export { ModuleDefinitionDiagnostic, ModuleDefinitionDurationsDiagnostic, ModuleDefinitionLocation, SourceModuleDiagnostic, SourceModuleLocations, UntrackedModuleDefinitionDiagnostic };
|
|
701
684
|
}
|
|
702
685
|
|
|
703
|
-
export { AsyncExpectationResult as AsyncMatcherResult,
|
|
686
|
+
export { AsyncExpectationResult as AsyncMatcherResult, DomainSnapshotAdapter, ExpectStatic, Experimental, LabelColor, ExpectationResult as MatcherResult, MatcherState, ModuleGraphData, ProvidedContext, SerializedConfig, SerializedRootConfig, SerializedTestSpecification, Snapshots, SyncExpectationResult as SyncMatcherResult, TestRunner, UserConsoleLog, assert, assertType, createExpect, globalExpect as expect, inject, should, vi, vitest };
|
|
704
687
|
export type { AssertType, BrowserUI, ExternalResult, TransformResultWithSource, VitestUtils, WebSocketEvents, WebSocketHandlers, WebSocketRPC };
|
package/dist/index.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
export {
|
|
1
|
+
export { S as Snapshots, T as TestRunner, a as assert, b as assertType, c as createExpect, g as expect, d as inject, s as should, v as vi, e as vitest } from './chunks/index.CE58PZNH.js';
|
|
2
2
|
export { V as EvaluatedModules } from './chunks/rpc.DFRWVnRh.js';
|
|
3
3
|
export { expectTypeOf } from 'expect-type';
|
|
4
4
|
export { afterAll, afterEach, aroundAll, aroundEach, beforeAll, beforeEach, describe, it, onTestFailed, onTestFinished, recordArtifact, suite, test } from '@vitest/runner';
|
|
@@ -19,5 +19,6 @@ import '@vitest/utils/diff';
|
|
|
19
19
|
import '@vitest/utils/display';
|
|
20
20
|
import 'tinyrainbow';
|
|
21
21
|
import 'pathe';
|
|
22
|
+
import 'tinybench';
|
|
22
23
|
import 'vite/module-runner';
|
|
23
24
|
import './chunks/index.Chj8NDwU.js';
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { ModuleEvaluator, ModuleRunnerImportMeta, ModuleRunnerContext, EvaluatedModuleNode } from 'vite/module-runner';
|
|
2
|
+
import { a as RuntimeRPC, G as GetterTracker } from './chunks/rpc.d.OQ_EZi1Z.js';
|
|
2
3
|
import { V as VitestEvaluatedModules } from './chunks/evaluatedModules.d.BxJ5omdx.js';
|
|
3
4
|
import vm from 'node:vm';
|
|
4
|
-
import { a as RuntimeRPC } from './chunks/rpc.d.7JZuxZ8u.js';
|
|
5
5
|
import '@vitest/runner';
|
|
6
6
|
import './chunks/general.d.DFAHgpC2.js';
|
|
7
7
|
import '@vitest/pretty-format';
|
|
@@ -105,6 +105,7 @@ interface VitestModuleEvaluatorOptions {
|
|
|
105
105
|
getCurrentTestFilepath?: () => string | undefined;
|
|
106
106
|
compiledFunctionArgumentsNames?: string[];
|
|
107
107
|
compiledFunctionArgumentsValues?: unknown[];
|
|
108
|
+
getterTracker?: GetterTracker;
|
|
108
109
|
}
|
|
109
110
|
declare class VitestModuleEvaluator implements ModuleEvaluator {
|
|
110
111
|
private options;
|
|
@@ -113,6 +114,8 @@ declare class VitestModuleEvaluator implements ModuleEvaluator {
|
|
|
113
114
|
private vm;
|
|
114
115
|
private compiledFunctionArgumentsNames?;
|
|
115
116
|
private compiledFunctionArgumentsValues;
|
|
117
|
+
private getterTracker;
|
|
118
|
+
static EXPORTS_MAX_INVOCATIONS: number;
|
|
116
119
|
private primitives;
|
|
117
120
|
private debug;
|
|
118
121
|
private _otel;
|
package/dist/module-evaluator.js
CHANGED
|
@@ -38,6 +38,8 @@ class VitestModuleEvaluator {
|
|
|
38
38
|
vm;
|
|
39
39
|
compiledFunctionArgumentsNames;
|
|
40
40
|
compiledFunctionArgumentsValues = [];
|
|
41
|
+
getterTracker;
|
|
42
|
+
static EXPORTS_MAX_INVOCATIONS = 1e6;
|
|
41
43
|
primitives;
|
|
42
44
|
debug = new ModuleDebug();
|
|
43
45
|
_otel;
|
|
@@ -56,6 +58,7 @@ class VitestModuleEvaluator {
|
|
|
56
58
|
Proxy,
|
|
57
59
|
Reflect
|
|
58
60
|
};
|
|
61
|
+
this.getterTracker = options.getterTracker;
|
|
59
62
|
}
|
|
60
63
|
convertIdToImportUrl(id) {
|
|
61
64
|
// TODO: vitest returns paths for external modules, but Vite returns file://
|
|
@@ -180,6 +183,7 @@ class VitestModuleEvaluator {
|
|
|
180
183
|
argumentsList.push(
|
|
181
184
|
// TODO@discuss deprecate in Vitest 5, remove in Vitest 6(?)
|
|
182
185
|
// backwards compat for vite-node
|
|
186
|
+
// https://github.com/vitest-dev/vitest/issues/10292
|
|
183
187
|
"__filename",
|
|
184
188
|
"__dirname",
|
|
185
189
|
"module",
|
|
@@ -203,25 +207,16 @@ class VitestModuleEvaluator {
|
|
|
203
207
|
importer
|
|
204
208
|
});
|
|
205
209
|
try {
|
|
206
|
-
|
|
207
|
-
|
|
208
|
-
|
|
209
|
-
|
|
210
|
-
|
|
211
|
-
|
|
212
|
-
|
|
213
|
-
|
|
214
|
-
|
|
215
|
-
|
|
216
|
-
get: getter
|
|
217
|
-
})),
|
|
218
|
-
cjsGlobals.__filename,
|
|
219
|
-
cjsGlobals.__dirname,
|
|
220
|
-
cjsGlobals.module,
|
|
221
|
-
cjsGlobals.exports,
|
|
222
|
-
cjsGlobals.require,
|
|
223
|
-
...this.compiledFunctionArgumentsValues
|
|
224
|
-
);
|
|
210
|
+
const initModule = this.vm ? vm.runInContext(wrappedCode, this.vm.context, options) : vm.runInThisContext(wrappedCode, options);
|
|
211
|
+
const __vite_ssr_exportName__ = context.__vite_ssr_exportName__ || ((name, getter) => Object.defineProperty(context[ssrModuleExportsKey], name, {
|
|
212
|
+
enumerable: true,
|
|
213
|
+
configurable: true,
|
|
214
|
+
get: getter
|
|
215
|
+
}));
|
|
216
|
+
let __vite_track_exportName__;
|
|
217
|
+
const getterTracker = this.getterTracker;
|
|
218
|
+
if (getterTracker) __vite_track_exportName__ = getterTracker.createTracker(module.id, __vite_ssr_exportName__);
|
|
219
|
+
await initModule(context[ssrModuleExportsKey], context[ssrImportMetaKey], context[ssrImportKey], context[ssrDynamicImportKey], context[ssrExportAllKey], __vite_track_exportName__ || __vite_ssr_exportName__, cjsGlobals.__filename, cjsGlobals.__dirname, cjsGlobals.module, cjsGlobals.exports, cjsGlobals.require, ...this.compiledFunctionArgumentsValues);
|
|
225
220
|
} finally {
|
|
226
221
|
// moduleExecutionInfo needs to use Node filename instead of the normalized one
|
|
227
222
|
// because we rely on this behaviour in coverage-v8, for example
|
|
@@ -339,7 +334,7 @@ function interopModule(mod) {
|
|
|
339
334
|
defaultExport: mod
|
|
340
335
|
};
|
|
341
336
|
let defaultExport = "default" in mod ? mod.default : mod;
|
|
342
|
-
if (!isPrimitive(defaultExport) &&
|
|
337
|
+
if (!isPrimitive(defaultExport) && defaultExport.__esModule) {
|
|
343
338
|
mod = defaultExport;
|
|
344
339
|
if ("default" in defaultExport) defaultExport = defaultExport.default;
|
|
345
340
|
}
|
package/dist/node.d.ts
CHANGED
|
@@ -3,24 +3,23 @@ import { InlineConfig, UserConfig as UserConfig$1, TransformResult, Plugin, Reso
|
|
|
3
3
|
export { vite as Vite };
|
|
4
4
|
export { esbuildVersion, isCSSRequest, isFileLoadingAllowed, parseAst, parseAstAsync, rollupVersion, version as viteVersion } from 'vite';
|
|
5
5
|
import { IncomingMessage } from 'node:http';
|
|
6
|
-
import { R as ResolvedConfig, U as UserConfig, V as
|
|
7
|
-
export { M as AgentReporter, B as BaseCoverageOptions, h as BaseReporter, i as
|
|
8
|
-
import './chunks/browser.d.
|
|
6
|
+
import { R as ResolvedConfig, U as UserConfig, V as VitestOptions, a as Vitest, b as VitestRunMode, A as ApiConfig, L as Logger, c as ResolvedCoverageOptions, C as CoverageMap, d as ReportContext, T as TestProject, e as TestSpecification, P as PoolWorker, f as PoolOptions, W as WorkerRequest, g as TestSequencer } from './chunks/plugin.d.B7MTG_Fe.js';
|
|
7
|
+
export { M as AgentReporter, B as BaseCoverageOptions, h as BaseReporter, i as BenchmarkUserOptions, j as BrowserBuiltinProvider, k as BrowserCommand, l as BrowserCommandContext, m as BrowserConfigOptions, n as BrowserInstanceOption, o as BrowserModuleMocker, p as BrowserOrchestrator, q as BrowserProvider, r as BrowserProviderOption, s as BrowserScript, t as BrowserServerFactory, u as BrowserServerOptions, v as BrowserServerState, w as BrowserServerStateSession, x as BuiltinEnvironment, y as BuiltinReporterOptions, z as BuiltinReporters, D as CSSModuleScopeStrategy, E as CacheKeyIdGenerator, F as CacheKeyIdGeneratorContext, G as CoverageInstrumenter, H as CoverageIstanbulOptions, I as CoverageOptions, J as CoverageProvider, K as CoverageProviderModule, N as CoverageReporter, O as CoverageV8Options, Q as CustomProviderOptions, S as DefaultReporter, X as DepsOptimizationOptions, Y as DotReporter, Z as EnvironmentOptions, _ as GithubActionsReporter, $ as HTMLOptions, a0 as HangingProcessReporter, a1 as InlineConfig, a2 as InstrumenterOptions, a3 as JUnitOptions, a4 as JUnitReporter, a5 as JsonAssertionResult, a6 as JsonOptions, a7 as JsonReporter, a8 as JsonTestResult, a9 as JsonTestResults, M as MinimalReporter, aa as ModuleDiagnostic, ab as OnServerRestartHandler, ac as OnTestsRerunHandler, ad as ParentProjectBrowser, ae as Pool, af as PoolRunnerInitializer, ag as PoolTask, ah as ProjectBrowser, ai as ProjectConfig, aj as Report, ak as ReportedHookContext, al as Reporter, am as ReportersMap, an as ResolveSnapshotPathHandler, ao as ResolveSnapshotPathHandlerContext, ap as ResolvedBrowserOptions, aq as ResolvedProjectConfig, ar as SerializedTestProject, as as TapFlatReporter, at as TapReporter, au as TaskOptions, av as TestCase, aw as TestCollection, ax as TestDiagnostic, ay as TestModule, az as TestModuleState, aA as TestResult, aB as TestResultFailed, aC as TestResultPassed, aD as TestResultSkipped, aE as TestRunEndReason, aF as TestRunResult, aG as TestSequencerConstructor, aH as TestSpecificationOptions, aI as TestState, aJ as TestSuite, aK as TestSuiteState, aL as ToMatchScreenshotComparators, aM as ToMatchScreenshotOptions, aN as TypecheckConfig, aO as UserWorkspaceConfig, aP as VerboseReporter, aQ as VitestEnvironment, aR as VitestPackageInstaller, aS as VitestPluginContext, aT as WatcherTriggerPattern, aU as WorkerResponse, aV as _BrowserNames, aW as experimental_getRunnerTask } from './chunks/plugin.d.B7MTG_Fe.js';
|
|
8
|
+
import './chunks/browser.d.BGxB4Xum.js';
|
|
9
9
|
import { A as AfterSuiteRunMeta } from './chunks/general.d.DFAHgpC2.js';
|
|
10
10
|
import { Awaitable } from '@vitest/utils';
|
|
11
11
|
export { SerializedError } from '@vitest/utils';
|
|
12
|
-
import { a as RuntimeRPC } from './chunks/rpc.d.
|
|
12
|
+
import { a as RuntimeRPC } from './chunks/rpc.d.OQ_EZi1Z.js';
|
|
13
13
|
import { Writable } from 'node:stream';
|
|
14
|
-
import { C as ContextRPC } from './chunks/worker.d.
|
|
15
|
-
export { T as TestExecutionType } from './chunks/worker.d.
|
|
14
|
+
import { C as ContextRPC } from './chunks/worker.d.yR22cs6X.js';
|
|
15
|
+
export { T as TestExecutionType } from './chunks/worker.d.yR22cs6X.js';
|
|
16
16
|
import { Debugger } from 'obug';
|
|
17
|
-
import './chunks/global.d.
|
|
17
|
+
import './chunks/global.d.BtKPuz2X.js';
|
|
18
18
|
export { Task as RunnerTask, TaskResult as RunnerTaskResult, TaskResultPack as RunnerTaskResultPack, Test as RunnerTestCase, File as RunnerTestFile, Suite as RunnerTestSuite, SequenceHooks, SequenceSetupFiles } from '@vitest/runner';
|
|
19
|
-
export { b as RuntimeConfig } from './chunks/config.d.
|
|
19
|
+
export { b as RuntimeConfig } from './chunks/config.d.DXq1aBpy.js';
|
|
20
20
|
export { generateFileHash } from '@vitest/runner/utils';
|
|
21
21
|
export { CDPSession } from 'vitest/browser';
|
|
22
22
|
import 'node:fs/promises';
|
|
23
|
-
import '@vitest/runner/types';
|
|
24
23
|
import '@vitest/pretty-format';
|
|
25
24
|
import '@vitest/utils/diff';
|
|
26
25
|
import 'chai';
|
|
@@ -33,10 +32,12 @@ import 'node:fs';
|
|
|
33
32
|
import '@vitest/spy';
|
|
34
33
|
import 'tinyrainbow';
|
|
35
34
|
import '@vitest/utils/display';
|
|
36
|
-
import 'tinybench';
|
|
37
35
|
import './chunks/environment.d-DOJxxZV9.d.DOJxxZV9.js';
|
|
38
36
|
import 'vite/module-runner';
|
|
39
37
|
import './chunks/environment.d.CrsxCzP1.js';
|
|
38
|
+
import 'tinybench';
|
|
39
|
+
|
|
40
|
+
declare function escapeTestName(label: string, dynamic: boolean): string;
|
|
40
41
|
|
|
41
42
|
type RawErrsMap = Map<string, TscErrorInfo[]>;
|
|
42
43
|
interface TscErrorInfo {
|
|
@@ -64,8 +65,6 @@ type Context = RootAndTarget & {
|
|
|
64
65
|
|
|
65
66
|
declare function isValidApiRequest(config: ResolvedConfig, req: IncomingMessage): boolean;
|
|
66
67
|
|
|
67
|
-
declare function escapeTestName(label: string, dynamic: boolean): string;
|
|
68
|
-
|
|
69
68
|
interface CliOptions extends UserConfig {
|
|
70
69
|
/**
|
|
71
70
|
* Override the watch mode
|
|
@@ -108,6 +107,10 @@ interface CliOptions extends UserConfig {
|
|
|
108
107
|
*
|
|
109
108
|
* Returns a Vitest instance if initialized successfully.
|
|
110
109
|
*/
|
|
110
|
+
declare function startVitest(cliFilters?: string[], options?: CliOptions, viteOverrides?: UserConfig$1, vitestOptions?: VitestOptions): Promise<Vitest>;
|
|
111
|
+
/**
|
|
112
|
+
* @deprecated The `mode` argument is no longer used. Use `startVitest(cliFilters?, options?, viteOverrides?, vitestOptions?)` instead.
|
|
113
|
+
*/
|
|
111
114
|
declare function startVitest(mode: VitestRunMode, cliFilters?: string[], options?: CliOptions, viteOverrides?: UserConfig$1, vitestOptions?: VitestOptions): Promise<Vitest>;
|
|
112
115
|
|
|
113
116
|
interface CliParseOptions {
|
|
@@ -217,11 +220,15 @@ declare class BaseCoverageProvider {
|
|
|
217
220
|
createUncoveredFileTransformer(ctx: Vitest): (filename: string) => Promise<TransformResult | null | undefined>;
|
|
218
221
|
}
|
|
219
222
|
|
|
223
|
+
declare function createVitest(options: CliOptions, viteOverrides?: UserConfig$1, vitestOptions?: VitestOptions): Promise<Vitest>;
|
|
224
|
+
/**
|
|
225
|
+
* @deprecated The `mode` argument is no longer used. Use `createVitest(options, viteOverrides?, vitestOptions?)` instead.
|
|
226
|
+
*/
|
|
220
227
|
declare function createVitest(mode: VitestRunMode, options: CliOptions, viteOverrides?: UserConfig$1, vitestOptions?: VitestOptions): Promise<Vitest>;
|
|
221
228
|
|
|
222
229
|
declare class FilesNotFoundError extends Error {
|
|
223
230
|
code: string;
|
|
224
|
-
constructor(
|
|
231
|
+
constructor();
|
|
225
232
|
}
|
|
226
233
|
declare class GitNotFoundError extends Error {
|
|
227
234
|
code: string;
|
package/dist/node.js
CHANGED
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import * as vite from 'vite';
|
|
2
2
|
import { resolveConfig as resolveConfig$1, mergeConfig } from 'vite';
|
|
3
3
|
export { esbuildVersion, isCSSRequest, isFileLoadingAllowed, parseAst, parseAstAsync, rollupVersion, version as viteVersion } from 'vite';
|
|
4
|
-
import { V as Vitest, a as VitestPlugin, r as resolveConfig$2 } from './chunks/cli-api.
|
|
5
|
-
export { M as AgentReporter, B as BaseCoverageProvider, b as BaseSequencer,
|
|
6
|
-
export { p as parseCLI } from './chunks/cac.
|
|
4
|
+
import { V as Vitest, a as VitestPlugin, r as resolveConfig$2 } from './chunks/cli-api.DJMXq34b.js';
|
|
5
|
+
export { M as AgentReporter, B as BaseCoverageProvider, b as BaseSequencer, D as DefaultReporter, c as DotReporter, F as ForksPoolWorker, G as GitNotFoundError, d as GithubActionsReporter, H as HangingProcessReporter, J as JUnitReporter, e as JsonReporter, M as MinimalReporter, R as ReportersMap, T as TapFlatReporter, f as TapReporter, g as TestsNotFoundError, h as ThreadsPoolWorker, i as TypecheckPoolWorker, j as VerboseReporter, k as VitestPackageInstaller, l as VmForksPoolWorker, m as VmThreadsPoolWorker, n as createDebugger, o as createMethodsRPC, p as createViteLogger, q as createVitest, s as escapeTestName, t as experimental_getRunnerTask, u as getFilePoolName, v as isFileServingAllowed, w as isValidApiRequest, x as registerConsoleShortcuts, y as resolveApiServerConfig, z as resolveFsAllow, A as startVitest } from './chunks/cli-api.DJMXq34b.js';
|
|
6
|
+
export { p as parseCLI } from './chunks/cac.CyXAEMkE.js';
|
|
7
7
|
import { slash, deepClone } from '@vitest/utils/helpers';
|
|
8
8
|
import { a as any } from './chunks/index.og1WyBLx.js';
|
|
9
9
|
import { resolve } from 'pathe';
|
|
@@ -29,8 +29,8 @@ import 'obug';
|
|
|
29
29
|
import 'node:crypto';
|
|
30
30
|
import 'tinyrainbow';
|
|
31
31
|
import 'tinyglobby';
|
|
32
|
-
import './chunks/defaults.
|
|
33
|
-
import './chunks/env.
|
|
32
|
+
import './chunks/defaults.CUUnbOrq.js';
|
|
33
|
+
import './chunks/env.BKKtU2WC.js';
|
|
34
34
|
import 'std-env';
|
|
35
35
|
import './chunks/utils.DKODp04v.js';
|
|
36
36
|
import '@vitest/utils/display';
|
|
@@ -73,7 +73,7 @@ async function resolveConfig(options = {}, viteOverrides = {}) {
|
|
|
73
73
|
const root = slash(resolve(options.root || process.cwd()));
|
|
74
74
|
const configPath = options.config === false ? false : options.config ? resolve(root, options.config) : any(configFiles, { cwd: root });
|
|
75
75
|
options.config = configPath;
|
|
76
|
-
const vitest = new Vitest(
|
|
76
|
+
const vitest = new Vitest(deepClone(options));
|
|
77
77
|
const config = await resolveConfig$1(mergeConfig({
|
|
78
78
|
configFile: configPath,
|
|
79
79
|
mode: options.mode || "test",
|
package/dist/runtime.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { VitestModuleEvaluator } from './module-evaluator.js';
|
|
2
|
-
import { V as VITEST_VM_CONTEXT_SYMBOL, s as startVitestModuleRunner, a as VitestModuleRunner } from './chunks/index.
|
|
3
|
-
export { e as builtinEnvironments, p as populateGlobal } from './chunks/index.
|
|
2
|
+
import { V as VITEST_VM_CONTEXT_SYMBOL, s as startVitestModuleRunner, a as VitestModuleRunner } from './chunks/index.nQFVd50u.js';
|
|
3
|
+
export { e as builtinEnvironments, p as populateGlobal } from './chunks/index.nQFVd50u.js';
|
|
4
4
|
import { g as getWorkerState } from './chunks/utils.BX5Fg8C4.js';
|
|
5
5
|
export { VitestNodeSnapshotEnvironment as VitestSnapshotEnvironment } from './chunks/node.CwFbQqI1.js';
|
|
6
6
|
import 'node:module';
|
package/dist/worker.d.ts
CHANGED
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
import { W as WorkerGlobalState, d as WorkerSetupContext, e as BirpcOptions } from './chunks/worker.d.
|
|
2
|
-
import { T as Traces, a as RuntimeRPC } from './chunks/rpc.d.
|
|
1
|
+
import { W as WorkerGlobalState, d as WorkerSetupContext, e as BirpcOptions } from './chunks/worker.d.yR22cs6X.js';
|
|
2
|
+
import { T as Traces, a as RuntimeRPC } from './chunks/rpc.d.OQ_EZi1Z.js';
|
|
3
3
|
import { Awaitable } from '@vitest/utils';
|
|
4
4
|
import { ModuleRunner } from 'vite/module-runner';
|
|
5
5
|
import '@vitest/runner';
|
|
6
|
-
import './chunks/config.d.
|
|
6
|
+
import './chunks/config.d.DXq1aBpy.js';
|
|
7
7
|
import '@vitest/pretty-format';
|
|
8
8
|
import './chunks/general.d.DFAHgpC2.js';
|
|
9
9
|
import './chunks/environment.d-DOJxxZV9.d.DOJxxZV9.js';
|
package/dist/worker.js
CHANGED
|
@@ -1,11 +1,11 @@
|
|
|
1
|
-
export { r as runBaseTests, s as setupEnvironment } from './chunks/base.
|
|
2
|
-
export { i as init } from './chunks/init.
|
|
1
|
+
export { r as runBaseTests, s as setupEnvironment } from './chunks/base.BEGVMQrS.js';
|
|
2
|
+
export { i as init } from './chunks/init.6qx-LaHs.js';
|
|
3
3
|
import 'node:vm';
|
|
4
4
|
import '@vitest/spy';
|
|
5
|
-
import './chunks/index.
|
|
5
|
+
import './chunks/index.CcluKS59.js';
|
|
6
6
|
import 'chai';
|
|
7
7
|
import 'node:async_hooks';
|
|
8
|
-
import './chunks/setup-common.
|
|
8
|
+
import './chunks/setup-common.DdEF_hkE.js';
|
|
9
9
|
import './chunks/coverage.CTzCuANN.js';
|
|
10
10
|
import '@vitest/utils/timers';
|
|
11
11
|
import './chunks/utils.BX5Fg8C4.js';
|
|
@@ -15,7 +15,7 @@ import './chunks/rpc.DFRWVnRh.js';
|
|
|
15
15
|
import 'pathe';
|
|
16
16
|
import 'vite/module-runner';
|
|
17
17
|
import './chunks/index.Chj8NDwU.js';
|
|
18
|
-
import './chunks/index.
|
|
18
|
+
import './chunks/index.CE58PZNH.js';
|
|
19
19
|
import '@vitest/runner';
|
|
20
20
|
import '@vitest/utils/helpers';
|
|
21
21
|
import '@vitest/utils/offset';
|
|
@@ -26,6 +26,7 @@ import '@vitest/utils/error';
|
|
|
26
26
|
import '@vitest/utils/diff';
|
|
27
27
|
import '@vitest/utils/display';
|
|
28
28
|
import 'tinyrainbow';
|
|
29
|
+
import 'tinybench';
|
|
29
30
|
import 'expect-type';
|
|
30
31
|
import './chunks/nativeModuleRunner.BOeMnHl4.js';
|
|
31
32
|
import 'node:url';
|
|
@@ -38,7 +39,7 @@ import 'node:assert';
|
|
|
38
39
|
import 'node:v8';
|
|
39
40
|
import 'node:util';
|
|
40
41
|
import './traces.js';
|
|
41
|
-
import './chunks/index.
|
|
42
|
+
import './chunks/index.nQFVd50u.js';
|
|
42
43
|
import './chunks/modules.BJuCwlRJ.js';
|
|
43
44
|
import './path.js';
|
|
44
45
|
import './module-evaluator.js';
|
package/dist/workers/forks.js
CHANGED
|
@@ -1,11 +1,11 @@
|
|
|
1
|
-
import { r as runBaseTests, s as setupBaseEnvironment } from '../chunks/base.
|
|
2
|
-
import { w as workerInit } from '../chunks/init-forks.
|
|
1
|
+
import { r as runBaseTests, s as setupBaseEnvironment } from '../chunks/base.BEGVMQrS.js';
|
|
2
|
+
import { w as workerInit } from '../chunks/init-forks.Ce3vGWgL.js';
|
|
3
3
|
import 'node:vm';
|
|
4
4
|
import '@vitest/spy';
|
|
5
|
-
import '../chunks/index.
|
|
5
|
+
import '../chunks/index.CcluKS59.js';
|
|
6
6
|
import 'chai';
|
|
7
7
|
import 'node:async_hooks';
|
|
8
|
-
import '../chunks/setup-common.
|
|
8
|
+
import '../chunks/setup-common.DdEF_hkE.js';
|
|
9
9
|
import '../chunks/coverage.CTzCuANN.js';
|
|
10
10
|
import '@vitest/utils/timers';
|
|
11
11
|
import '../chunks/utils.BX5Fg8C4.js';
|
|
@@ -15,7 +15,7 @@ import '../chunks/rpc.DFRWVnRh.js';
|
|
|
15
15
|
import 'pathe';
|
|
16
16
|
import 'vite/module-runner';
|
|
17
17
|
import '../chunks/index.Chj8NDwU.js';
|
|
18
|
-
import '../chunks/index.
|
|
18
|
+
import '../chunks/index.CE58PZNH.js';
|
|
19
19
|
import '@vitest/runner';
|
|
20
20
|
import '@vitest/utils/helpers';
|
|
21
21
|
import '@vitest/utils/offset';
|
|
@@ -26,12 +26,13 @@ import '@vitest/utils/error';
|
|
|
26
26
|
import '@vitest/utils/diff';
|
|
27
27
|
import '@vitest/utils/display';
|
|
28
28
|
import 'tinyrainbow';
|
|
29
|
+
import 'tinybench';
|
|
29
30
|
import 'expect-type';
|
|
30
|
-
import '../chunks/init.
|
|
31
|
+
import '../chunks/init.6qx-LaHs.js';
|
|
31
32
|
import 'node:fs';
|
|
32
33
|
import 'node:module';
|
|
33
34
|
import 'node:url';
|
|
34
|
-
import '../chunks/index.
|
|
35
|
+
import '../chunks/index.nQFVd50u.js';
|
|
35
36
|
import '../chunks/modules.BJuCwlRJ.js';
|
|
36
37
|
import '../path.js';
|
|
37
38
|
import 'node:path';
|
|
@@ -5,9 +5,9 @@ import timersPromises from 'node:timers/promises';
|
|
|
5
5
|
import util from 'node:util';
|
|
6
6
|
import { startTests, collectTests } from '@vitest/runner';
|
|
7
7
|
import { KNOWN_ASSET_TYPES } from '@vitest/utils/constants';
|
|
8
|
-
import { s as setupChaiConfig, r as resolveTestRunner, a as resolveSnapshotEnvironment, d as detectAsyncLeaks } from '../chunks/index.
|
|
9
|
-
import { s as setupCommonEnv, b as startCoverageInsideWorker, c as stopCoverageInsideWorker } from '../chunks/setup-common.
|
|
10
|
-
import { i as index, g as globalExpect } from '../chunks/index.
|
|
8
|
+
import { s as setupChaiConfig, r as resolveTestRunner, a as resolveSnapshotEnvironment, d as detectAsyncLeaks } from '../chunks/index.CcluKS59.js';
|
|
9
|
+
import { s as setupCommonEnv, b as startCoverageInsideWorker, c as stopCoverageInsideWorker } from '../chunks/setup-common.DdEF_hkE.js';
|
|
10
|
+
import { i as index, g as globalExpect } from '../chunks/index.CE58PZNH.js';
|
|
11
11
|
import { c as closeInspector } from '../chunks/inspector.CvyFGlXm.js';
|
|
12
12
|
import { g as getWorkerState } from '../chunks/utils.BX5Fg8C4.js';
|
|
13
13
|
import 'chai';
|
|
@@ -30,6 +30,7 @@ import '@vitest/utils/error';
|
|
|
30
30
|
import '@vitest/utils/diff';
|
|
31
31
|
import '@vitest/utils/display';
|
|
32
32
|
import 'tinyrainbow';
|
|
33
|
+
import 'tinybench';
|
|
33
34
|
import 'expect-type';
|
|
34
35
|
import 'node:url';
|
|
35
36
|
|