supercov 4.29.9 → 4.29.10
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/docs/mutation.md
CHANGED
|
@@ -210,6 +210,11 @@ npx supercov mutants --diff origin/main --format markdown --output mutants.md
|
|
|
210
210
|
it has the mutation score and lists the survivors. `supercov mutants` takes
|
|
211
211
|
`--format markdown` and `--output <file>` too, and writes its own answer
|
|
212
212
|
that way.
|
|
213
|
+
- A survivor that only changes a log line (its change lies wholly inside the
|
|
214
|
+
arguments of `console.*`, or of a method named `info`, `warn`, `error`,
|
|
215
|
+
`debug`, `trace` or `log`) is still `survived`, but marked `(only changes a
|
|
216
|
+
log line)` (`logOnly` in JSON) and counted on its own: `survived 185 (109
|
|
217
|
+
only change a log line)`. Triage can set those aside.
|
|
213
218
|
- `--fail-on` exits `1` when a mutant asked about has one of the statuses
|
|
214
219
|
given. On `runs latest mutants` they are weak statuses, from the run alone;
|
|
215
220
|
on `supercov mutants` and `mutants test` they are verdicts: `survived`,
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "supercov",
|
|
3
|
-
"version": "4.29.
|
|
3
|
+
"version": "4.29.10",
|
|
4
4
|
"description": "Coverage, security and code quality for coding agents",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"coverage",
|
|
@@ -125,14 +125,14 @@
|
|
|
125
125
|
"test:windows-tls": "node scripts/windows-tls-test.mjs"
|
|
126
126
|
},
|
|
127
127
|
"optionalDependencies": {
|
|
128
|
-
"@supercov/cli-darwin-arm64": "4.29.
|
|
129
|
-
"@supercov/cli-darwin-x64": "4.29.
|
|
130
|
-
"@supercov/cli-linux-arm64-gnu": "4.29.
|
|
131
|
-
"@supercov/cli-linux-arm64-musl": "4.29.
|
|
132
|
-
"@supercov/cli-linux-x64-gnu": "4.29.
|
|
133
|
-
"@supercov/cli-linux-x64-musl": "4.29.
|
|
134
|
-
"@supercov/cli-win32-arm64": "4.29.
|
|
135
|
-
"@supercov/cli-win32-x64": "4.29.
|
|
128
|
+
"@supercov/cli-darwin-arm64": "4.29.10",
|
|
129
|
+
"@supercov/cli-darwin-x64": "4.29.10",
|
|
130
|
+
"@supercov/cli-linux-arm64-gnu": "4.29.10",
|
|
131
|
+
"@supercov/cli-linux-arm64-musl": "4.29.10",
|
|
132
|
+
"@supercov/cli-linux-x64-gnu": "4.29.10",
|
|
133
|
+
"@supercov/cli-linux-x64-musl": "4.29.10",
|
|
134
|
+
"@supercov/cli-win32-arm64": "4.29.10",
|
|
135
|
+
"@supercov/cli-win32-x64": "4.29.10"
|
|
136
136
|
},
|
|
137
137
|
"peerDependencies": {
|
|
138
138
|
"@playwright/test": ">=1.55.0",
|
|
@@ -31,7 +31,8 @@
|
|
|
31
31
|
// with every request (header, cookies, child processes) and the page through
|
|
32
32
|
// an init script. A mutant the server must start with (its code ran in work
|
|
33
33
|
// no request named, or is a server module's top level, or ran for a request
|
|
34
|
-
// that named no test
|
|
34
|
+
// that named no test, or its switch is evaluated as a server module loads)
|
|
35
|
+
// is run alone afterwards, in an invocation of its own
|
|
35
36
|
// with SUPERCOV_ACTIVE_MUTANT set, which the engine starts for each `restart`
|
|
36
37
|
// record the judge writes (javascript_run.rs). So do a kill (or a timeout)
|
|
37
38
|
// that ran beside another mutant's attempt or whose control failed (one test
|
|
@@ -384,8 +385,13 @@ function buildPass(pass, root, config) {
|
|
|
384
385
|
const infected = [...new Set(own.filter((test) => test.infected).map((test) => test.id))];
|
|
385
386
|
const ordered = [...new Set(own.map((test) => test.id))];
|
|
386
387
|
const switched = `${mutant.file}#${found.index}`;
|
|
387
|
-
|
|
388
|
-
|
|
388
|
+
// A switch the copy evaluates as its module loads (an arrow
|
|
389
|
+
// mutated whole at a module's top level), in a module a server
|
|
390
|
+
// ran: the server made the original once, for every request,
|
|
391
|
+
// whatever mutant a request names.
|
|
392
|
+
const serverWide = mutant.serverWide ?? (found.entry.static && mutant.serverRan ? "module-level" : undefined);
|
|
393
|
+
if (serverWide) {
|
|
394
|
+
restarts.push({ id: mutant.id, mutant: switched, tests: ordered, reason: serverWide });
|
|
389
395
|
continue;
|
|
390
396
|
}
|
|
391
397
|
mutants.push({ id: mutant.id, mutant: switched, tests: ordered, infected });
|