vitest 0.0.112 → 0.0.113

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/index.d.ts CHANGED
@@ -2,6 +2,7 @@ import { Formatter } from 'picocolors/types';
2
2
  import { ViteDevServer } from 'vite';
3
3
  import { OptionsReceived } from 'pretty-format';
4
4
  import { MessagePort } from 'worker_threads';
5
+ import { RawSourceMap } from 'source-map-js';
5
6
  export { Spy, SpyFn } from 'tinyspy';
6
7
  export { assert, default as chai, should } from 'chai';
7
8
 
@@ -233,6 +234,7 @@ declare abstract class BaseReporter implements Reporter {
233
234
  onUserConsoleLog(log: UserConsoleLog): void;
234
235
  onServerRestart(): void;
235
236
  reportSummary(files: File[]): Promise<void>;
237
+ private printTaskErrors;
236
238
  }
237
239
 
238
240
  interface ListRendererOptions {
@@ -298,6 +300,16 @@ interface UserConsoleLog {
298
300
  type: 'stdout' | 'stderr';
299
301
  taskId?: string;
300
302
  }
303
+ interface Position {
304
+ line: number;
305
+ column: number;
306
+ }
307
+ interface ParsedStack {
308
+ method: string;
309
+ file: string;
310
+ line: number;
311
+ column: number;
312
+ }
301
313
 
302
314
  declare type ChainableFunction<T extends string, Args extends any[], R = any> = {
303
315
  (...args: Args): R;
@@ -608,6 +620,7 @@ interface WorkerContext {
608
620
  }
609
621
  interface RpcMap {
610
622
  fetch: [[id: string], string | undefined];
623
+ getSourceMap: [[id: string, force?: boolean], RawSourceMap | undefined];
611
624
  log: [[UserConsoleLog], void];
612
625
  processExit: [[code?: number], void];
613
626
  onCollected: [[files: File[]], void];
@@ -623,9 +636,9 @@ declare type RpcPayload<T extends keyof RpcMap = keyof RpcMap> = {
623
636
  args: RpcMap[T][0];
624
637
  };
625
638
 
626
- declare const suite: ChainableFunction<"skip" | "only" | "todo" | "concurrent", [name: string, factory?: TestFactory | undefined], SuiteCollector>;
639
+ declare const suite: ChainableFunction<"concurrent" | "skip" | "only" | "todo", [name: string, factory?: TestFactory | undefined], SuiteCollector>;
627
640
  declare const test: TestCollector;
628
- declare const describe: ChainableFunction<"skip" | "only" | "todo" | "concurrent", [name: string, factory?: TestFactory | undefined], SuiteCollector>;
641
+ declare const describe: ChainableFunction<"concurrent" | "skip" | "only" | "todo", [name: string, factory?: TestFactory | undefined], SuiteCollector>;
629
642
  declare const it: TestCollector;
630
643
 
631
644
  declare const beforeAll: (fn: SuiteHooks['beforeAll'][0], timeout?: number | undefined) => void;
@@ -866,4 +879,4 @@ declare global {
866
879
  }
867
880
  }
868
881
 
869
- export { ArgumentsOf, ArgumentsType, Arrayable, Awaitable, BuiltinEnvironment, ComputeMode, ConstructorArgumentsOf, DoneCallback, Environment, EnvironmentReturn, File, HookListener, InlineConfig, JestMockCompat, JestMockCompatContext, JestMockCompatFn, MaybeMocked, MaybeMockedConstructor, MaybeMockedDeep, MethodKeysOf, MockWithArgs, MockableFunction, MockedFunction, MockedFunctionDeep, MockedObject, MockedObjectDeep, ModuleCache, Nullable, PropertyKeysOf, Reporter, ResolvedConfig, RpcCall, RpcMap, RpcPayload, RpcSend, RunMode, RuntimeContext, SnapshotData, SnapshotMatchOptions, SnapshotResult, SnapshotStateOptions, SnapshotSummary, SnapshotUpdateState, Suite, SuiteCollector, SuiteHooks, Task, TaskBase, TaskResult, TaskResultPack, TaskState, Test, TestCollector, TestFactory, TestFunction, UncheckedSnapshot, UserConfig, UserConsoleLog, WorkerContext, afterAll, afterEach, beforeAll, beforeEach, describe, expect, fn, it, spies, spyOn, suite, test, vi, vitest };
882
+ export { ArgumentsOf, ArgumentsType, Arrayable, Awaitable, BuiltinEnvironment, ComputeMode, ConstructorArgumentsOf, DoneCallback, Environment, EnvironmentReturn, File, HookListener, InlineConfig, JestMockCompat, JestMockCompatContext, JestMockCompatFn, MaybeMocked, MaybeMockedConstructor, MaybeMockedDeep, MethodKeysOf, MockWithArgs, MockableFunction, MockedFunction, MockedFunctionDeep, MockedObject, MockedObjectDeep, ModuleCache, Nullable, ParsedStack, Position, PropertyKeysOf, Reporter, ResolvedConfig, RpcCall, RpcMap, RpcPayload, RpcSend, RunMode, RuntimeContext, SnapshotData, SnapshotMatchOptions, SnapshotResult, SnapshotStateOptions, SnapshotSummary, SnapshotUpdateState, Suite, SuiteCollector, SuiteHooks, Task, TaskBase, TaskResult, TaskResultPack, TaskState, Test, TestCollector, TestFactory, TestFunction, UncheckedSnapshot, UserConfig, UserConsoleLog, WorkerContext, afterAll, afterEach, beforeAll, beforeEach, describe, expect, fn, it, spies, spyOn, suite, test, vi, vitest };
package/dist/index.js CHANGED
@@ -1,10 +1,9 @@
1
- export { d as describe, i as it, c as suite, t as test, e as vi, v as vitest } from './vi-cb9e4e4e.js';
2
- export { a as afterAll, d as afterEach, b as beforeAll, c as beforeEach, e as expect } from './index-2bb9fd4d.js';
1
+ export { d as describe, i as it, c as suite, t as test, e as vi, v as vitest } from './vi-51946984.js';
2
+ export { a as afterAll, d as afterEach, b as beforeAll, c as beforeEach, e as expect } from './index-09437c50.js';
3
3
  export { f as fn, s as spies, a as spyOn } from './jest-mock-a57b745c.js';
4
4
  export { assert, default as chai, should } from 'chai';
5
- import './utils-cb6b1266.js';
5
+ import './index-041e627e.js';
6
6
  import 'tty';
7
7
  import 'local-pkg';
8
- import 'path';
9
8
  import './_commonjsHelpers-c9e3b764.js';
10
9
  import 'tinyspy';