vitest 2.1.0-beta.7 → 2.1.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.
- package/dist/browser.js +1 -1
- package/dist/chunks/{base.CchlWrnV.js → base.CsQmmYBA.js} +1 -1
- package/dist/chunks/{cac.B5XYKv2_.js → cac.BVmpoFAv.js} +4 -4
- package/dist/chunks/{cli-api.ByZPnilx.js → cli-api.BKkmK21J.js} +32 -25
- package/dist/chunks/{creator.zfBZSJzo.js → creator.BteLTfY8.js} +3 -3
- package/dist/chunks/{globals.jM7MxN2t.js → globals.C03P0O1a.js} +2 -2
- package/dist/chunks/{index.CSjyR2-v.js → index.DkN6V87F.js} +1 -1
- package/dist/chunks/{index.xm8OIiKD.js → index.iyKRMe3s.js} +1 -1
- package/dist/chunks/{index.DpJO1tkB.js → index.zPibhCkV.js} +3 -1
- package/dist/chunks/{runBaseTests.Cztfoflv.js → runBaseTests.9YDrdSI4.js} +4 -4
- package/dist/chunks/{setup-common.fGBFoQKJ.js → setup-common.DV1PI68g.js} +1 -1
- package/dist/chunks/{vi.DGgiNzJE.js → vi.D6IHiKAI.js} +3 -9
- package/dist/cli.js +1 -1
- package/dist/index.js +3 -3
- package/dist/node.js +4 -4
- package/dist/reporters.js +1 -1
- package/dist/runners.js +1 -1
- package/dist/workers/forks.js +1 -1
- package/dist/workers/runVmTests.js +4 -4
- package/dist/workers/threads.js +1 -1
- package/dist/workers.js +1 -1
- package/package.json +11 -11
package/dist/browser.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
export { collectTests, processError, startTests } from '@vitest/runner';
|
|
2
|
-
export { l as loadDiffConfig, a as loadSnapshotSerializers, s as setupCommonEnv } from './chunks/setup-common.
|
|
2
|
+
export { l as loadDiffConfig, a as loadSnapshotSerializers, s as setupCommonEnv } from './chunks/setup-common.DV1PI68g.js';
|
|
3
3
|
export { g as getCoverageProvider, a as startCoverageInsideWorker, s as stopCoverageInsideWorker, t as takeCoverageInsideWorker } from './chunks/coverage.zlNdAMHK.js';
|
|
4
4
|
export { s as SpyModule } from './chunks/spy.Cf_4R5Oe.js';
|
|
5
5
|
import '@vitest/utils';
|
|
@@ -24,7 +24,7 @@ async function runBaseTests(method, state) {
|
|
|
24
24
|
ctx.files.forEach((i) => state.moduleCache.delete(i));
|
|
25
25
|
const [executor, { run }] = await Promise.all([
|
|
26
26
|
startViteNode({ state, requestStubs: getDefaultRequestStubs() }),
|
|
27
|
-
import('./runBaseTests.
|
|
27
|
+
import('./runBaseTests.9YDrdSI4.js')
|
|
28
28
|
]);
|
|
29
29
|
await run(
|
|
30
30
|
method,
|
|
@@ -618,7 +618,7 @@ class CAC extends EventEmitter {
|
|
|
618
618
|
|
|
619
619
|
const cac = (name = "") => new CAC(name);
|
|
620
620
|
|
|
621
|
-
var version = "2.1.
|
|
621
|
+
var version = "2.1.1";
|
|
622
622
|
|
|
623
623
|
const apiConfig = (port) => ({
|
|
624
624
|
port: {
|
|
@@ -1501,7 +1501,7 @@ async function start(mode, cliFilters, options) {
|
|
|
1501
1501
|
} catch {
|
|
1502
1502
|
}
|
|
1503
1503
|
try {
|
|
1504
|
-
const { startVitest } = await import('./cli-api.
|
|
1504
|
+
const { startVitest } = await import('./cli-api.BKkmK21J.js').then(function (n) { return n.d; });
|
|
1505
1505
|
const ctx = await startVitest(mode, cliFilters.map(normalize), normalizeCliOptions(options));
|
|
1506
1506
|
if (!ctx?.shouldKeepServer()) {
|
|
1507
1507
|
await ctx?.exit();
|
|
@@ -1523,7 +1523,7 @@ async function init(project) {
|
|
|
1523
1523
|
console.error(new Error('Only the "browser" project is supported. Use "vitest init browser" to create a new project.'));
|
|
1524
1524
|
process.exit(1);
|
|
1525
1525
|
}
|
|
1526
|
-
const { create } = await import('./creator.
|
|
1526
|
+
const { create } = await import('./creator.BteLTfY8.js');
|
|
1527
1527
|
await create();
|
|
1528
1528
|
}
|
|
1529
1529
|
async function collect(mode, cliFilters, options) {
|
|
@@ -1532,7 +1532,7 @@ async function collect(mode, cliFilters, options) {
|
|
|
1532
1532
|
} catch {
|
|
1533
1533
|
}
|
|
1534
1534
|
try {
|
|
1535
|
-
const { prepareVitest, processCollected, outputFileList } = await import('./cli-api.
|
|
1535
|
+
const { prepareVitest, processCollected, outputFileList } = await import('./cli-api.BKkmK21J.js').then(function (n) { return n.d; });
|
|
1536
1536
|
const ctx = await prepareVitest(mode, {
|
|
1537
1537
|
...normalizeCliOptions(options),
|
|
1538
1538
|
watch: false,
|
|
@@ -8,13 +8,13 @@ import { V as VitestCache, d as configDefaults, m as mm, b as resolveConfig, i a
|
|
|
8
8
|
import { ViteNodeRunner } from 'vite-node/client';
|
|
9
9
|
import { SnapshotManager } from '@vitest/snapshot/manager';
|
|
10
10
|
import { ViteNodeServer } from 'vite-node/server';
|
|
11
|
-
import { v as version$1 } from './cac.
|
|
11
|
+
import { v as version$1 } from './cac.BVmpoFAv.js';
|
|
12
12
|
import { createFileTask, getTasks, hasFailed, getTests, getNames } from '@vitest/runner/utils';
|
|
13
13
|
import { n as noop, b as isPrimitive, t as toArray, d as deepMerge, c as nanoid, w as wildcardPatternToRegExp, a as slash, e as stdout } from './base.BlXpj3e_.js';
|
|
14
14
|
import { toArray as toArray$1, notNullish, createDefer } from '@vitest/utils';
|
|
15
15
|
import { i as isWindows } from './env.CmHVDJnw.js';
|
|
16
16
|
import { c as createBirpc } from './index.BpSiYbpB.js';
|
|
17
|
-
import { s as stringify, p as parse$5, R as ReportersMap, h as BenchmarkReportsMap, f as TestModule, g as TestSuite, e as TestCase, j as generateCodeFrame, i as TestProject, L as Logger, k as BlobReporter, r as readBlobs } from './index.
|
|
17
|
+
import { s as stringify, p as parse$5, R as ReportersMap, h as BenchmarkReportsMap, f as TestModule, g as TestSuite, e as TestCase, j as generateCodeFrame, i as TestProject, L as Logger, k as BlobReporter, r as readBlobs } from './index.zPibhCkV.js';
|
|
18
18
|
import require$$0$2 from 'stream';
|
|
19
19
|
import require$$0 from 'zlib';
|
|
20
20
|
import require$$0$1 from 'buffer';
|
|
@@ -9688,8 +9688,9 @@ async function resolveWorkspace(vitest, cliOptions, workspaceConfigPath, workspa
|
|
|
9688
9688
|
}, {});
|
|
9689
9689
|
const cwd = process.cwd();
|
|
9690
9690
|
const projects = [];
|
|
9691
|
+
const fileProjects = [...configFiles, ...nonConfigDirectories];
|
|
9691
9692
|
try {
|
|
9692
|
-
for (const filepath of
|
|
9693
|
+
for (const filepath of fileProjects) {
|
|
9693
9694
|
if (vitest.server.config.configFile === filepath) {
|
|
9694
9695
|
const project = await vitest._createCoreProject();
|
|
9695
9696
|
projects.push(project);
|
|
@@ -9732,12 +9733,18 @@ async function resolveWorkspace(vitest, cliOptions, workspaceConfigPath, workspa
|
|
|
9732
9733
|
const name = project.getName();
|
|
9733
9734
|
if (names.has(name)) {
|
|
9734
9735
|
const duplicate = resolvedProjects.find((p) => p.getName() === name && p !== project);
|
|
9736
|
+
const filesError = fileProjects.length ? [
|
|
9737
|
+
"\n\nYour config matched these files:\n",
|
|
9738
|
+
fileProjects.map((p) => ` - ${relative(vitest.config.root, p)}`).join("\n"),
|
|
9739
|
+
"\n\n"
|
|
9740
|
+
].join("") : [" "];
|
|
9735
9741
|
throw new Error([
|
|
9736
9742
|
`Project name "${name}"`,
|
|
9737
9743
|
project.server.config.configFile ? ` from "${relative(vitest.config.root, project.server.config.configFile)}"` : "",
|
|
9738
9744
|
" is not unique.",
|
|
9739
9745
|
duplicate?.server.config.configFile ? ` The project is already defined by "${relative(vitest.config.root, duplicate.server.config.configFile)}".` : "",
|
|
9740
|
-
|
|
9746
|
+
filesError,
|
|
9747
|
+
"All projects in a workspace should have unique names. Make sure your configuration is correct."
|
|
9741
9748
|
].join(""));
|
|
9742
9749
|
}
|
|
9743
9750
|
names.add(name);
|
|
@@ -9785,29 +9792,29 @@ async function resolveWorkspaceProjectConfigs(vitest, workspaceConfigPath, works
|
|
|
9785
9792
|
} else {
|
|
9786
9793
|
projectsOptions.push(await definition);
|
|
9787
9794
|
}
|
|
9788
|
-
|
|
9789
|
-
|
|
9790
|
-
|
|
9791
|
-
|
|
9792
|
-
|
|
9793
|
-
|
|
9794
|
-
|
|
9795
|
-
|
|
9796
|
-
|
|
9797
|
-
|
|
9798
|
-
|
|
9799
|
-
|
|
9800
|
-
|
|
9801
|
-
|
|
9802
|
-
|
|
9803
|
-
|
|
9804
|
-
nonConfigProjectDirectories.push(filepath);
|
|
9805
|
-
}
|
|
9795
|
+
}
|
|
9796
|
+
if (workspaceGlobMatches.length) {
|
|
9797
|
+
const globOptions = {
|
|
9798
|
+
absolute: true,
|
|
9799
|
+
dot: true,
|
|
9800
|
+
onlyFiles: false,
|
|
9801
|
+
cwd: vitest.config.root,
|
|
9802
|
+
expandDirectories: false,
|
|
9803
|
+
ignore: ["**/node_modules/**", "**/*.timestamp-*"]
|
|
9804
|
+
};
|
|
9805
|
+
const workspacesFs = await glob(workspaceGlobMatches, globOptions);
|
|
9806
|
+
await Promise.all(workspacesFs.map(async (filepath) => {
|
|
9807
|
+
if (filepath.endsWith("/")) {
|
|
9808
|
+
const configFile = await resolveDirectoryConfig(filepath);
|
|
9809
|
+
if (configFile) {
|
|
9810
|
+
workspaceConfigFiles.push(configFile);
|
|
9806
9811
|
} else {
|
|
9807
|
-
|
|
9812
|
+
nonConfigProjectDirectories.push(filepath);
|
|
9808
9813
|
}
|
|
9809
|
-
}
|
|
9810
|
-
|
|
9814
|
+
} else {
|
|
9815
|
+
workspaceConfigFiles.push(filepath);
|
|
9816
|
+
}
|
|
9817
|
+
}));
|
|
9811
9818
|
}
|
|
9812
9819
|
const projectConfigFiles = Array.from(new Set(workspaceConfigFiles));
|
|
9813
9820
|
return {
|
|
@@ -40,7 +40,7 @@ import { expect, test } from 'vitest'
|
|
|
40
40
|
import { render } from '@testing-library/jsx'
|
|
41
41
|
import HelloWorld from './HelloWorld.jsx'
|
|
42
42
|
|
|
43
|
-
test('renders name', () => {
|
|
43
|
+
test('renders name', async () => {
|
|
44
44
|
const { getByText } = render(<HelloWorld name="Vitest" />)
|
|
45
45
|
await expect.element(getByText('Hello Vitest!')).toBeInTheDocument()
|
|
46
46
|
})
|
|
@@ -79,7 +79,7 @@ import { expect, test } from 'vitest'
|
|
|
79
79
|
import { render } from 'vitest-browser-vue'
|
|
80
80
|
import HelloWorld from './HelloWorld.vue'
|
|
81
81
|
|
|
82
|
-
test('renders name', () => {
|
|
82
|
+
test('renders name', async () => {
|
|
83
83
|
const { getByText } = render(HelloWorld, {
|
|
84
84
|
props: { name: 'Vitest' },
|
|
85
85
|
})
|
|
@@ -108,7 +108,7 @@ import { expect, test } from 'vitest'
|
|
|
108
108
|
import { render } from 'vitest-browser-svelte'
|
|
109
109
|
import HelloWorld from './HelloWorld.svelte'
|
|
110
110
|
|
|
111
|
-
test('renders name', () => {
|
|
111
|
+
test('renders name', async () => {
|
|
112
112
|
const { getByText } = render(HelloWorld, { name: 'Vitest' })
|
|
113
113
|
await expect.element(getByText('Hello Vitest!')).toBeInTheDocument()
|
|
114
114
|
})
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { g as globalApis } from './constants.fzPh7AOq.js';
|
|
2
|
-
import { V as VitestIndex } from './index.
|
|
2
|
+
import { V as VitestIndex } from './index.iyKRMe3s.js';
|
|
3
3
|
import '@vitest/runner';
|
|
4
4
|
import './benchmark.C8CRJYG4.js';
|
|
5
5
|
import '@vitest/runner/utils';
|
|
@@ -10,7 +10,7 @@ import './utils.Ck2hJTRs.js';
|
|
|
10
10
|
import './env.CmHVDJnw.js';
|
|
11
11
|
import 'std-env';
|
|
12
12
|
import './run-once.Sxe67Wng.js';
|
|
13
|
-
import './vi.
|
|
13
|
+
import './vi.D6IHiKAI.js';
|
|
14
14
|
import 'chai';
|
|
15
15
|
import './_commonjsHelpers.BFTU3MAI.js';
|
|
16
16
|
import '@vitest/expect';
|
|
@@ -4,7 +4,7 @@ import { distDir } from '../path.js';
|
|
|
4
4
|
import { g as getWorkerState } from './utils.Ck2hJTRs.js';
|
|
5
5
|
import { r as rpc } from './rpc.B7Mfb-Yf.js';
|
|
6
6
|
import { t as takeCoverageInsideWorker } from './coverage.zlNdAMHK.js';
|
|
7
|
-
import { l as loadDiffConfig, a as loadSnapshotSerializers } from './setup-common.
|
|
7
|
+
import { l as loadDiffConfig, a as loadSnapshotSerializers } from './setup-common.DV1PI68g.js';
|
|
8
8
|
|
|
9
9
|
function setupChaiConfig(config) {
|
|
10
10
|
Object.assign(chai.config, config);
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { afterAll, afterEach, beforeAll, beforeEach, describe, it, onTestFailed, onTestFinished, suite, test } from '@vitest/runner';
|
|
2
2
|
import { b as bench } from './benchmark.C8CRJYG4.js';
|
|
3
3
|
import { i as isFirstRun, a as runOnce } from './run-once.Sxe67Wng.js';
|
|
4
|
-
import { c as createExpect, a as globalExpect, v as vi, b as vitest } from './vi.
|
|
4
|
+
import { c as createExpect, a as globalExpect, v as vi, b as vitest } from './vi.D6IHiKAI.js';
|
|
5
5
|
import { g as getWorkerState } from './utils.Ck2hJTRs.js';
|
|
6
6
|
import * as chai from 'chai';
|
|
7
7
|
import { assert, should } from 'chai';
|
|
@@ -3980,10 +3980,12 @@ No ${config.mode} files found, exiting with code 1`)
|
|
|
3980
3980
|
const output = project.isCore() ? "" : ` [${name}]`;
|
|
3981
3981
|
const resolvedUrls = project.browser.vite.resolvedUrls;
|
|
3982
3982
|
const origin = resolvedUrls?.local[0] ?? resolvedUrls?.network[0];
|
|
3983
|
+
const provider = project.browser.provider.name;
|
|
3984
|
+
const providerString = provider === "preview" ? "" : ` by ${provider}`;
|
|
3983
3985
|
this.log(
|
|
3984
3986
|
c.dim(
|
|
3985
3987
|
c.green(
|
|
3986
|
-
` ${output} Browser runner started at ${new URL("/", origin)}`
|
|
3988
|
+
` ${output} Browser runner started${providerString} at ${new URL("/", origin)}`
|
|
3987
3989
|
)
|
|
3988
3990
|
)
|
|
3989
3991
|
);
|
|
@@ -5,16 +5,16 @@ import '@vitest/runner/utils';
|
|
|
5
5
|
import { getSafeTimers } from '@vitest/utils';
|
|
6
6
|
import { g as getWorkerState } from './utils.Ck2hJTRs.js';
|
|
7
7
|
import './env.CmHVDJnw.js';
|
|
8
|
-
import { a as globalExpect, r as resetModules, v as vi } from './vi.
|
|
8
|
+
import { a as globalExpect, r as resetModules, v as vi } from './vi.D6IHiKAI.js';
|
|
9
9
|
import { a as startCoverageInsideWorker, s as stopCoverageInsideWorker } from './coverage.zlNdAMHK.js';
|
|
10
|
-
import { a as resolveSnapshotEnvironment, s as setupChaiConfig, r as resolveTestRunner } from './index.
|
|
10
|
+
import { a as resolveSnapshotEnvironment, s as setupChaiConfig, r as resolveTestRunner } from './index.DkN6V87F.js';
|
|
11
11
|
import { createRequire } from 'node:module';
|
|
12
12
|
import util from 'node:util';
|
|
13
13
|
import timers from 'node:timers';
|
|
14
14
|
import { installSourcemapsSupport } from 'vite-node/source-map';
|
|
15
15
|
import { KNOWN_ASSET_TYPES } from 'vite-node/constants';
|
|
16
|
-
import { V as VitestIndex } from './index.
|
|
17
|
-
import { s as setupCommonEnv } from './setup-common.
|
|
16
|
+
import { V as VitestIndex } from './index.iyKRMe3s.js';
|
|
17
|
+
import { s as setupCommonEnv } from './setup-common.DV1PI68g.js';
|
|
18
18
|
import { c as closeInspector } from './inspector.70d6emsh.js';
|
|
19
19
|
import 'std-env';
|
|
20
20
|
import 'chai';
|
|
@@ -13,7 +13,7 @@ async function setupCommonEnv(config) {
|
|
|
13
13
|
globalSetup = true;
|
|
14
14
|
setSafeTimers();
|
|
15
15
|
if (config.globals) {
|
|
16
|
-
(await import('./globals.
|
|
16
|
+
(await import('./globals.C03P0O1a.js')).registerApiGlobally();
|
|
17
17
|
}
|
|
18
18
|
}
|
|
19
19
|
function setupDefines(defines) {
|
|
@@ -463,7 +463,6 @@ function createExpect(test) {
|
|
|
463
463
|
expect.getState = () => getState(expect);
|
|
464
464
|
expect.setState = (state) => setState(state, expect);
|
|
465
465
|
const globalState = getState(globalThis[GLOBAL_EXPECT]) || {};
|
|
466
|
-
const testPath = getTestFile(test);
|
|
467
466
|
setState(
|
|
468
467
|
{
|
|
469
468
|
// this should also add "snapshotState" that is added conditionally
|
|
@@ -474,7 +473,9 @@ function createExpect(test) {
|
|
|
474
473
|
expectedAssertionsNumber: null,
|
|
475
474
|
expectedAssertionsNumberErrorGen: null,
|
|
476
475
|
environment: getCurrentEnvironment(),
|
|
477
|
-
testPath
|
|
476
|
+
get testPath() {
|
|
477
|
+
return getWorkerState().filepath;
|
|
478
|
+
},
|
|
478
479
|
currentTestName: test ? getTestName(test) : globalState.currentTestName
|
|
479
480
|
},
|
|
480
481
|
expect
|
|
@@ -516,13 +517,6 @@ function createExpect(test) {
|
|
|
516
517
|
chai$1.util.addMethod(expect, "hasAssertions", hasAssertions);
|
|
517
518
|
return expect;
|
|
518
519
|
}
|
|
519
|
-
function getTestFile(test) {
|
|
520
|
-
if (test) {
|
|
521
|
-
return test.file.filepath;
|
|
522
|
-
}
|
|
523
|
-
const state = getWorkerState();
|
|
524
|
-
return state.filepath;
|
|
525
|
-
}
|
|
526
520
|
const globalExpect = createExpect();
|
|
527
521
|
Object.defineProperty(globalThis, GLOBAL_EXPECT, {
|
|
528
522
|
value: globalExpect,
|
package/dist/cli.js
CHANGED
package/dist/index.js
CHANGED
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
export { afterAll, afterEach, beforeAll, beforeEach, describe, it, onTestFailed, onTestFinished, suite, test } from '@vitest/runner';
|
|
2
2
|
export { b as bench } from './chunks/benchmark.C8CRJYG4.js';
|
|
3
|
-
import { d as dist } from './chunks/index.
|
|
4
|
-
export { a as assertType, g as getRunningMode, b as inject, i as isWatchMode } from './chunks/index.
|
|
3
|
+
import { d as dist } from './chunks/index.iyKRMe3s.js';
|
|
4
|
+
export { a as assertType, g as getRunningMode, b as inject, i as isWatchMode } from './chunks/index.iyKRMe3s.js';
|
|
5
5
|
export { i as isFirstRun, a as runOnce } from './chunks/run-once.Sxe67Wng.js';
|
|
6
|
-
export { c as createExpect, a as expect, v as vi, b as vitest } from './chunks/vi.
|
|
6
|
+
export { c as createExpect, a as expect, v as vi, b as vitest } from './chunks/vi.D6IHiKAI.js';
|
|
7
7
|
import * as chai from 'chai';
|
|
8
8
|
export { chai };
|
|
9
9
|
export { assert, should } from 'chai';
|
package/dist/node.js
CHANGED
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import { createServer as createServer$1 } from 'vite';
|
|
2
2
|
export { createLogger as createViteLogger, isFileServingAllowed, parseAst, parseAstAsync } from 'vite';
|
|
3
|
-
import { f as TestModule } from './chunks/index.
|
|
4
|
-
export { e as TestCase, i as TestProject, g as TestSuite } from './chunks/index.
|
|
5
|
-
export { G as GitNotFoundError, T as TestSpecification, F as TestsNotFoundError, a as VitestPackageInstaller, V as VitestPlugin, c as createVitest, r as registerConsoleShortcuts, b as resolveFsAllow, s as startVitest } from './chunks/cli-api.
|
|
6
|
-
export { p as parseCLI } from './chunks/cac.
|
|
3
|
+
import { f as TestModule } from './chunks/index.zPibhCkV.js';
|
|
4
|
+
export { e as TestCase, i as TestProject, g as TestSuite } from './chunks/index.zPibhCkV.js';
|
|
5
|
+
export { G as GitNotFoundError, T as TestSpecification, F as TestsNotFoundError, a as VitestPackageInstaller, V as VitestPlugin, c as createVitest, r as registerConsoleShortcuts, b as resolveFsAllow, s as startVitest } from './chunks/cli-api.BKkmK21J.js';
|
|
6
|
+
export { p as parseCLI } from './chunks/cac.BVmpoFAv.js';
|
|
7
7
|
export { c as createMethodsRPC, g as getFilePoolName, a as resolveApiServerConfig, b as resolveConfig } from './chunks/resolveConfig.-K5hHm0S.js';
|
|
8
8
|
import createDebug from 'debug';
|
|
9
9
|
export { distDir, rootDir } from './path.js';
|
package/dist/reporters.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
export { B as BasicReporter, h as BenchmarkReportsMap, D as DefaultReporter, a as DotReporter, G as GithubActionsReporter, H as HangingProcessReporter, b as JUnitReporter, J as JsonReporter, R as ReportersMap, c as TapFlatReporter, T as TapReporter, e as TestCase, d as TestFile, f as TestModule, g as TestSuite, V as VerboseReporter } from './chunks/index.
|
|
1
|
+
export { B as BasicReporter, h as BenchmarkReportsMap, D as DefaultReporter, a as DotReporter, G as GithubActionsReporter, H as HangingProcessReporter, b as JUnitReporter, J as JsonReporter, R as ReportersMap, c as TapFlatReporter, T as TapReporter, e as TestCase, d as TestFile, f as TestModule, g as TestSuite, V as VerboseReporter } from './chunks/index.zPibhCkV.js';
|
|
2
2
|
import 'node:fs';
|
|
3
3
|
import 'tinyrainbow';
|
|
4
4
|
import 'pathe';
|
package/dist/runners.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { setState, GLOBAL_EXPECT, getState } from '@vitest/expect';
|
|
2
|
-
import { g as getSnapshotClient, c as createExpect, v as vi } from './chunks/vi.
|
|
2
|
+
import { g as getSnapshotClient, c as createExpect, v as vi } from './chunks/vi.D6IHiKAI.js';
|
|
3
3
|
import 'pathe';
|
|
4
4
|
import { g as getTestName } from './chunks/tasks.BZnCS9aT.js';
|
|
5
5
|
import { createDefer, getSafeTimers } from '@vitest/utils';
|
package/dist/workers/forks.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import v8 from 'node:v8';
|
|
2
2
|
import { c as createForksRpcOptions, u as unwrapSerializableConfig } from '../chunks/utils.Cn0zI1t3.js';
|
|
3
|
-
import { r as runBaseTests } from '../chunks/base.
|
|
3
|
+
import { r as runBaseTests } from '../chunks/base.CsQmmYBA.js';
|
|
4
4
|
import '@vitest/utils';
|
|
5
5
|
import 'vite-node/client';
|
|
6
6
|
import '../chunks/utils.Ck2hJTRs.js';
|
|
@@ -5,11 +5,11 @@ import { performance } from 'node:perf_hooks';
|
|
|
5
5
|
import { startTests, collectTests } from '@vitest/runner';
|
|
6
6
|
import { installSourcemapsSupport } from 'vite-node/source-map';
|
|
7
7
|
import { KNOWN_ASSET_TYPES } from 'vite-node/constants';
|
|
8
|
-
import { s as setupChaiConfig, r as resolveTestRunner, a as resolveSnapshotEnvironment } from '../chunks/index.
|
|
8
|
+
import { s as setupChaiConfig, r as resolveTestRunner, a as resolveSnapshotEnvironment } from '../chunks/index.DkN6V87F.js';
|
|
9
9
|
import { a as startCoverageInsideWorker, s as stopCoverageInsideWorker } from '../chunks/coverage.zlNdAMHK.js';
|
|
10
|
-
import { V as VitestIndex } from '../chunks/index.
|
|
10
|
+
import { V as VitestIndex } from '../chunks/index.iyKRMe3s.js';
|
|
11
11
|
import { g as getWorkerState } from '../chunks/utils.Ck2hJTRs.js';
|
|
12
|
-
import { s as setupCommonEnv } from '../chunks/setup-common.
|
|
12
|
+
import { s as setupCommonEnv } from '../chunks/setup-common.DV1PI68g.js';
|
|
13
13
|
import { c as closeInspector } from '../chunks/inspector.70d6emsh.js';
|
|
14
14
|
import 'chai';
|
|
15
15
|
import 'pathe';
|
|
@@ -24,7 +24,7 @@ import '../chunks/index.CxRxs566.js';
|
|
|
24
24
|
import '../chunks/env.CmHVDJnw.js';
|
|
25
25
|
import 'std-env';
|
|
26
26
|
import '../chunks/run-once.Sxe67Wng.js';
|
|
27
|
-
import '../chunks/vi.
|
|
27
|
+
import '../chunks/vi.D6IHiKAI.js';
|
|
28
28
|
import '../chunks/_commonjsHelpers.BFTU3MAI.js';
|
|
29
29
|
import '@vitest/expect';
|
|
30
30
|
import '@vitest/snapshot';
|
package/dist/workers/threads.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { r as runBaseTests } from '../chunks/base.
|
|
1
|
+
import { r as runBaseTests } from '../chunks/base.CsQmmYBA.js';
|
|
2
2
|
import { a as createThreadsRpcOptions } from '../chunks/utils.Cn0zI1t3.js';
|
|
3
3
|
import 'vite-node/client';
|
|
4
4
|
import '../chunks/utils.Ck2hJTRs.js';
|
package/dist/workers.js
CHANGED
|
@@ -2,7 +2,7 @@ export { c as createForksRpcOptions, a as createThreadsRpcOptions, u as unwrapSe
|
|
|
2
2
|
export { p as provideWorkerState } from './chunks/utils.Ck2hJTRs.js';
|
|
3
3
|
export { collect as collectVitestWorkerTests, run as runVitestWorker } from './worker.js';
|
|
4
4
|
export { r as runVmTests } from './chunks/vm.CPXwWp4C.js';
|
|
5
|
-
export { r as runBaseTests } from './chunks/base.
|
|
5
|
+
export { r as runBaseTests } from './chunks/base.CsQmmYBA.js';
|
|
6
6
|
import '@vitest/utils';
|
|
7
7
|
import 'node:url';
|
|
8
8
|
import 'tinypool';
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "vitest",
|
|
3
3
|
"type": "module",
|
|
4
|
-
"version": "2.1.
|
|
4
|
+
"version": "2.1.1",
|
|
5
5
|
"description": "Next generation testing framework powered by Vite",
|
|
6
6
|
"author": "Anthony Fu <anthonyfu117@hotmail.com>",
|
|
7
7
|
"license": "MIT",
|
|
@@ -122,8 +122,8 @@
|
|
|
122
122
|
"@types/node": "^18.0.0 || >=20.0.0",
|
|
123
123
|
"happy-dom": "*",
|
|
124
124
|
"jsdom": "*",
|
|
125
|
-
"@vitest/
|
|
126
|
-
"@vitest/
|
|
125
|
+
"@vitest/browser": "2.1.1",
|
|
126
|
+
"@vitest/ui": "2.1.1"
|
|
127
127
|
},
|
|
128
128
|
"peerDependenciesMeta": {
|
|
129
129
|
"@edge-runtime/vm": {
|
|
@@ -157,14 +157,14 @@
|
|
|
157
157
|
"tinyrainbow": "^1.2.0",
|
|
158
158
|
"vite": "^5.0.0",
|
|
159
159
|
"why-is-node-running": "^2.3.0",
|
|
160
|
-
"@vitest/
|
|
161
|
-
"@vitest/
|
|
162
|
-
"@vitest/
|
|
163
|
-
"@vitest/
|
|
164
|
-
"@vitest/spy": "2.1.
|
|
165
|
-
"
|
|
166
|
-
"@vitest/
|
|
167
|
-
"
|
|
160
|
+
"@vitest/mocker": "2.1.1",
|
|
161
|
+
"@vitest/runner": "2.1.1",
|
|
162
|
+
"@vitest/snapshot": "2.1.1",
|
|
163
|
+
"@vitest/pretty-format": "^2.1.1",
|
|
164
|
+
"@vitest/spy": "2.1.1",
|
|
165
|
+
"vite-node": "2.1.1",
|
|
166
|
+
"@vitest/utils": "2.1.1",
|
|
167
|
+
"@vitest/expect": "2.1.1"
|
|
168
168
|
},
|
|
169
169
|
"devDependencies": {
|
|
170
170
|
"@ampproject/remapping": "^2.3.0",
|