@systemfsoftware/stryker-js 5.0.0 → 6.0.0
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/CHANGELOG.md +56 -0
- package/README.md +144 -39
- package/dist/Plugins-DF95m9KO.d.mts +1400 -0
- package/dist/{builtin-reporters-wAuKFSsd.mjs → builtin-reporters-BqePgAN0.mjs} +3 -4
- package/dist/builtin-reporters.d.mts +299 -1
- package/dist/builtin-reporters.mjs +3 -2
- package/dist/compiler-C8aLIb5U.mjs +48406 -0
- package/dist/config.d.mts +2 -1
- package/dist/dist-CWbipfGB.mjs +711 -0
- package/dist/index-BInJWa0x.d.mts +1148 -0
- package/dist/index.d.mts +2538 -312
- package/dist/index.mjs +4 -3
- package/dist/main.mjs +499 -1893
- package/dist/{mutation-test.cell-RmF-sBUm.d.mts → mutation-test.cell-Cw1ZzDnb.d.mts} +70 -18
- package/dist/plugin-loader.d.mts +1577 -10
- package/dist/plugin-loader.mjs +3 -2
- package/dist/{plugin-worker-entry-DNu0SHO8.mjs → plugin-worker-entry-D00fedxV.mjs} +356 -184
- package/dist/promises.d.mts +2 -2
- package/dist/promises.mjs +1 -1
- package/dist/rolldown-runtime-XITHOX9H.mjs +15 -0
- package/dist/src-fju4cI5I.mjs +12466 -0
- package/dist/src-js-DRK8boNV.mjs +1009 -0
- package/dist/{stryker-config-BlfHxS7n.d.mts → stryker-config-DIGmQrm1.d.mts} +2 -2
- package/package.json +37 -15
- package/dist/Plugins-sA_9VKus.d.mts +0 -96
- package/dist/src-Bzh7ykDp.mjs +0 -4724
|
@@ -1,33 +1,31 @@
|
|
|
1
|
+
import { B as StrykerOptions, O as PartialStrykerOptions, P as ReporterFactory, R as ReporterRpcs, T as MutationTestResult, W as TestResult, at as FileDescription, bt as RunMutantResult, d as ExitClass, gt as MutateDescription, it as CoverageData, lt as Mutant, ot as FileDescriptions, r as CompleteDryRunResult } from "./index-BInJWa0x.mjs";
|
|
1
2
|
import { r as ResolvedMode } from "./output-mode-CfGHDpi5.mjs";
|
|
2
|
-
import {
|
|
3
|
-
import * as Effect from "effect/Effect";
|
|
3
|
+
import { b as Ignorer, o as LoadedPlugins } from "./Plugins-DF95m9KO.mjs";
|
|
4
|
+
import * as Effect$1 from "effect/Effect";
|
|
4
5
|
import * as FileSystem from "effect/FileSystem";
|
|
5
6
|
import * as Path from "effect/Path";
|
|
6
7
|
import * as Stdio from "effect/Stdio";
|
|
7
8
|
import { Cell } from "@systemfsoftware/effect-cell-types";
|
|
8
|
-
import
|
|
9
|
+
import * as S from "effect/Schema";
|
|
9
10
|
import * as Context from "effect/Context";
|
|
11
|
+
import * as Rpc from "effect/unstable/rpc/Rpc";
|
|
12
|
+
import * as RpcGroup from "effect/unstable/rpc/RpcGroup";
|
|
13
|
+
import { Schema } from "effect";
|
|
10
14
|
import * as Layer from "effect/Layer";
|
|
11
15
|
import * as Queue from "effect/Queue";
|
|
12
16
|
import "effect/Result";
|
|
13
|
-
import * as S from "effect/Schema";
|
|
14
|
-
import { CoverageData, FileDescription, FileDescriptions, Mutant, MutantStatus, MutateDescription, RunMutantResult } from "@systemfsoftware/stryker-js-instrumenter/mutants";
|
|
15
17
|
import * as Cause from "effect/Cause";
|
|
18
|
+
import { YieldableError } from "effect/Cause";
|
|
16
19
|
import * as Scope from "effect/Scope";
|
|
17
20
|
import * as Duration from "effect/Duration";
|
|
18
21
|
import * as MutableHashMap from "effect/MutableHashMap";
|
|
19
22
|
import * as MutableHashSet from "effect/MutableHashSet";
|
|
20
|
-
import { Schema } from "effect";
|
|
21
23
|
import * as ChildProcessSpawner from "effect/unstable/process/ChildProcessSpawner";
|
|
22
24
|
import * as RpcClient from "effect/unstable/rpc/RpcClient";
|
|
23
25
|
import * as Schedule from "effect/Schedule";
|
|
24
|
-
import "@systemfsoftware/stryker-js-instrumenter";
|
|
25
26
|
import { PlatformError } from "effect/PlatformError";
|
|
26
|
-
import * as Rpc from "effect/unstable/rpc/Rpc";
|
|
27
27
|
import { RpcClientError } from "effect/unstable/rpc/RpcClientError";
|
|
28
|
-
import * as RpcGroup from "effect/unstable/rpc/RpcGroup";
|
|
29
28
|
import * as Socket from "effect/unstable/socket/Socket";
|
|
30
|
-
import { Ignorer } from "@systemfsoftware/stryker-ignorer-interface";
|
|
31
29
|
//#region src/Worker.schema.d.ts
|
|
32
30
|
declare const ChildProcessCrashedError_base: Schema.Class<ChildProcessCrashedError, Schema.TaggedStruct<"ChildProcessCrashedError", {
|
|
33
31
|
readonly pid: Schema.Int;
|
|
@@ -66,7 +64,7 @@ type WorkerExit = ChildProcessCrashedError | OutOfMemoryError;
|
|
|
66
64
|
interface SpawnedSocketWorker {
|
|
67
65
|
readonly pid: number;
|
|
68
66
|
readonly clientLayer: Layer.Layer<RpcClient.Protocol, Socket.SocketError>;
|
|
69
|
-
readonly exited: Effect.Effect<never, WorkerExit>;
|
|
67
|
+
readonly exited: Effect$1.Effect<never, WorkerExit>;
|
|
70
68
|
}
|
|
71
69
|
interface WorkerSpawnParams {
|
|
72
70
|
readonly entrypoint: string;
|
|
@@ -77,7 +75,7 @@ interface WorkerSpawnParams {
|
|
|
77
75
|
readonly env?: Readonly<Record<string, string>> | undefined;
|
|
78
76
|
}
|
|
79
77
|
interface WorkerLauncherShape {
|
|
80
|
-
readonly spawn: (params: WorkerSpawnParams) => Effect.Effect<SpawnedSocketWorker, ChildProcessCrashedError, Scope.Scope>;
|
|
78
|
+
readonly spawn: (params: WorkerSpawnParams) => Effect$1.Effect<SpawnedSocketWorker, ChildProcessCrashedError, Scope.Scope>;
|
|
81
79
|
}
|
|
82
80
|
declare const WorkerLauncher_base: Context.ServiceClass<WorkerLauncher, "@systemfsoftware/stryker-js/WorkerLauncher", WorkerLauncherShape>;
|
|
83
81
|
declare class WorkerLauncher extends WorkerLauncher_base {}
|
|
@@ -85,7 +83,7 @@ type WorkerBootError = WorkerExit | WorkerBootTimeoutError;
|
|
|
85
83
|
interface WorkerClientParams<Rpcs extends Rpc.Any> extends WorkerSpawnParams {
|
|
86
84
|
readonly rpcs: RpcGroup.RpcGroup<Rpcs>;
|
|
87
85
|
}
|
|
88
|
-
declare const makeWorkerClient: <Rpcs extends Rpc.Any>(params: WorkerClientParams<Rpcs>) => Effect.Effect<RpcClient.RpcClient<Rpcs, RpcClientError>, WorkerBootError, Scope.Scope | WorkerLauncher>;
|
|
86
|
+
declare const makeWorkerClient: <Rpcs extends Rpc.Any>(params: WorkerClientParams<Rpcs>) => Effect$1.Effect<RpcClient.RpcClient<Rpcs, RpcClientError>, WorkerBootError, Scope.Scope | WorkerLauncher>;
|
|
89
87
|
//#endregion
|
|
90
88
|
//#region src/RunEvent.schema.d.ts
|
|
91
89
|
declare const RunPhase: S.Literals<readonly ["prepare", "instrument", "dry-run", "mutation-test"]>;
|
|
@@ -210,7 +208,7 @@ interface TestCoverage {
|
|
|
210
208
|
//#endregion
|
|
211
209
|
//#region src/Worker.d.ts
|
|
212
210
|
interface IdGeneratorShape {
|
|
213
|
-
readonly next: Effect.Effect<number>;
|
|
211
|
+
readonly next: Effect$1.Effect<number>;
|
|
214
212
|
}
|
|
215
213
|
declare const IdGenerator_base: Context.ServiceClass<IdGenerator, "@systemfsoftware/stryker-js/Worker/IdGenerator", IdGeneratorShape>;
|
|
216
214
|
declare class IdGenerator extends IdGenerator_base {}
|
|
@@ -269,12 +267,62 @@ declare const MergeResult_base: S.Class<MergeResult, S.TaggedStruct<"MergeResult
|
|
|
269
267
|
readonly merged: S.$Record<S.String, S.Unknown>;
|
|
270
268
|
}>, {}>;
|
|
271
269
|
declare class MergeResult extends MergeResult_base {}
|
|
270
|
+
declare const ExtendsStepDocumentSchema: S.Struct<{
|
|
271
|
+
readonly path: S.String;
|
|
272
|
+
readonly options: S.$Record<S.String, S.Unknown>;
|
|
273
|
+
}>;
|
|
274
|
+
type ExtendsStepDocument = typeof ExtendsStepDocumentSchema.Type;
|
|
275
|
+
declare const ExtendsStepStateSchema: S.Struct<{
|
|
276
|
+
readonly visited: S.$Array<S.String>;
|
|
277
|
+
readonly documents: S.$Array<S.Struct<{
|
|
278
|
+
readonly path: S.String;
|
|
279
|
+
readonly options: S.$Record<S.String, S.Unknown>;
|
|
280
|
+
}>>;
|
|
281
|
+
}>;
|
|
282
|
+
type ExtendsStepState = typeof ExtendsStepStateSchema.Type;
|
|
283
|
+
type ExtendsRefusalReason = 'cycle' | 'non-string-extends';
|
|
284
|
+
declare const ExtendsStepDone_base: S.Class<ExtendsStepDone, S.TaggedStruct<"done", {
|
|
285
|
+
readonly options: S.$Record<S.String, S.Unknown>;
|
|
286
|
+
}>, {}>;
|
|
287
|
+
declare class ExtendsStepDone extends ExtendsStepDone_base {}
|
|
288
|
+
declare const ExtendsStepRead_base: S.Class<ExtendsStepRead, S.TaggedStruct<"read", {
|
|
289
|
+
readonly path: S.String;
|
|
290
|
+
readonly state: S.Struct<{
|
|
291
|
+
readonly visited: S.$Array<S.String>;
|
|
292
|
+
readonly documents: S.$Array<S.Struct<{
|
|
293
|
+
readonly path: S.String;
|
|
294
|
+
readonly options: S.$Record<S.String, S.Unknown>;
|
|
295
|
+
}>>;
|
|
296
|
+
}>;
|
|
297
|
+
}>, {}>;
|
|
298
|
+
declare class ExtendsStepRead extends ExtendsStepRead_base {}
|
|
299
|
+
declare const ExtendsStepResolve_base: S.Class<ExtendsStepResolve, S.TaggedStruct<"resolve", {
|
|
300
|
+
readonly specifier: S.String;
|
|
301
|
+
readonly state: S.Struct<{
|
|
302
|
+
readonly visited: S.$Array<S.String>;
|
|
303
|
+
readonly documents: S.$Array<S.Struct<{
|
|
304
|
+
readonly path: S.String;
|
|
305
|
+
readonly options: S.$Record<S.String, S.Unknown>;
|
|
306
|
+
}>>;
|
|
307
|
+
}>;
|
|
308
|
+
}>, {}>;
|
|
309
|
+
declare class ExtendsStepResolve extends ExtendsStepResolve_base {}
|
|
310
|
+
declare const ExtendsStepRefused_base: S.Class<ExtendsStepRefused, S.TaggedStruct<"refused", {
|
|
311
|
+
readonly reason: S.Literals<readonly ["cycle", "non-string-extends"]>;
|
|
312
|
+
readonly file: S.String;
|
|
313
|
+
}>, {}>;
|
|
314
|
+
declare class ExtendsStepRefused extends ExtendsStepRefused_base {}
|
|
315
|
+
type ExtendsStepDecision = ExtendsStepDone | ExtendsStepRead | ExtendsStepResolve | ExtendsStepRefused;
|
|
272
316
|
declare const survivorsPriorReport: S.optionalKey<S.String>;
|
|
273
317
|
declare const extendsPropertySchema: S.optionalKey<S.String>;
|
|
274
318
|
declare const forkOptionsSchema: S.StructWithRest<S.Struct<{
|
|
275
319
|
readonly allowConsoleColors: S.withDecodingDefaultKey<S.Boolean, never>;
|
|
276
320
|
readonly buildCommand: S.optional<S.String>;
|
|
277
|
-
readonly checkers: S.withDecodingDefaultKey<S.$Array<S.
|
|
321
|
+
readonly checkers: S.withDecodingDefaultKey<S.$Array<S.Struct<{
|
|
322
|
+
readonly plugin: S.String;
|
|
323
|
+
readonly nodeArgs: S.optional<S.$Array<S.String>>;
|
|
324
|
+
readonly options: S.optional<S.$Record<S.String, S.Unknown>>;
|
|
325
|
+
}>>, never>;
|
|
278
326
|
readonly checkerNodeArgs: S.withDecodingDefaultKey<S.$Array<S.String>, never>;
|
|
279
327
|
readonly concurrency: S.optional<S.Union<readonly [S.Finite, S.String]>>;
|
|
280
328
|
readonly commandRunner: S.withDecodingDefaultKey<S.StructWithRest<S.Struct<{
|
|
@@ -321,7 +369,11 @@ declare const forkOptionsSchema: S.StructWithRest<S.Struct<{
|
|
|
321
369
|
readonly symlinkNodeModules: S.withDecodingDefaultKey<S.Boolean, never>;
|
|
322
370
|
readonly tempDirName: S.withDecodingDefaultKey<S.String, never>;
|
|
323
371
|
readonly cleanTempDir: S.withDecodingDefaultKey<S.Literals<readonly ["always", false, true]>, never>;
|
|
324
|
-
readonly testRunner: S.withDecodingDefaultKey<S.String,
|
|
372
|
+
readonly testRunner: S.withDecodingDefaultKey<S.Union<readonly [S.String, S.Struct<{
|
|
373
|
+
readonly plugin: S.String;
|
|
374
|
+
readonly nodeArgs: S.optional<S.$Array<S.String>>;
|
|
375
|
+
readonly options: S.optional<S.$Record<S.String, S.Unknown>>;
|
|
376
|
+
}>]>, never>;
|
|
325
377
|
readonly testRunnerNodeArgs: S.withDecodingDefaultKey<S.$Array<S.String>, never>;
|
|
326
378
|
readonly thresholds: S.withDecodingDefaultKey<S.Struct<{
|
|
327
379
|
readonly high: S.withDecodingDefaultKey<S.Finite, never>;
|
|
@@ -367,7 +419,7 @@ interface SpawnReporterWorkerParams {
|
|
|
367
419
|
readonly options: StrykerOptions;
|
|
368
420
|
readonly tempDirPrefix: string;
|
|
369
421
|
}
|
|
370
|
-
declare const spawnReporterWorker: (params: SpawnReporterWorkerParams) => Effect.Effect<ReporterWorkerClient, WorkerBootError, Scope.Scope | WorkerLauncher>;
|
|
422
|
+
declare const spawnReporterWorker: (params: SpawnReporterWorkerParams) => Effect$1.Effect<ReporterWorkerClient, WorkerBootError, Scope.Scope | WorkerLauncher>;
|
|
371
423
|
//#endregion
|
|
372
424
|
//#region src/IncrementalReport.schema.d.ts
|
|
373
425
|
declare const IncrementalReportSchema: S.StructWithRest<S.Struct<{
|
|
@@ -506,4 +558,4 @@ interface MutationTestDone {
|
|
|
506
558
|
readonly verdict: ExitClass | null;
|
|
507
559
|
}
|
|
508
560
|
//#endregion
|
|
509
|
-
export {
|
|
561
|
+
export { Heartbeat as $, ExtendsStepDecision as A, MergeCommand as B, ConfigDocumentSchema as C, ConfigFileUnreadableError as D, ConfigFileNotFoundError as E, ExtendsStepRefused as F, survivorsPriorReport as G, ReadConfigCommand as H, ExtendsStepResolve as I, classifyWorkerExit as J, IdGenerator as K, ExtendsStepState as L, ExtendsStepDocumentSchema as M, ExtendsStepDone as N, ConfigFileUnsupportedError as O, ExtendsStepRead as P, RunIdentityShape as Q, ExtendsStepStateSchema as R, spawnReporterWorker as S, ConfigFileInvalidError as T, extendsPropertySchema as U, MergeResult as V, forkOptionsSchema as W, RunEvents as X, TestCoverage as Y, RunIdentity as Z, REPORTER_EVENT_BATCH_BOUND as _, connectRetry as _t, WiredRunLayer as a, RunMutantTested as at, SpawnReporterWorkerParams as b, OutOfMemoryError as bt, PrepareDone as c, RunTerminalEvent as ct, RunEnvironmentShape as d, WorkerBootError as dt, HelpRendered as et, SandboxHandle as f, WorkerClientParams as ft, IncrementalReportSchema as g, WorkerSpawnParams as gt, ProjectFile as h, WorkerLauncherShape as ht, StageServices as i, RunFailed as it, ExtendsStepDocument as j, ExtendsRefusalReason as k, PrepareExecutorArgs as l, VerdictReached as lt, Project as m, WorkerLauncher as mt, EnginePorts as n, PlanKnown as nt, DryRunDone as o, RunPhase as ot, StrykerError as p, WorkerExit as pt, IdGeneratorShape as q, RunStageServices as r, RunEvent as rt, InstrumentDone as s, RunStarted as st, MutationTestDone as t, PhaseEntered as tt, RunEnvironment as u, SpawnedSocketWorker as ut, ReporterStage as v, makeWorkerClient as vt, ConfigError as w, reporterWorkerFactory as x, WorkerBootTimeoutError as xt, ReporterWorkerClient as y, ChildProcessCrashedError as yt, ImportedModuleSchema as z };
|