supercov 4.24.0 → 4.24.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.
@@ -715,8 +715,11 @@ image, as `.:/workspace` in a compose file does: Supercov runs the command
715
715
  in the copy, so the mount is of the copy. It gets the run's settings with
716
716
  each path into the copy moved to where the container sees it, and the
717
717
  project's `node_modules`, which the copy's packages link to, mounted
718
- read-only at its own path. A mount of one directory of the project
719
- (`./src:/app/src`) is not the copy, and is left alone.
718
+ read-only at its own path. The copy's `.supercov`, where the run's evidence
719
+ is written, is mounted writable where the container sees it, so a copy
720
+ mounted read-only (`.:/workspace:ro`) is measured as well. A mount of one
721
+ directory of the project (`./src:/app/src`) is not the copy, and is left
722
+ alone.
720
723
 
721
724
  The tests can run in such a container too. A command `docker exec` (or
722
725
  `docker compose exec`) starts in it, `npx playwright test` say, gets the
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "supercov",
3
- "version": "4.24.0",
3
+ "version": "4.24.1",
4
4
  "description": "Coverage, security and code quality for coding agents",
5
5
  "keywords": [
6
6
  "coverage",
@@ -122,14 +122,14 @@
122
122
  "test:windows-tls": "node scripts/windows-tls-test.mjs"
123
123
  },
124
124
  "optionalDependencies": {
125
- "@supercov/cli-darwin-arm64": "4.24.0",
126
- "@supercov/cli-darwin-x64": "4.24.0",
127
- "@supercov/cli-linux-arm64-gnu": "4.24.0",
128
- "@supercov/cli-linux-arm64-musl": "4.24.0",
129
- "@supercov/cli-linux-x64-gnu": "4.24.0",
130
- "@supercov/cli-linux-x64-musl": "4.24.0",
131
- "@supercov/cli-win32-arm64": "4.24.0",
132
- "@supercov/cli-win32-x64": "4.24.0"
125
+ "@supercov/cli-darwin-arm64": "4.24.1",
126
+ "@supercov/cli-darwin-x64": "4.24.1",
127
+ "@supercov/cli-linux-arm64-gnu": "4.24.1",
128
+ "@supercov/cli-linux-arm64-musl": "4.24.1",
129
+ "@supercov/cli-linux-x64-gnu": "4.24.1",
130
+ "@supercov/cli-linux-x64-musl": "4.24.1",
131
+ "@supercov/cli-win32-arm64": "4.24.1",
132
+ "@supercov/cli-win32-x64": "4.24.1"
133
133
  },
134
134
  "peerDependencies": {
135
135
  "@playwright/test": ">=1.55.0",
@@ -625,6 +625,7 @@ function flushBackgroundAppends(fs) {
625
625
  // all.
626
626
  function makeEvidenceDirectory(fs, directory) {
627
627
  const first = fs.mkdirSync(directory, { recursive: true });
628
+ markContainerWriting(fs);
628
629
  if (!first || typeof process === "undefined" || !process.env || process.env.SUPERCOV_CONTAINER !== "1")
629
630
  return;
630
631
  let current = first;
@@ -640,6 +641,20 @@ function makeEvidenceDirectory(fs, directory) {
640
641
  }
641
642
  }
642
643
  }
644
+ // A container Supercov's relay measured says, once, that its evidence could
645
+ // be written: one that never does -- a server stopped at its first probe, a
646
+ // directory it may not write -- is named when the run ends.
647
+ function markContainerWriting(fs) {
648
+ const mark = typeof process !== "undefined" && process.env ? process.env.SUPERCOV_CONTAINER_MARK : void 0;
649
+ if (!mark || state.containerMarked)
650
+ return;
651
+ state.containerMarked = true;
652
+ try {
653
+ fs.mkdirSync(mark.slice(0, mark.lastIndexOf("/")), { recursive: true });
654
+ fs.writeFileSync(mark, "");
655
+ } catch (e) {
656
+ }
657
+ }
643
658
  function writeBackgroundLines(fs, runId, payload) {
644
659
  var _a8;
645
660
  const directory = backgroundEvidenceDirectory(runId);