@systemfsoftware/stryker-js-instrumenter 9.0.1 → 10.0.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/CHANGELOG.md CHANGED
@@ -1,5 +1,43 @@
1
1
  # @systemfsoftware/stryker-js-instrumenter
2
2
 
3
+ ## 10.0.1
4
+
5
+ ### Patch Changes
6
+
7
+ - The packages now depend on `@systemfsoftware/effect-cell-types` 11.
8
+
9
+ - Every tagged error now has a one-line message built from its fields, so a failure names the file, mutant, plugin, worker or exit code involved instead of an empty message. The errors' tags, fields and encoded forms are unchanged.
10
+
11
+ ## 10.0.0
12
+
13
+ ### Major Changes
14
+
15
+ - Rendering a caught cause is a function now, not a method on a schema class. `ErrorText.errorTextOf(cause)` and `ErrorText.causeTextOf(cause)` replace `ErrorText.ErrorText.fromCause(cause)` and `ErrorText.CauseText.fromCause(cause)`.
16
+
17
+ Replace the two calls: `ErrorText.ErrorText.fromCause(cause)` becomes `ErrorText.errorTextOf(cause)`, and `ErrorText.CauseText.fromCause(cause)` becomes `ErrorText.causeTextOf(cause)`. Both return the same `Option.Option<ErrorText>` and `Option.Option<CauseText>` as before. The `ErrorText` and `CauseText` classes, their value types, and `ErrnoException` are unchanged.
18
+
19
+ - File names handed to `instrument` are canonicalized: a backslash in an input path is folded to `/`, in the returned file names and in each mutant's file name alike. A result now reports one spelling of a path, matching the spelling `Mutant.fileName` already used, instead of echoing whatever separator the caller passed.
20
+
21
+ No call-site change is needed — keep passing plain strings to `instrument`.
22
+
23
+ - Mutant ids are decimal index strings. Every schema that carried a mutant id as a plain string now decodes `Mutant.MutantId` and refuses anything else: the mutation report and its mutant results, reporter events (`mutationTestingPlanReady` plans, `mutantTested`), the machine run stream (`mutant` and `verdict`), the survivors prior report, and the mutant coverage keys produced by test runners.
24
+
25
+ Mutant ids are minted only as the mutant's canonical non-negative decimal index (`Mutant.MutantId`), including in the instrumenter's planned mutants, placement sites, and checker answers. Consume the new `Mutant.MutantId` schema instead of assuming an arbitrary non-empty string; ids such as `constructor` or `__proto__` no longer decode.
26
+
27
+ - A mutant's status is declared once, as the eight-value `Mutant.MutantStatus`, plus the named subsets a run partitions on: `Mutant.SurvivorStatus`, `Mutant.RememberedStatus`, `Mutant.EphemeralStatus`, and `Mutant.ActionableStatus`. Import the subset your decision matches instead of re-listing the statuses you accept.
28
+
29
+ Mutants are tagged structs now. A status reason decodes only together with a status, and the remembered-mutant and ignored-mutant rows carry the same narrowed status as the subset they were selected by.
30
+
31
+ - Source locations are 1-based and validated end to end. `Mutant.Location`, `Mutant.Position`, `Mutant.Span`, `Mutant.OpenEndLocation`, `Mutant.ScriptOrigin`, and `Mutant.LineStarts` replace the former `LocationSchema`, `PositionSchema`, and `OpenEndLocationSchema`; a location whose end precedes its start, or a line or column below 1, no longer decodes.
32
+
33
+ - A mutant location always speaks the report contract, so a producer that minted 0-based coordinates or a bare number must switch to the new schemas.
34
+ - An embedded script's origin is a `ScriptOrigin` (1-based line plus a column shift), not a position.
35
+ - Incremental state from releases that stored the earlier column base is no longer matched: those mutants are re-tested, not reused, while the run rewrites the state.
36
+
37
+ ### Patch Changes
38
+
39
+ - Stages now run as cells over workflows, multi-item work runs as Effect streams, pools and worker transport use scoped Effect resources, and named operations are traced with Effect.fn. The Angular ignorer now declares @systemfsoftware/stryker-ignorer-kit as a runtime dependency.
40
+
3
41
  ## 9.0.1
4
42
 
5
43
  ### Patch Changes
package/dist/index.d.mts CHANGED
@@ -1,8 +1,9 @@
1
1
  import * as Option from "effect/Option";
2
- import "effect/Result";
2
+ import * as Result from "effect/Result";
3
3
  import * as S from "effect/Schema";
4
4
  import * as Effect from "effect/Effect";
5
5
  import { Handle, Workflow } from "@systemfsoftware/effect-cell-types";
6
+ import * as Arr from "effect/Array";
6
7
  import { EmbeddedDocument, FormatId, Framework, FrameworkContext } from "@systemfsoftware/stryker-framework-interface";
7
8
  import "oxc-parser";
8
9
  import "@oxc-project/types";
@@ -10,16 +11,12 @@ import "@oxc-project/types";
10
11
  declare const ErrorText_base: S.Class<ErrorText, S.Struct<{
11
12
  readonly text: S.NonEmptyString;
12
13
  }>, {}>;
13
- declare class ErrorText extends ErrorText_base {
14
- static fromCause: <A>(cause: A) => Option.Option<ErrorText>;
15
- }
14
+ declare class ErrorText extends ErrorText_base {}
16
15
  type ErrorTextValue = ErrorText;
17
16
  declare const CauseText_base: S.Class<CauseText, S.Struct<{
18
17
  readonly text: S.NonEmptyString;
19
18
  }>, {}>;
20
- declare class CauseText extends CauseText_base {
21
- static fromCause: <A>(cause: A) => Option.Option<CauseText>;
22
- }
19
+ declare class CauseText extends CauseText_base {}
23
20
  type CauseTextValue = CauseText;
24
21
  interface ErrnoException extends Error {
25
22
  code?: string;
@@ -27,8 +24,12 @@ interface ErrnoException extends Error {
27
24
  path?: string;
28
25
  syscall?: string;
29
26
  }
27
+ //#endregion
28
+ //#region src/error-text.d.ts
29
+ declare const errorTextOf: <A = unknown>(cause: A) => Option.Option<ErrorText>;
30
+ declare const causeTextOf: <A = unknown>(cause: A) => Option.Option<CauseText>;
30
31
  declare namespace mod_d_exports {
31
- export { CauseText, CauseTextValue, ErrnoException, ErrorText, ErrorTextValue };
32
+ export { CauseText, CauseTextValue, ErrnoException, ErrorText, ErrorTextValue, causeTextOf, errorTextOf };
32
33
  }
33
34
  //#endregion
34
35
  //#region ../ignorers/interface/dist/index.d.ts
@@ -1338,54 +1339,73 @@ declare interface YieldExpression$1 extends Span$1 {
1338
1339
  }
1339
1340
  //#endregion
1340
1341
  //#region src/Location.schema.d.ts
1341
- /**
1342
- * File coordinates in the mutation-testing-report-schema contract: both line
1343
- * and column are 1-based. The first line of a file is line 1, and the first
1344
- * character of a line is column 1. Slicing a source line by one of these
1345
- * positions uses `line - 1` for the line index and `column - 1` for the
1346
- * character offset.
1347
- */
1348
- declare const PositionSchema: S.Struct<{
1342
+ declare const Offset: S.Int;
1343
+ type Offset = typeof Offset.Type;
1344
+ /** A 1-based line: the first line of a file is line 1. */
1345
+ declare const Line: S.Int;
1346
+ type Line = typeof Line.Type;
1347
+ /** A 1-based column: the first character of a line is column 1. */
1348
+ declare const Column: S.Int;
1349
+ type Column = typeof Column.Type;
1350
+ declare const Position: S.Struct<{
1349
1351
  readonly line: S.Int;
1350
1352
  readonly column: S.Int;
1351
1353
  }>;
1352
- type Position = typeof PositionSchema.Type;
1353
- declare const LocationSchema: S.Struct<{
1354
- readonly start: S.Struct<{
1355
- readonly line: S.Int;
1356
- readonly column: S.Int;
1357
- }>;
1358
- readonly end: S.Struct<{
1359
- readonly line: S.Int;
1360
- readonly column: S.Int;
1361
- }>;
1354
+ type Position = typeof Position.Type;
1355
+ declare const Location: S.declare<{
1356
+ readonly start: {
1357
+ readonly line: number;
1358
+ readonly column: number;
1359
+ };
1360
+ readonly end: {
1361
+ readonly line: number;
1362
+ readonly column: number;
1363
+ };
1364
+ }, {
1365
+ readonly start: {
1366
+ readonly line: number;
1367
+ readonly column: number;
1368
+ };
1369
+ readonly end: {
1370
+ readonly line: number;
1371
+ readonly column: number;
1372
+ };
1362
1373
  }>;
1363
- type Location = typeof LocationSchema.Type;
1364
- declare const OpenEndLocationSchema: S.Struct<{
1365
- readonly start: S.Struct<{
1366
- readonly line: S.Int;
1367
- readonly column: S.Int;
1368
- }>;
1369
- readonly end: S.optional<S.Struct<{
1370
- readonly line: S.Int;
1371
- readonly column: S.Int;
1372
- }>>;
1374
+ type Location = typeof Location.Type;
1375
+ declare const OpenEndLocation: S.declare<{
1376
+ readonly start: {
1377
+ readonly line: number;
1378
+ readonly column: number;
1379
+ };
1380
+ readonly end?: {
1381
+ readonly line: number;
1382
+ readonly column: number;
1383
+ } | undefined;
1384
+ }, {
1385
+ readonly start: {
1386
+ readonly line: number;
1387
+ readonly column: number;
1388
+ };
1389
+ readonly end?: {
1390
+ readonly line: number;
1391
+ readonly column: number;
1392
+ } | undefined;
1373
1393
  }>;
1374
- type OpenEndLocation = typeof OpenEndLocationSchema.Type;
1375
- /**
1376
- * A mutant's `location` already speaks the report contract (1-based line and
1377
- * column), so the report's location is that location unchanged.
1378
- */
1379
- declare const ReportLocationFromMutant: S.Struct<{
1380
- readonly start: S.Struct<{
1381
- readonly line: S.Int;
1382
- readonly column: S.Int;
1383
- }>;
1384
- readonly end: S.Struct<{
1385
- readonly line: S.Int;
1386
- readonly column: S.Int;
1387
- }>;
1394
+ type OpenEndLocation = typeof OpenEndLocation.Type;
1395
+ declare const Span: S.declare<{
1396
+ readonly start: number;
1397
+ readonly end: number;
1398
+ }, {
1399
+ readonly start: number;
1400
+ readonly end: number;
1401
+ }>;
1402
+ type Span = typeof Span.Type;
1403
+ declare const ScriptOrigin: S.Struct<{
1404
+ readonly line: S.Int;
1405
+ readonly columnShift: S.Int;
1388
1406
  }>;
1407
+ type ScriptOrigin = typeof ScriptOrigin.Type;
1408
+ type LineStarts = Arr.NonEmptyReadonlyArray<Offset>;
1389
1409
  //#endregion
1390
1410
  //#region src/Syntax.schema.d.ts
1391
1411
  declare const AstFormat: S.Literals<readonly ["js", "ts", "tsx"]>;
@@ -1403,7 +1423,7 @@ interface BaseAst {
1403
1423
  originFileName: string;
1404
1424
  rawContent: string;
1405
1425
  root: Program;
1406
- offset?: Position;
1426
+ offset?: ScriptOrigin;
1407
1427
  }
1408
1428
  interface EmbeddedAst {
1409
1429
  format: 'embedded';
@@ -1436,29 +1456,189 @@ interface TsxAst extends BaseAst {
1436
1456
  type ScriptAst = JSAst | TSAst | TsxAst;
1437
1457
  type Ast = JSAst | TSAst | TsxAst | EmbeddedAst;
1438
1458
  //#endregion
1459
+ //#region src/Instrument.schema.d.ts
1460
+ declare const InstrumentError_base: S.Class<InstrumentError, S.TaggedStruct<"InstrumentError", {
1461
+ readonly message: S.String;
1462
+ readonly cause: S.Defect;
1463
+ }>, import("effect/Cause").YieldableError>;
1464
+ declare class InstrumentError extends InstrumentError_base {
1465
+ get message(): string;
1466
+ }
1467
+ declare const MutateDescriptionSchema: S.Union<readonly [S.Boolean, S.$Array<S.declare<{
1468
+ readonly start: {
1469
+ readonly line: number;
1470
+ readonly column: number;
1471
+ };
1472
+ readonly end: {
1473
+ readonly line: number;
1474
+ readonly column: number;
1475
+ };
1476
+ }, {
1477
+ readonly start: {
1478
+ readonly line: number;
1479
+ readonly column: number;
1480
+ };
1481
+ readonly end: {
1482
+ readonly line: number;
1483
+ readonly column: number;
1484
+ };
1485
+ }>>]>;
1486
+ type MutateDescription = typeof MutateDescriptionSchema.Type;
1487
+ interface FileDescription {
1488
+ readonly mutate: MutateDescription;
1489
+ }
1490
+ type FileDescriptions = Record<string, FileDescription>;
1491
+ declare const InstrumenterOptionsSchema: S.Struct<{
1492
+ readonly excludedMutations: S.$Array<S.String>;
1493
+ readonly ignorers: S.$Array<S.Unknown>;
1494
+ readonly noHeader: S.optional<S.Boolean>;
1495
+ readonly optInMutations: S.optional<S.$Array<S.String>>;
1496
+ }>;
1497
+ type InstrumenterOptions = typeof InstrumenterOptionsSchema.Type;
1498
+ declare const InstrumentFileSkip_base: S.Class<InstrumentFileSkip, S.TaggedStruct<"InstrumentFileSkip", {
1499
+ readonly file: S.String;
1500
+ readonly extension: S.String;
1501
+ readonly reason: S.String;
1502
+ }>, {}>;
1503
+ declare class InstrumentFileSkip extends InstrumentFileSkip_base {}
1504
+ declare const InstrumentResult_base: S.Class<InstrumentResult$1, S.TaggedStruct<"InstrumentResult", {
1505
+ readonly files: S.$Array<S.Struct<{
1506
+ readonly name: S.decodeTo<S.brand<S.String, "CanonicalFileName">, S.String, never, never>;
1507
+ readonly content: S.String;
1508
+ readonly mutate: S.Union<readonly [S.Boolean, S.$Array<S.declare<{
1509
+ readonly start: {
1510
+ readonly line: number;
1511
+ readonly column: number;
1512
+ };
1513
+ readonly end: {
1514
+ readonly line: number;
1515
+ readonly column: number;
1516
+ };
1517
+ }, {
1518
+ readonly start: {
1519
+ readonly line: number;
1520
+ readonly column: number;
1521
+ };
1522
+ readonly end: {
1523
+ readonly line: number;
1524
+ readonly column: number;
1525
+ };
1526
+ }>>]>;
1527
+ }>>;
1528
+ readonly mutants: S.$Array<S.Struct<{
1529
+ readonly _tag: S.tag<"Mutant">;
1530
+ readonly id: S.brand<S.String, "MutantId">;
1531
+ readonly fileName: S.decodeTo<S.brand<S.String, "CanonicalFileName">, S.String, never, never>;
1532
+ readonly mutatorName: S.brand<S.NonEmptyString, "MutatorName">;
1533
+ readonly replacement: S.String;
1534
+ readonly location: S.declare<{
1535
+ readonly start: {
1536
+ readonly line: number;
1537
+ readonly column: number;
1538
+ };
1539
+ readonly end: {
1540
+ readonly line: number;
1541
+ readonly column: number;
1542
+ };
1543
+ }, {
1544
+ readonly start: {
1545
+ readonly line: number;
1546
+ readonly column: number;
1547
+ };
1548
+ readonly end: {
1549
+ readonly line: number;
1550
+ readonly column: number;
1551
+ };
1552
+ }>;
1553
+ readonly status: S.optional<S.Literals<readonly ["Killed", "Survived", "NoCoverage", "CompileError", "RuntimeError", "Timeout", "Ignored", "Pending"]>>;
1554
+ readonly statusReason: S.optional<S.String>;
1555
+ readonly coveredBy: S.optional<S.$Array<S.String>>;
1556
+ readonly static: S.optional<S.Boolean>;
1557
+ readonly testsCompleted: S.optional<S.Finite>;
1558
+ readonly description: S.optional<S.String>;
1559
+ }>>;
1560
+ readonly skipped: S.$Array<typeof InstrumentFileSkip>;
1561
+ }>, {}>;
1562
+ declare class InstrumentResult$1 extends InstrumentResult_base {}
1563
+ //#endregion
1564
+ //#region src/Parser.schema.d.ts
1565
+ declare const ParseFailed_base: S.Class<ParseFailed, S.TaggedStruct<"ParseFailed", {
1566
+ readonly fileName: S.String;
1567
+ readonly message: S.String;
1568
+ readonly location: S.Struct<{
1569
+ readonly line: S.Int;
1570
+ readonly column: S.Int;
1571
+ }>;
1572
+ readonly cause: S.Defect;
1573
+ }>, import("effect/Cause").YieldableError>;
1574
+ declare class ParseFailed extends ParseFailed_base {
1575
+ get message(): string;
1576
+ }
1577
+ //#endregion
1578
+ //#region src/Parser.service.d.ts
1579
+ interface ParserOptions {}
1580
+ interface ParserContext {
1581
+ parse: (code: string, fileName: string, scriptFormat: ScriptFormat) => Effect.Effect<ScriptAst, ParseFailed>;
1582
+ }
1583
+ //#endregion
1584
+ //#region src/print/PrintFailed.schema.d.ts
1585
+ declare const PrintFailed_base: S.Class<PrintFailed, S.TaggedStruct<"PrintFailed", {
1586
+ readonly message: S.String;
1587
+ }>, import("effect/Cause").YieldableError>;
1588
+ declare class PrintFailed extends PrintFailed_base {}
1589
+ //#endregion
1590
+ //#region src/Printer.d.ts
1591
+ interface PrinterContext {
1592
+ print: (file: Ast, context: PrinterContext) => Result.Result<string, PrintFailed>;
1593
+ }
1594
+ //#endregion
1439
1595
  //#region src/Mutant.schema.d.ts
1440
1596
  declare const MutantStatusSchema: S.Literals<readonly ["Killed", "Survived", "NoCoverage", "CompileError", "RuntimeError", "Timeout", "Ignored", "Pending"]>;
1441
1597
  type MutantStatus = typeof MutantStatusSchema.Type;
1442
- declare const MutantId: S.brand<S.NonEmptyString, "MutantId">;
1598
+ declare const SurvivorStatusSchema: S.Literals<readonly ["Survived", "NoCoverage"]>;
1599
+ type SurvivorStatus = typeof SurvivorStatusSchema.Type;
1600
+ declare const RememberedStatusSchema: S.Literals<readonly ["Survived", "Killed", "Timeout", "NoCoverage", "Ignored"]>;
1601
+ type RememberedStatus = typeof RememberedStatusSchema.Type;
1602
+ declare const EphemeralStatusSchema: S.Literals<readonly ["CompileError", "RuntimeError", "Pending"]>;
1603
+ type EphemeralStatus = typeof EphemeralStatusSchema.Type;
1604
+ declare const ActionableStatusSchema: S.Literals<readonly ["Survived", "NoCoverage", "Timeout", "RuntimeError"]>;
1605
+ type ActionableStatus = typeof ActionableStatusSchema.Type;
1606
+ declare const MutantId: S.brand<S.String, "MutantId">;
1443
1607
  type MutantId = typeof MutantId.Type;
1444
1608
  declare const MutatorName: S.brand<S.NonEmptyString, "MutatorName">;
1445
1609
  type MutatorName = typeof MutatorName.Type;
1446
1610
  declare const CanonicalFileName: S.decodeTo<S.brand<S.String, "CanonicalFileName">, S.String, never, never>;
1447
1611
  type CanonicalFileName = typeof CanonicalFileName.Type;
1448
- declare const Mutant_base: S.Class<Mutant$1, S.TaggedStruct<"Mutant", {
1449
- readonly id: S.brand<S.NonEmptyString, "MutantId">;
1612
+ /**
1613
+ * A mutant's file location in the mutation-testing-report-schema contract:
1614
+ * 1-based line and 1-based column, the same base the JSON report and the
1615
+ * machine stream emit. Every producer on the instrument path (node spans,
1616
+ * embedded-region shifts) targets this base; no downstream layer converts.
1617
+ */
1618
+ declare const Mutant$1: S.Struct<{
1619
+ readonly _tag: S.tag<"Mutant">;
1620
+ readonly id: S.brand<S.String, "MutantId">;
1450
1621
  readonly fileName: S.decodeTo<S.brand<S.String, "CanonicalFileName">, S.String, never, never>;
1451
1622
  readonly mutatorName: S.brand<S.NonEmptyString, "MutatorName">;
1452
1623
  readonly replacement: S.String;
1453
- readonly location: S.Struct<{
1454
- readonly start: S.Struct<{
1455
- readonly line: S.Int;
1456
- readonly column: S.Int;
1457
- }>;
1458
- readonly end: S.Struct<{
1459
- readonly line: S.Int;
1460
- readonly column: S.Int;
1461
- }>;
1624
+ readonly location: S.declare<{
1625
+ readonly start: {
1626
+ readonly line: number;
1627
+ readonly column: number;
1628
+ };
1629
+ readonly end: {
1630
+ readonly line: number;
1631
+ readonly column: number;
1632
+ };
1633
+ }, {
1634
+ readonly start: {
1635
+ readonly line: number;
1636
+ readonly column: number;
1637
+ };
1638
+ readonly end: {
1639
+ readonly line: number;
1640
+ readonly column: number;
1641
+ };
1462
1642
  }>;
1463
1643
  readonly status: S.optional<S.Literals<readonly ["Killed", "Survived", "NoCoverage", "CompileError", "RuntimeError", "Timeout", "Ignored", "Pending"]>>;
1464
1644
  readonly statusReason: S.optional<S.String>;
@@ -1466,15 +1646,40 @@ declare const Mutant_base: S.Class<Mutant$1, S.TaggedStruct<"Mutant", {
1466
1646
  readonly static: S.optional<S.Boolean>;
1467
1647
  readonly testsCompleted: S.optional<S.Finite>;
1468
1648
  readonly description: S.optional<S.String>;
1469
- }>, {}>;
1470
- /**
1471
- * A mutant's file location in the mutation-testing-report-schema contract:
1472
- * 1-based line and 1-based column, the same base the JSON report and the
1473
- * machine stream emit. Every producer on the instrument path (node spans,
1474
- * embedded-region shifts) targets this base; no downstream layer converts.
1475
- */
1476
- declare class Mutant$1 extends Mutant_base {}
1477
- declare const MutantFromUnknown: S.compose<typeof Mutant$1, S.Unknown>;
1649
+ }>;
1650
+ type Mutant$1 = typeof Mutant$1.Type;
1651
+ declare const MutantFromUnknown: S.compose<S.Struct<{
1652
+ readonly _tag: S.tag<"Mutant">;
1653
+ readonly id: S.brand<S.String, "MutantId">;
1654
+ readonly fileName: S.decodeTo<S.brand<S.String, "CanonicalFileName">, S.String, never, never>;
1655
+ readonly mutatorName: S.brand<S.NonEmptyString, "MutatorName">;
1656
+ readonly replacement: S.String;
1657
+ readonly location: S.declare<{
1658
+ readonly start: {
1659
+ readonly line: number;
1660
+ readonly column: number;
1661
+ };
1662
+ readonly end: {
1663
+ readonly line: number;
1664
+ readonly column: number;
1665
+ };
1666
+ }, {
1667
+ readonly start: {
1668
+ readonly line: number;
1669
+ readonly column: number;
1670
+ };
1671
+ readonly end: {
1672
+ readonly line: number;
1673
+ readonly column: number;
1674
+ };
1675
+ }>;
1676
+ readonly status: S.optional<S.Literals<readonly ["Killed", "Survived", "NoCoverage", "CompileError", "RuntimeError", "Timeout", "Ignored", "Pending"]>>;
1677
+ readonly statusReason: S.optional<S.String>;
1678
+ readonly coveredBy: S.optional<S.$Array<S.String>>;
1679
+ readonly static: S.optional<S.Boolean>;
1680
+ readonly testsCompleted: S.optional<S.Finite>;
1681
+ readonly description: S.optional<S.String>;
1682
+ }>, S.Unknown>;
1478
1683
  type MutantFromUnknown = typeof MutantFromUnknown.Type;
1479
1684
  declare const RunOptionsFields: {
1480
1685
  timeout: S.Finite;
@@ -1482,10 +1687,42 @@ declare const RunOptionsFields: {
1482
1687
  };
1483
1688
  declare const MutantActivationSchema: S.Literals<readonly ["runtime", "static"]>;
1484
1689
  type MutantActivation = typeof MutantActivationSchema.Type;
1690
+ declare const HitCount: S.Int;
1485
1691
  declare const MutantRunOptionsSchema: S.Struct<{
1486
1692
  readonly timeout: S.Finite;
1487
1693
  readonly disableBail: S.Boolean;
1488
- readonly activeMutant: typeof Mutant$1;
1694
+ readonly activeMutant: S.Struct<{
1695
+ readonly _tag: S.tag<"Mutant">;
1696
+ readonly id: S.brand<S.String, "MutantId">;
1697
+ readonly fileName: S.decodeTo<S.brand<S.String, "CanonicalFileName">, S.String, never, never>;
1698
+ readonly mutatorName: S.brand<S.NonEmptyString, "MutatorName">;
1699
+ readonly replacement: S.String;
1700
+ readonly location: S.declare<{
1701
+ readonly start: {
1702
+ readonly line: number;
1703
+ readonly column: number;
1704
+ };
1705
+ readonly end: {
1706
+ readonly line: number;
1707
+ readonly column: number;
1708
+ };
1709
+ }, {
1710
+ readonly start: {
1711
+ readonly line: number;
1712
+ readonly column: number;
1713
+ };
1714
+ readonly end: {
1715
+ readonly line: number;
1716
+ readonly column: number;
1717
+ };
1718
+ }>;
1719
+ readonly status: S.optional<S.Literals<readonly ["Killed", "Survived", "NoCoverage", "CompileError", "RuntimeError", "Timeout", "Ignored", "Pending"]>>;
1720
+ readonly statusReason: S.optional<S.String>;
1721
+ readonly coveredBy: S.optional<S.$Array<S.String>>;
1722
+ readonly static: S.optional<S.Boolean>;
1723
+ readonly testsCompleted: S.optional<S.Finite>;
1724
+ readonly description: S.optional<S.String>;
1725
+ }>;
1489
1726
  readonly sandboxFileName: S.String;
1490
1727
  readonly mutantActivation: S.Literals<readonly ["runtime", "static"]>;
1491
1728
  readonly reloadEnvironment: S.Boolean;
@@ -1493,8 +1730,8 @@ declare const MutantRunOptionsSchema: S.Struct<{
1493
1730
  readonly hitLimit: S.optionalKey<S.Int>;
1494
1731
  }>;
1495
1732
  declare const MutantCoverageSchema: S.Struct<{
1496
- readonly perTest: S.$Record<S.String, S.$Record<S.String, S.Int>>;
1497
- readonly static: S.$Record<S.String, S.Int>;
1733
+ readonly perTest: S.$Record<S.String, S.$Record<S.brand<S.String, "MutantId">, S.Int>>;
1734
+ readonly static: S.$Record<S.brand<S.String, "MutantId">, S.Int>;
1498
1735
  }>;
1499
1736
  type MutantCoverage = typeof MutantCoverageSchema.Type;
1500
1737
  type CoverageData = Record<string, number>;
@@ -1542,11 +1779,11 @@ declare const InstrumenterContext_base: S.Class<InstrumenterContext, S.Struct<{
1542
1779
  readonly activeMutant: S.optional<S.String>;
1543
1780
  readonly currentTestId: S.optional<S.String>;
1544
1781
  readonly mutantCoverage: S.optional<S.Struct<{
1545
- readonly perTest: S.$Record<S.String, S.$Record<S.String, S.Int>>;
1546
- readonly static: S.$Record<S.String, S.Int>;
1782
+ readonly perTest: S.$Record<S.String, S.$Record<S.brand<S.String, "MutantId">, S.Int>>;
1783
+ readonly static: S.$Record<S.brand<S.String, "MutantId">, S.Int>;
1547
1784
  }>>;
1548
- readonly hitCount: S.optional<S.Finite>;
1549
- readonly hitLimit: S.optional<S.Finite>;
1785
+ readonly hitCount: S.optional<S.Int>;
1786
+ readonly hitLimit: S.optional<S.Int>;
1550
1787
  }>, {}>;
1551
1788
  declare class InstrumenterContext extends InstrumenterContext_base {
1552
1789
  static readonly NAMESPACE = "__stryker__";
@@ -1561,92 +1798,6 @@ type MutantRunPlan = RunPlan;
1561
1798
  type MutantEarlyResultPlan = EarlyResultPlan;
1562
1799
  type MutantTestPlan = TestPlan;
1563
1800
  //#endregion
1564
- //#region src/Instrument.schema.d.ts
1565
- declare const InstrumentError_base: S.Class<InstrumentError, S.TaggedStruct<"InstrumentError", {
1566
- readonly message: S.String;
1567
- readonly cause: S.Defect;
1568
- }>, import("effect/Cause").YieldableError>;
1569
- declare class InstrumentError extends InstrumentError_base {
1570
- get message(): string;
1571
- }
1572
- declare const MutateDescriptionSchema: S.Union<readonly [S.Boolean, S.$Array<S.Struct<{
1573
- readonly start: S.Struct<{
1574
- readonly line: S.Int;
1575
- readonly column: S.Int;
1576
- }>;
1577
- readonly end: S.Struct<{
1578
- readonly line: S.Int;
1579
- readonly column: S.Int;
1580
- }>;
1581
- }>>]>;
1582
- type MutateDescription = typeof MutateDescriptionSchema.Type;
1583
- interface MutationRange {
1584
- readonly start: Position;
1585
- readonly end: Position;
1586
- }
1587
- interface FileDescription {
1588
- readonly mutate: MutateDescription;
1589
- }
1590
- type FileDescriptions = Record<string, FileDescription>;
1591
- declare const InstrumenterOptionsSchema: S.Struct<{
1592
- readonly excludedMutations: S.$Array<S.String>;
1593
- readonly ignorers: S.$Array<S.Unknown>;
1594
- readonly noHeader: S.optional<S.Boolean>;
1595
- readonly optInMutations: S.optional<S.$Array<S.String>>;
1596
- }>;
1597
- type InstrumenterOptions = typeof InstrumenterOptionsSchema.Type;
1598
- declare const InstrumentFileSkip_base: S.Class<InstrumentFileSkip, S.TaggedStruct<"InstrumentFileSkip", {
1599
- readonly file: S.String;
1600
- readonly extension: S.String;
1601
- readonly reason: S.String;
1602
- }>, {}>;
1603
- declare class InstrumentFileSkip extends InstrumentFileSkip_base {}
1604
- declare const InstrumentResult_base: S.Class<InstrumentResult$1, S.TaggedStruct<"InstrumentResult", {
1605
- readonly files: S.$Array<S.Struct<{
1606
- readonly name: S.String;
1607
- readonly content: S.String;
1608
- readonly mutate: S.Union<readonly [S.Boolean, S.$Array<S.Struct<{
1609
- readonly start: S.Struct<{
1610
- readonly line: S.Int;
1611
- readonly column: S.Int;
1612
- }>;
1613
- readonly end: S.Struct<{
1614
- readonly line: S.Int;
1615
- readonly column: S.Int;
1616
- }>;
1617
- }>>]>;
1618
- }>>;
1619
- readonly mutants: S.$Array<typeof Mutant$1>;
1620
- readonly skipped: S.$Array<typeof InstrumentFileSkip>;
1621
- }>, {}>;
1622
- declare class InstrumentResult$1 extends InstrumentResult_base {}
1623
- //#endregion
1624
- //#region src/Parser.schema.d.ts
1625
- declare const ParseFailed_base: S.Class<ParseFailed, S.TaggedStruct<"ParseFailed", {
1626
- readonly fileName: S.String;
1627
- readonly message: S.String;
1628
- readonly location: S.Struct<{
1629
- readonly line: S.Finite;
1630
- readonly column: S.Finite;
1631
- }>;
1632
- readonly cause: S.Defect;
1633
- }>, import("effect/Cause").YieldableError>;
1634
- declare class ParseFailed extends ParseFailed_base {
1635
- get message(): string;
1636
- }
1637
- //#endregion
1638
- //#region src/Parser.service.d.ts
1639
- interface ParserOptions {}
1640
- interface ParserContext {
1641
- parse: (code: string, fileName: string, scriptFormat: ScriptFormat) => Effect.Effect<ScriptAst, ParseFailed>;
1642
- }
1643
- //#endregion
1644
- //#region src/Printer.d.ts
1645
- type Printer<T extends Ast = Ast> = (file: T, context: PrinterContext) => string;
1646
- interface PrinterContext {
1647
- print: Printer<Ast>;
1648
- }
1649
- //#endregion
1650
1801
  //#region src/Mutator.service.d.ts
1651
1802
  interface Mutable {
1652
1803
  mutatorName: string;
@@ -1654,7 +1805,7 @@ interface Mutable {
1654
1805
  replacement: Node_2;
1655
1806
  }
1656
1807
  interface Mutant extends Mutable {
1657
- readonly id: string;
1808
+ readonly id: MutantId;
1658
1809
  readonly fileName: string;
1659
1810
  readonly original: Node_2;
1660
1811
  readonly location: Location;
@@ -1753,10 +1904,29 @@ declare const disableTypeChecks: {
1753
1904
  (registry?: FormatRegistry): (file: File) => Effect.Effect<File, InstrumentError>;
1754
1905
  };
1755
1906
  declare namespace mod_d_exports$2 {
1756
- export { File, FileDescription, FileDescriptions, InstrumentError, InstrumentFileSkip, InstrumentResult, InstrumenterOptions, MutateDescription, MutationRange, ParserOptions, disableTypeChecks, instrument };
1907
+ export { File, FileDescription, FileDescriptions, InstrumentError, InstrumentFileSkip, InstrumentResult, InstrumenterOptions, MutateDescription, ParserOptions, disableTypeChecks, instrument };
1757
1908
  }
1909
+ //#endregion
1910
+ //#region src/Location.d.ts
1911
+ export declare const lineStartsOf: (text: string) => LineStarts;
1912
+ export declare const positionAt: {
1913
+ (lineStarts: LineStarts, offset: Offset): Position;
1914
+ (offset: Offset): (lineStarts: LineStarts) => Position;
1915
+ };
1916
+ export declare const locationOf: {
1917
+ (lineStarts: LineStarts, span: Span): Location;
1918
+ (span: Span): (lineStarts: LineStarts) => Location;
1919
+ };
1920
+ export declare const originAt: {
1921
+ (lineStarts: LineStarts, offset: Offset): ScriptOrigin;
1922
+ (offset: Offset): (lineStarts: LineStarts) => ScriptOrigin;
1923
+ };
1924
+ export declare const offsetAt: {
1925
+ (lineStarts: LineStarts, position: Position): Option.Option<Offset>;
1926
+ (position: Position): (lineStarts: LineStarts) => Option.Option<Offset>;
1927
+ };
1758
1928
  declare namespace mod_d_exports$3 {
1759
- export { CanonicalFileName, CanonicalFileName as CanonicalFileNameValue, Coverage, CoverageData, CoveragePerTestId, EarlyResultPlan, InstrumenterContext, Location, LocationSchema, Mutant$1 as Mutant, MutantActivation, MutantActivationSchema, MutantCoverage, MutantCoverageSchema, MutantEarlyResultPlan, MutantFromUnknown, MutantFromUnknown as MutantFromUnknownValue, MutantId, MutantId as MutantIdValue, MutantRunOptions, MutantRunOptionsSchema, MutantRunPlan, MutantStatus, MutantStatusSchema, MutantTestCoverage, MutantTestPlan, MutatorName, MutatorName as MutatorNameValue, OpenEndLocation, OpenEndLocationSchema, Position, PositionSchema, ReportLocationFromMutant, RunMutantResult, RunOptions, RunOptionsFields, RunPlan, TestPlan };
1929
+ export { ActionableStatus, ActionableStatusSchema, CanonicalFileName, CanonicalFileName as CanonicalFileNameValue, Column, Coverage, CoverageData, CoveragePerTestId, EarlyResultPlan, EphemeralStatus, EphemeralStatusSchema, HitCount, InstrumenterContext, Line, LineStarts, Location, Mutant$1 as Mutant, MutantActivation, MutantActivationSchema, MutantCoverage, MutantCoverageSchema, MutantEarlyResultPlan, MutantFromUnknown, MutantFromUnknown as MutantFromUnknownValue, MutantId, MutantId as MutantIdValue, MutantRunOptions, MutantRunOptionsSchema, MutantRunPlan, MutantStatus, MutantStatusSchema, MutantTestCoverage, MutantTestPlan, MutatorName, MutatorName as MutatorNameValue, Offset, OpenEndLocation, Position, RememberedStatus, RememberedStatusSchema, RunMutantResult, RunOptions, RunOptionsFields, RunPlan, ScriptOrigin, Span, SurvivorStatus, SurvivorStatusSchema, TestPlan };
1760
1930
  }
1761
1931
  //#endregion
1762
1932
  export { mod_d_exports as ErrorText, mod_d_exports$1 as Format, mod_d_exports$2 as Instrument, mod_d_exports$3 as Mutant };