@systemfsoftware/stryker-js 10.2.0 → 11.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.
Files changed (33) hide show
  1. package/CHANGELOG.md +6 -0
  2. package/README.md +34 -26
  3. package/dist/Run.schema-B_qdjbe9.mjs +226 -0
  4. package/dist/{Run.schema-B-Pi3bCB.d.mts → Run.schema-CUpTIyrj.d.mts} +91 -19
  5. package/dist/RunEnvironment.service-zgwzyXpO.d.mts +456 -0
  6. package/dist/config.d.mts +6 -22
  7. package/dist/config.mjs +2 -7
  8. package/dist/{Run.schema-Ba34IwAY.mjs → dist-ClUhPgb6.mjs} +3432 -4856
  9. package/dist/{dist-CjdAPjrJ.mjs → dist-DKhCurgc.mjs} +95 -1
  10. package/dist/events.d.mts +2 -2
  11. package/dist/events.mjs +2 -2
  12. package/dist/index-CMCCQdTd.d.mts +4087 -0
  13. package/dist/index.d.mts +1084 -3321
  14. package/dist/index.mjs +116 -3
  15. package/dist/main.mjs +114296 -87310
  16. package/dist/promises.d.mts +4 -4
  17. package/dist/promises.mjs +6 -10
  18. package/dist/{rolldown-runtime-XITHOX9H.mjs → rolldown-runtime-8H4AJuhK.mjs} +1 -2
  19. package/dist/run-stages.cell-CPpkn7og.mjs +8639 -0
  20. package/dist/stryker-config.schema-CCnDtVuW.mjs +82 -0
  21. package/dist/stryker-config.schema-lr7GMjpY.d.mts +35 -0
  22. package/package.json +31 -46
  23. package/dist/compiler-BTpMWGqK.mjs +0 -48955
  24. package/dist/compiler-CEwQzMxZ.mjs +0 -48955
  25. package/dist/dist-Cpq7Esc3.mjs +0 -17404
  26. package/dist/dist-Dmv1WEP8.mjs +0 -5337
  27. package/dist/dist-DsmXFb2_.mjs +0 -17404
  28. package/dist/index-tt2EziOT.d.mts +0 -1216
  29. package/dist/merge-config-CHZWyvVQ.mjs +0 -19
  30. package/dist/mutation-test.cell-Dq23b2NP.d.mts +0 -1758
  31. package/dist/output-mode-CfGHDpi5.d.mts +0 -17
  32. package/dist/sourcemap-codec-qFD3eFBj.mjs +0 -186
  33. package/dist/src-CcqEZJIY.mjs +0 -6559
@@ -0,0 +1,456 @@
1
+ import { a as mod_d_exports$5, c as mod_d_exports$2, d as Ignorer, i as mod_d_exports$4, l as mod_d_exports$3$1, n as mod_d_exports$2$1, o as mod_d_exports$6, r as mod_d_exports$3, s as mod_d_exports$1, t as mod_d_exports, u as Framework } from "./index-CMCCQdTd.mjs";
2
+ import { A as VerdictReached, D as SkippedReported, _ as PluginsReported, b as RunFailed, c as Heartbeat, i as FormatRegistryResolved, l as HelpRendered, m as PlanKnown, p as PhaseEntered, w as RunStarted, x as RunMutantTested, y as RunEvent } from "./Run.schema-CUpTIyrj.mjs";
3
+ import { Cell, Sandwich, Workflow } from "@systemfsoftware/effect-cell-types";
4
+ import "effect/Option";
5
+ import * as Result from "effect/Result";
6
+ import * as S from "effect/Schema";
7
+ import * as Effect$1 from "effect/Effect";
8
+ import { Pipeable } from "effect/Pipeable";
9
+ import * as Context from "effect/Context";
10
+ import { Schema } from "effect";
11
+ import * as RpcGroup from "effect/unstable/rpc/RpcGroup";
12
+ import * as Cause from "effect/Cause";
13
+ import * as Path from "effect/Path";
14
+ import * as FileSystem from "effect/FileSystem";
15
+ import "effect/Exit";
16
+ import * as Stream from "effect/Stream";
17
+ import * as ChildProcessSpawner from "effect/unstable/process/ChildProcessSpawner";
18
+ import * as EffectDuration from "effect/Duration";
19
+ import * as Layer from "effect/Layer";
20
+ import * as Queue from "effect/Queue";
21
+ import * as Scope from "effect/Scope";
22
+ import * as HashMap from "effect/HashMap";
23
+ import * as MutableHashMap from "effect/MutableHashMap";
24
+ import * as RpcClient from "effect/unstable/rpc/RpcClient";
25
+ import * as Stdio from "effect/Stdio";
26
+ import * as MutableHashSet from "effect/MutableHashSet";
27
+ import { RpcClientError } from "effect/unstable/rpc/RpcClientError";
28
+ import * as Socket from "effect/unstable/socket/Socket";
29
+ import { PlatformError } from "effect/PlatformError";
30
+ import "effect/Console";
31
+ import "effect/Runtime";
32
+ //#region src/Worker.schema.d.ts
33
+ /**
34
+ * The child process hosting a worker ended when it was not supposed to.
35
+ */
36
+ declare const WorkerExitTypeId: unique symbol;
37
+ type WorkerExitTypeId = typeof WorkerExitTypeId;
38
+ declare const ChildProcessCrashedError_base: Schema.Class<ChildProcessCrashedError, Schema.TaggedStruct<"ChildProcessCrashedError", {
39
+ readonly pid: Schema.Int;
40
+ readonly exit: Schema.Union<readonly [Schema.Struct<{
41
+ readonly _tag: Schema.Literals<readonly ["Code"]>;
42
+ readonly code: Schema.Int;
43
+ }>, Schema.Struct<{
44
+ readonly _tag: Schema.Literals<readonly ["Signal"]>;
45
+ readonly signal: Schema.NonEmptyString;
46
+ }>]>;
47
+ readonly cause: Schema.optional<Schema.String>;
48
+ }>, import("effect/Cause").YieldableError>;
49
+ declare class ChildProcessCrashedError extends ChildProcessCrashedError_base {
50
+ readonly [WorkerExitTypeId]: symbol;
51
+ readonly exitClass: 'InternalError';
52
+ }
53
+ declare const OutOfMemoryError_base: Schema.Class<OutOfMemoryError, Schema.TaggedStruct<"OutOfMemoryError", {
54
+ readonly pid: Schema.Int;
55
+ readonly exitCode: Schema.Int;
56
+ }>, import("effect/Cause").YieldableError>;
57
+ declare class OutOfMemoryError extends OutOfMemoryError_base {
58
+ readonly [WorkerExitTypeId]: symbol;
59
+ readonly exitClass: 'RuntimeError';
60
+ }
61
+ type WorkerExit = ChildProcessCrashedError | OutOfMemoryError;
62
+ type WorkerBootError = WorkerExit | WorkerBootTimeoutError;
63
+ declare const WorkerBootTimeoutError_base: Schema.Class<WorkerBootTimeoutError, Schema.TaggedStruct<"WorkerBootTimeoutError", {
64
+ readonly pid: Schema.Int;
65
+ }>, import("effect/Cause").YieldableError>;
66
+ declare class WorkerBootTimeoutError extends WorkerBootTimeoutError_base {
67
+ readonly exitClass: 'InternalError';
68
+ }
69
+ //#endregion
70
+ //#region src/ConfigError.schema.d.ts
71
+ declare const ConfigFileNotFoundError_base: S.Class<ConfigFileNotFoundError, S.TaggedStruct<"ConfigFileNotFoundError", {
72
+ readonly file: S.String;
73
+ }>, import("effect/Cause").YieldableError>;
74
+ declare class ConfigFileNotFoundError extends ConfigFileNotFoundError_base {
75
+ readonly exitClass: 'ConfigError';
76
+ }
77
+ declare const ConfigFileUnsupportedError_base: S.Class<ConfigFileUnsupportedError, S.TaggedStruct<"ConfigFileUnsupportedError", {
78
+ readonly file: S.String;
79
+ readonly hint: S.String;
80
+ }>, import("effect/Cause").YieldableError>;
81
+ declare class ConfigFileUnsupportedError extends ConfigFileUnsupportedError_base {
82
+ readonly exitClass: 'ConfigError';
83
+ get message(): string;
84
+ }
85
+ declare const ConfigFileUnreadableError_base: S.Class<ConfigFileUnreadableError, S.TaggedStruct<"ConfigFileUnreadableError", {
86
+ readonly file: S.String;
87
+ readonly cause: S.Unknown;
88
+ }>, import("effect/Cause").YieldableError>;
89
+ declare class ConfigFileUnreadableError extends ConfigFileUnreadableError_base {
90
+ readonly exitClass: 'ConfigError';
91
+ }
92
+ declare const ConfigFileInvalidError_base: S.Class<ConfigFileInvalidError, S.TaggedStruct<"ConfigFileInvalidError", {
93
+ readonly file: S.String;
94
+ readonly cause: S.Unknown;
95
+ }>, import("effect/Cause").YieldableError>;
96
+ declare class ConfigFileInvalidError extends ConfigFileInvalidError_base {
97
+ readonly exitClass: 'ConfigError';
98
+ }
99
+ declare const ConfigError_base: S.Class<ConfigError, S.TaggedStruct<"ConfigError", {
100
+ readonly message: S.String;
101
+ }>, import("effect/Cause").YieldableError>;
102
+ declare class ConfigError extends ConfigError_base {
103
+ readonly exitClass: 'ConfigError';
104
+ }
105
+ //#endregion
106
+ //#region src/run-events.service.d.ts
107
+ declare const RunEvents_base: Context.ServiceClass<RunEvents, "@systemfsoftware/stryker-js/run-events.service/RunEvents", Queue.Queue<FormatRegistryResolved | Heartbeat | HelpRendered | PhaseEntered | PlanKnown | PluginsReported | RunFailed | RunMutantTested | RunStarted | SkippedReported | VerdictReached, Cause.Done<void>>>;
108
+ declare class RunEvents extends RunEvents_base {}
109
+ interface RunIdentityShape {
110
+ readonly runId: string;
111
+ readonly basePath: string;
112
+ }
113
+ declare const RunIdentity_base: Context.ServiceClass<RunIdentity, "@systemfsoftware/stryker-js/run-events.service/RunIdentity", RunIdentityShape>;
114
+ declare class RunIdentity extends RunIdentity_base {}
115
+ //#endregion
116
+ //#region src/output-mode.schema.d.ts
117
+ /**
118
+ * Mode type vocabulary shared with the CLI package. Runtime resolution
119
+ * (`resolveMode`) and gate functions (`isProgressEnabled`, `isColorEnabled`)
120
+ * live in the CLI; the `ResolvedMode` fields (`mode`, `signal`,
121
+ * `stdoutIsTTY`) ride along in `VerdictEnvelope` (`verdict-envelope.ts`),
122
+ * so the types stay where the data does.
123
+ */
124
+ type OutputMode = 'human' | 'machine';
125
+ type ModeSignal = 'flag' | 'env' | 'tty' | 'agent' | 'tool';
126
+ interface ResolvedMode {
127
+ readonly mode: OutputMode;
128
+ readonly signal: ModeSignal;
129
+ readonly stdoutIsTTY: boolean;
130
+ }
131
+ //#endregion
132
+ //#region src/stryker-error.schema.d.ts
133
+ declare const StrykerError_base: Schema.Class<StrykerError, Schema.TaggedStruct<"StrykerError", {
134
+ readonly message: Schema.String;
135
+ readonly cause: Schema.optional<Schema.Unknown>;
136
+ }>, import("effect/Cause").YieldableError>;
137
+ declare class StrykerError extends StrykerError_base {}
138
+ //#endregion
139
+ //#region src/frame-run-event.workflow.d.ts
140
+ interface ResolvedModeInput {
141
+ readonly mode: 'machine' | 'human';
142
+ readonly signal: 'flag' | 'env' | 'tty' | 'agent' | 'tool';
143
+ }
144
+ //#endregion
145
+ //#region src/run-event-stream.service.d.ts
146
+ type FramedDrain = (framed: Stream.Stream<string, never, never>) => Effect$1.Effect<void, never, never>;
147
+ interface RunEventDrainShape {
148
+ readonly drainFramed: FramedDrain;
149
+ readonly setProgressStreamFile: (fileName: string) => Effect$1.Effect<void, never, never>;
150
+ }
151
+ declare const RunEventDrain_base: Context.ServiceClass<RunEventDrain, "@systemfsoftware/stryker-js/run-event-stream.service/RunEventDrain", RunEventDrainShape>;
152
+ declare class RunEventDrain extends RunEventDrain_base {
153
+ static readonly layer: Layer.Layer<RunEventDrain, never, Stdio.Stdio>;
154
+ static readonly DefaultProgressStreamFile = "reports/mutation-stream.jsonl";
155
+ static readonly fileLayer: Layer.Layer<RunEventDrain, never, Stdio.Stdio | FileSystem.FileSystem | Path.Path>;
156
+ }
157
+ declare const RunEventDrainLive: Layer.Layer<RunEventDrain, never, Stdio.Stdio>;
158
+ interface RunEventStream {
159
+ readonly queue: Queue.Queue<RunEvent, Cause.Done>;
160
+ readonly runId: string;
161
+ readonly startedAt: number;
162
+ readonly isOpen: Effect$1.Effect<boolean, never, never>;
163
+ readonly ensureOpen: (openResolved: ResolvedModeInput) => Effect$1.Effect<void, never, never>;
164
+ readonly open: Effect$1.Effect<void, never, never>;
165
+ readonly closeAndDrain: Effect$1.Effect<void, never, never>;
166
+ }
167
+ declare const makeRunEventStream: (resolved: ResolvedModeInput) => Effect$1.Effect<{
168
+ queue: Queue.Queue<FormatRegistryResolved | Heartbeat | HelpRendered | PhaseEntered | PlanKnown | PluginsReported | RunFailed | RunMutantTested | RunStarted | SkippedReported | VerdictReached, Cause.Done<void>>;
169
+ runId: string;
170
+ startedAt: number;
171
+ isOpen: Effect$1.Effect<boolean, never, never>;
172
+ ensureOpen: (openResolved: ResolvedModeInput) => Effect$1.Effect<void, never, never>;
173
+ open: Effect$1.Effect<void, never, never>;
174
+ closeAndDrain: Effect$1.Effect<void, never, never>;
175
+ }, never, RunEventDrain | Stdio.Stdio>;
176
+ //#endregion
177
+ //#region src/Project.schema.d.ts
178
+ interface ProjectFile extends mod_d_exports$2.FileDescription {
179
+ readonly name: string;
180
+ readonly mutate: mod_d_exports$2.MutateDescription;
181
+ readonly content: string | undefined;
182
+ readonly originalContent: string | undefined;
183
+ }
184
+ interface Project {
185
+ readonly fileDescriptions: mod_d_exports$2.FileDescriptions;
186
+ readonly incrementalReport: mod_d_exports$4.MutationTestResult | undefined;
187
+ readonly testFiles: readonly string[];
188
+ readonly files: MutableHashMap.MutableHashMap<string, ProjectFile>;
189
+ readonly filesToMutate: MutableHashMap.MutableHashMap<string, ProjectFile>;
190
+ }
191
+ //#endregion
192
+ //#region src/project-files.service.d.ts
193
+ type ContentPair = readonly [ProjectFile, string];
194
+ type PathPair = readonly [string, string];
195
+ interface InPlaceTarget {
196
+ readonly backupDirectory: string;
197
+ readonly basePath: string;
198
+ }
199
+ interface SandboxTarget {
200
+ readonly workingDirectory: string;
201
+ readonly basePath: string;
202
+ }
203
+ interface ProjectFilesShape {
204
+ readonly read: (file: ProjectFile) => Effect$1.Effect<string, PlatformError>;
205
+ readonly readAll: (files: Iterable<ProjectFile>) => Effect$1.Effect<readonly ContentPair[], PlatformError>;
206
+ readonly readAllOriginal: (files: Iterable<ProjectFile>) => Effect$1.Effect<readonly ContentPair[], PlatformError>;
207
+ readonly writeAllInPlace: (files: Iterable<readonly [string, ProjectFile]>, target: InPlaceTarget) => Effect$1.Effect<readonly PathPair[], PlatformError>;
208
+ readonly writeAllToSandbox: (files: Iterable<readonly [string, ProjectFile]>, target: SandboxTarget) => Effect$1.Effect<readonly PathPair[], PlatformError>;
209
+ }
210
+ declare const ProjectFiles_base: Context.ServiceClass<ProjectFiles, "@systemfsoftware/stryker-js/project-files.service/ProjectFiles", ProjectFilesShape>;
211
+ declare class ProjectFiles extends ProjectFiles_base {
212
+ static readonly layer: Layer.Layer<ProjectFiles, never, FileSystem.FileSystem | Path.Path>;
213
+ }
214
+ //#endregion
215
+ //#region src/spawned-socket-worker.handle.d.ts
216
+ declare const TypeId: unique symbol;
217
+ type TypeId = typeof TypeId;
218
+ declare const ClientLayerTypeId: unique symbol;
219
+ interface SpawnedSocketWorker extends Pipeable {
220
+ readonly [TypeId]: typeof TypeId;
221
+ readonly [ClientLayerTypeId]: Layer.Layer<RpcClient.Protocol, Socket.SocketError>;
222
+ readonly pid: number;
223
+ readonly exited: Effect$1.Effect<never, WorkerExit>;
224
+ }
225
+ declare const make: (worker: {
226
+ readonly pid: number;
227
+ readonly clientLayer: Layer.Layer<RpcClient.Protocol, Socket.SocketError>;
228
+ readonly exited: Effect$1.Effect<never, WorkerExit>;
229
+ }) => SpawnedSocketWorker;
230
+ //#endregion
231
+ //#region src/WorkerLauncher.service.d.ts
232
+ interface WorkerSpawnParams {
233
+ readonly entrypoint: string;
234
+ readonly workingDirectory: string;
235
+ readonly execArgv: readonly string[];
236
+ readonly optionsJson: string;
237
+ readonly tempDirPrefix: string;
238
+ readonly env?: Readonly<Record<string, string>> | undefined;
239
+ }
240
+ interface WorkerLauncherShape {
241
+ readonly spawn: (params: WorkerSpawnParams) => Effect$1.Effect<SpawnedSocketWorker, ChildProcessCrashedError, Scope.Scope>;
242
+ }
243
+ declare const WorkerLauncher_base: Context.ServiceClass<WorkerLauncher, "@systemfsoftware/stryker-js/WorkerLauncher.service/WorkerLauncher", WorkerLauncherShape>;
244
+ declare class WorkerLauncher extends WorkerLauncher_base {}
245
+ //#endregion
246
+ //#region src/reporter-stream.service.d.ts
247
+ declare const ReporterStageTypeId: unique symbol;
248
+ /**
249
+ * An attached reporter stage, opaque at the engine boundary: the published
250
+ * phase types carry this handle so the attachment machinery (queues, fibers,
251
+ * the state latch) never reaches an adopter's compiler. Constructed only by
252
+ * `attachReporterFactories`.
253
+ */
254
+ interface ReporterStage {
255
+ readonly [ReporterStageTypeId]: typeof ReporterStageTypeId;
256
+ }
257
+ declare const REPORTER_EVENT_BATCH_BOUND = 128;
258
+ type ReporterWorkerClient = RpcClient.RpcClient<RpcGroup.Rpcs<typeof mod_d_exports$3.ReporterRpcs>, RpcClientError>;
259
+ declare const reporterWorkerFactory: (client: ReporterWorkerClient) => mod_d_exports$5.ReporterFactory;
260
+ interface SpawnReporterWorkerParams {
261
+ readonly entrypoint: string;
262
+ readonly projectBasePath: string;
263
+ readonly execArgv: readonly string[];
264
+ readonly options: mod_d_exports$2$1.StrykerOptions;
265
+ readonly tempDirPrefix: string;
266
+ }
267
+ declare const spawnReporterWorker: (params: SpawnReporterWorkerParams) => Effect$1.Effect<ReporterWorkerClient, WorkerBootError, Scope.Scope | WorkerLauncher>;
268
+ //#endregion
269
+ //#region src/test-coverage.schema.d.ts
270
+ interface TestCoverage {
271
+ readonly testsByMutantId: MutableHashMap.MutableHashMap<string, MutableHashSet.MutableHashSet<mod_d_exports$6.TestResult>>;
272
+ readonly testsById: MutableHashMap.MutableHashMap<string, mod_d_exports$6.TestResult>;
273
+ readonly staticCoverage: mod_d_exports$3$1.CoverageData | undefined;
274
+ readonly hitsByMutantId: MutableHashMap.MutableHashMap<string, number>;
275
+ }
276
+ //#endregion
277
+ //#region src/Worker.service.d.ts
278
+ interface IdGeneratorShape {
279
+ readonly next: Effect$1.Effect<number>;
280
+ }
281
+ declare const IdGenerator_base: Context.ServiceClass<IdGenerator, "@systemfsoftware/stryker-js/Worker.service/IdGenerator", IdGeneratorShape>;
282
+ declare class IdGenerator extends IdGenerator_base {
283
+ static readonly layer: Layer.Layer<IdGenerator, never, never>;
284
+ }
285
+ //#endregion
286
+ //#region src/Sandbox.handle.d.ts
287
+ interface SandboxHandle {
288
+ readonly workingDirectory: string;
289
+ readonly sandboxFileFor: (fileName: string) => Result.Result<string, StrykerError>;
290
+ readonly originalFileFor: (sandboxFileName: string) => string;
291
+ }
292
+ //#endregion
293
+ //#region src/Plugins.schema.d.ts
294
+ type PluginKind = mod_d_exports$3.WorkerPluginKind | 'Evaluator';
295
+ interface WorkerPluginDescriptor<K extends mod_d_exports$3.WorkerPluginKind = mod_d_exports$3.WorkerPluginKind> {
296
+ readonly kind: K;
297
+ readonly name: string;
298
+ readonly workerEntry: string;
299
+ }
300
+ interface EvaluatorPluginDescriptor {
301
+ readonly kind: 'Evaluator';
302
+ readonly name: string;
303
+ }
304
+ type AnyWorkerPluginDescriptor = { [K in mod_d_exports$3.WorkerPluginKind]: WorkerPluginDescriptor<K>; }[mod_d_exports$3.WorkerPluginKind];
305
+ type AnyPluginDescriptor = AnyWorkerPluginDescriptor | EvaluatorPluginDescriptor;
306
+ type PluginDescriptorOf<K extends PluginKind> = Extract<AnyPluginDescriptor, {
307
+ readonly kind: K;
308
+ }>;
309
+ type PluginDescriptor<K extends PluginKind = PluginKind> = PluginDescriptorOf<K>;
310
+ interface WorkerPluginSource<K extends mod_d_exports$3.WorkerPluginKind = mod_d_exports$3.WorkerPluginKind> {
311
+ readonly kind: K;
312
+ readonly name: string;
313
+ readonly modulePath: string;
314
+ readonly workerEntry: string;
315
+ }
316
+ interface EvaluatorPluginSource {
317
+ readonly kind: 'Evaluator';
318
+ readonly name: string;
319
+ readonly modulePath: string;
320
+ }
321
+ type AnyWorkerPluginSource = { [K in mod_d_exports$3.WorkerPluginKind]: WorkerPluginSource<K>; }[mod_d_exports$3.WorkerPluginKind];
322
+ type PluginSource = AnyWorkerPluginSource | EvaluatorPluginSource;
323
+ interface LoadedPlugins<A = unknown> {
324
+ readonly schemaContributions: readonly Record<string, A>[];
325
+ readonly pluginsByKind: HashMap.HashMap<PluginKind, readonly PluginDescriptor[]>;
326
+ readonly pluginModulePaths: readonly string[];
327
+ readonly pluginSources: readonly PluginSource[];
328
+ readonly ignorers: readonly Ignorer[];
329
+ readonly frameworks: readonly {
330
+ readonly moduleName: string;
331
+ readonly framework: Framework;
332
+ }[];
333
+ }
334
+ //#endregion
335
+ //#region src/reporter-output.service.d.ts
336
+ type OutputChannel = 'stdout' | 'stderr';
337
+ interface ReporterOutputShape {
338
+ readonly write: (channel: OutputChannel, chunks: readonly string[]) => Effect$1.Effect<void, PlatformError>;
339
+ }
340
+ declare const ReporterOutput_base: Context.ServiceClass<ReporterOutput, "@systemfsoftware/stryker-js/reporter-output.service/ReporterOutput", ReporterOutputShape>;
341
+ declare class ReporterOutput extends ReporterOutput_base {
342
+ static readonly layer: Layer.Layer<ReporterOutput, never, Stdio.Stdio>;
343
+ }
344
+ //#endregion
345
+ //#region src/reporter.service.d.ts
346
+ interface ReporterShape {
347
+ readonly builtin: Readonly<Record<string, mod_d_exports$5.ReporterFactory>>;
348
+ }
349
+ declare const Reporter_base: Context.ServiceClass<Reporter, "@systemfsoftware/stryker-js/reporter.service/Reporter", ReporterShape>;
350
+ declare class Reporter extends Reporter_base {
351
+ static readonly layer: Layer.Layer<Reporter, never, ReporterOutput | FileSystem.FileSystem | Path.Path>;
352
+ }
353
+ //#endregion
354
+ //#region src/run/explain-file-skip.workflow.d.ts
355
+ declare const FrameworkClaimant: S.Struct<{
356
+ readonly package: S.String;
357
+ readonly extensions: S.$Array<S.String>;
358
+ }>;
359
+ type FrameworkClaimant = S.Schema.Type<typeof FrameworkClaimant>;
360
+ //#endregion
361
+ //#region src/run/prepare.cell.d.ts
362
+ interface PrepareDone {
363
+ readonly project: Project;
364
+ readonly loadedPlugins: LoadedPlugins;
365
+ readonly ignorers: readonly Ignorer[];
366
+ readonly formatRegistry: mod_d_exports$1.FormatRegistry;
367
+ readonly options: mod_d_exports$2$1.StrykerOptions;
368
+ readonly temporaryDirectoryPath: string;
369
+ readonly reporterStage: ReporterStage;
370
+ readonly frameworkClaimants: readonly FrameworkClaimant[];
371
+ }
372
+ interface PrepareExecutorArgs {
373
+ cliOptions: mod_d_exports$2$1.PartialStrykerOptions;
374
+ targetMutatePatterns: string[] | undefined;
375
+ }
376
+ //#endregion
377
+ //#region src/run/instrument.cell.d.ts
378
+ interface InstrumentDone extends PrepareDone {
379
+ readonly mutants: readonly mod_d_exports$3$1.Mutant[];
380
+ readonly sandbox: SandboxHandle;
381
+ readonly concurrency: {
382
+ readonly testRunners: number;
383
+ readonly checkers: number;
384
+ };
385
+ }
386
+ //#endregion
387
+ //#region src/run/dry-run.cell.d.ts
388
+ interface DryRunDone extends InstrumentDone {
389
+ readonly dryRunResult: mod_d_exports$6.CompleteDryRunResult;
390
+ readonly testCoverage: TestCoverage;
391
+ readonly timeOverhead: EffectDuration.Duration;
392
+ }
393
+ //#endregion
394
+ //#region src/run/mutation-test.cell.d.ts
395
+ interface MutationTestDone {
396
+ readonly results: readonly mod_d_exports$3$1.RunMutantResult[];
397
+ readonly verdict: mod_d_exports$3.ExitClass | null;
398
+ }
399
+ //#endregion
400
+ //#region src/mutation-reporting.service.d.ts
401
+ interface MutationReportingInput {
402
+ readonly results: readonly mod_d_exports$3$1.RunMutantResult[];
403
+ readonly options: mod_d_exports$2$1.StrykerOptions;
404
+ readonly project: Project;
405
+ readonly testCoverage: TestCoverage;
406
+ readonly runId: string;
407
+ readonly resolvedMode: ResolvedMode;
408
+ readonly basePath: string;
409
+ readonly reporterStage: ReporterStage;
410
+ readonly formatRegistry: mod_d_exports$1.FormatRegistry;
411
+ }
412
+ interface MutationReportingService {
413
+ readonly reportCheckFailure: (mutant: mod_d_exports$3$1.MutantTestCoverage, result: Exclude<mod_d_exports.CheckResult, mod_d_exports.PassedCheckResult>) => Effect$1.Effect<mod_d_exports$3$1.RunMutantResult>;
414
+ readonly reportMutantRunResult: (mutant: mod_d_exports$3$1.MutantTestCoverage, result: mod_d_exports$6.MutantRunResult) => Effect$1.Effect<mod_d_exports$3$1.RunMutantResult>;
415
+ readonly reportAll: (input: MutationReportingInput) => Effect$1.Effect<MutationTestDone, PlatformError>;
416
+ readonly checkpoint: (input: MutationReportingInput) => Effect$1.Effect<void, PlatformError>;
417
+ }
418
+ declare const MutationReporting_base: Context.ServiceClass<MutationReporting, "@systemfsoftware/stryker-js/mutation-reporting.service/MutationReporting", MutationReportingService>;
419
+ declare class MutationReporting extends MutationReporting_base {
420
+ static readonly layer: Layer.Layer<MutationReporting, never, FileSystem.FileSystem | Path.Path | RunEvents | ProjectFiles>;
421
+ }
422
+ //#endregion
423
+ //#region src/run/StageServices.service.d.ts
424
+ type StageServices = ChildProcessSpawner.ChildProcessSpawner | FileSystem.FileSystem | IdGenerator | MutationReporting | Path.Path | ProjectFiles | Reporter | RunEnvironment | RunEvents | Scope.Scope | Stdio.Stdio | WorkerLauncher;
425
+ type EnginePorts = ChildProcessSpawner.ChildProcessSpawner | FileSystem.FileSystem | Path.Path | Stdio.Stdio | WorkerLauncher;
426
+ type RunStageServices = ProjectFiles | Reporter | RunEnvironment | RunEvents | IdGenerator | MutationReporting | Scope.Scope;
427
+ type WiredRunLayer = Layer.Layer<RunStageServices | EnginePorts, never, never>;
428
+ //#endregion
429
+ //#region src/run/RunEnvironment.service.d.ts
430
+ interface RunEnvironmentShape {
431
+ readonly runId: string;
432
+ readonly resolvedMode: ResolvedMode;
433
+ readonly runStartedAt: number;
434
+ readonly basePath: string;
435
+ readonly builtinReporters: Readonly<Record<string, mod_d_exports$5.ReporterFactory>>;
436
+ readonly allowConsoleColors: boolean;
437
+ }
438
+ declare const RunEnvironment_base: Context.ServiceClass<RunEnvironment, "@systemfsoftware/stryker-js/run/RunEnvironment.service/RunEnvironment", RunEnvironmentShape>;
439
+ declare class RunEnvironment extends RunEnvironment_base {
440
+ static readonly stage: {
441
+ (env: RunEnvironmentShape, events?: Queue.Queue<RunEvent, Cause.Done>): Layer.Layer<RunStageServices, never, EnginePorts>;
442
+ (events?: Queue.Queue<RunEvent, Cause.Done>): (env: RunEnvironmentShape) => Layer.Layer<RunStageServices, never, EnginePorts>;
443
+ };
444
+ static readonly forStream: {
445
+ (mode: ResolvedMode, stream: RunEventStream, host: {
446
+ readonly noColor?: string | undefined;
447
+ readonly builtinReporters: Readonly<Record<string, mod_d_exports$5.ReporterFactory>>;
448
+ }): Effect$1.Effect<RunEnvironmentShape, PlatformError, FileSystem.FileSystem>;
449
+ (stream: RunEventStream, host: {
450
+ readonly noColor?: string | undefined;
451
+ readonly builtinReporters: Readonly<Record<string, mod_d_exports$5.ReporterFactory>>;
452
+ }): (mode: ResolvedMode) => Effect$1.Effect<RunEnvironmentShape, PlatformError, FileSystem.FileSystem>;
453
+ };
454
+ }
455
+ //#endregion
456
+ export { ConfigError as $, ReporterWorkerClient as A, ProjectFile as B, WorkerPluginSource as C, TestCoverage as D, IdGeneratorShape as E, WorkerLauncherShape as F, ResolvedModeInput as G, RunEventDrainLive as H, WorkerSpawnParams as I, OutputMode as J, StrykerError as K, SpawnedSocketWorker as L, reporterWorkerFactory as M, spawnReporterWorker as N, REPORTER_EVENT_BATCH_BOUND as O, WorkerLauncher as P, RunIdentityShape as Q, make as R, WorkerPluginDescriptor as S, IdGenerator as T, RunEventStream as U, RunEventDrain as V, makeRunEventStream as W, RunEvents as X, ResolvedMode as Y, RunIdentity as Z, LoadedPlugins as _, StageServices as a, OutOfMemoryError as at, PluginKind as b, DryRunDone as c, WorkerExit as ct, PrepareExecutorArgs as d, ConfigFileInvalidError as et, AnyPluginDescriptor as f, EvaluatorPluginSource as g, EvaluatorPluginDescriptor as h, RunStageServices as i, ChildProcessCrashedError as it, SpawnReporterWorkerParams as j, ReporterStage as k, InstrumentDone as l, AnyWorkerPluginSource as m, RunEnvironmentShape as n, ConfigFileUnreadableError as nt, WiredRunLayer as o, WorkerBootError as ot, AnyWorkerPluginDescriptor as p, ModeSignal as q, EnginePorts as r, ConfigFileUnsupportedError as rt, MutationTestDone as s, WorkerBootTimeoutError as st, RunEnvironment as t, ConfigFileNotFoundError as tt, PrepareDone as u, PluginDescriptor as v, SandboxHandle as w, PluginSource as x, PluginDescriptorOf as y, Project as z };
package/dist/config.d.mts CHANGED
@@ -1,23 +1,7 @@
1
- import { K as StrykerOptions, P as PartialStrykerOptions } from "./index-tt2EziOT.mjs";
2
- import { n as OutputMode } from "./output-mode-CfGHDpi5.mjs";
3
- //#region src/config/stryker-config.d.ts
4
- interface ConfigEnv {
5
- readonly command: 'run' | 'merge-reports';
6
- readonly isDryRun: boolean;
7
- readonly mode: OutputMode;
8
- readonly isCi: boolean;
9
- }
10
- type StrykerConfig = PartialStrykerOptions;
11
- type StrykerConfigFn = (env: ConfigEnv) => StrykerConfig | Promise<StrykerConfig>;
12
- type StrykerConfigExport = StrykerConfig | Promise<StrykerConfig> | StrykerConfigFn;
1
+ import { n as mod_d_exports$2 } from "./index-CMCCQdTd.mjs";
2
+ import { a as StrykerConfig, i as Primitive, n as Immutable, o as StrykerConfigExport, r as ImmutablePrimitive, s as StrykerConfigFn, t as ConfigEnv } from "./stryker-config.schema-lr7GMjpY.mjs";
3
+ //#region src/config/mod.d.ts
4
+ export type PartialStrykerOptions = mod_d_exports$2.PartialStrykerOptions;
5
+ export type StrykerOptions = mod_d_exports$2.StrykerOptions;
13
6
  //#endregion
14
- //#region src/config/define-config.d.ts
15
- export declare function defineConfig(config: StrykerConfig): StrykerConfig;
16
- export declare function defineConfig(config: Promise<StrykerConfig>): Promise<StrykerConfig>;
17
- export declare function defineConfig(config: StrykerConfigFn): StrykerConfigFn;
18
- export declare function defineConfig(config: StrykerConfigExport): StrykerConfigExport;
19
- //#endregion
20
- //#region src/config/merge-config.d.ts
21
- export declare const mergeConfig: (defaults: StrykerConfig, overrides: StrykerConfig) => StrykerConfig;
22
- //#endregion
23
- export type { ConfigEnv, PartialStrykerOptions, StrykerConfig, StrykerConfigExport, StrykerConfigFn, StrykerOptions };
7
+ export { type ConfigEnv, type Immutable, type ImmutablePrimitive, type Primitive, StrykerConfig, type StrykerConfigExport, type StrykerConfigFn };
package/dist/config.mjs CHANGED
@@ -1,7 +1,2 @@
1
- import { t as mergeConfig } from "./merge-config-CHZWyvVQ.mjs";
2
- //#region src/config/define-config.ts
3
- function defineConfig(config) {
4
- return config;
5
- }
6
- //#endregion
7
- export { defineConfig, mergeConfig };
1
+ import { t as StrykerConfig } from "./stryker-config.schema-CCnDtVuW.mjs";
2
+ export { StrykerConfig };