✔ a first launch clones the root at its branch, with the root's path as origin (31.009289ms)
✔ the clone is not at its place until git clone has finished (22.134238ms)
✔ a later launch fast-forwards a clean clone after a commit to the root, then finds it current (77.013225ms)
✔ a clone ahead of the root keeps its commits and counts as current (38.21811ms)
▶ a dirty clone, one on another branch and one diverged are kept as they are
  ✔ a modified file (29.856011ms)
  ✔ an untracked file (34.94121ms)
  ✔ a staged file (30.884726ms)
  ✔ another branch (29.248961ms)
  ✔ a detached HEAD (30.957665ms)
  ✔ a diverged branch (47.687192ms)
✔ a dirty clone, one on another branch and one diverged are kept as they are (204.869849ms)
▶ a clone the session rigged is kept, and git runs nothing and writes nothing outside it
  ✔ core.fsmonitor (39.328244ms)
  ✔ core.hooksPath (33.575753ms)
  ✔ a hook file (31.387088ms)
  ✔ include.path (33.776724ms)
  ✔ includeIf (34.92023ms)
  ✔ a filter driver (34.849438ms)
  ✔ origin moved (32.429425ms)
  ✔ a second origin url (36.548842ms)
  ✔ the origin url twice, both the root (36.866848ms)
  ✔ an ext:: origin (33.998885ms)
  ✔ a branch tracking another remote (36.343653ms)
  ✔ a branch merging a tag (31.862866ms)
  ✔ a fetch line onto local branches (31.510361ms)
  ✔ no origin (30.794284ms)
  ✔ a config file over the size cap (28.279134ms)
  ✔ config a symlink to /dev/zero (28.855581ms)
  ✔ the clone a symlink to the bait (28.774004ms)
  ✔ the clone a file (29.492846ms)
  ✔ the clone a plain directory (30.554214ms)
  ✔ .git a gitdir: file (27.053575ms)
  ✔ .git a symlink (27.662521ms)
  ✔ .git/logs a symlink (28.000587ms)
  ✔ .git/refs/heads a symlink (28.485767ms)
  ✔ .git/objects a symlink (28.631499ms)
  ✔ a reflog hard-linked to a file outside (28.753692ms)
  ✔ HEAD a fifo (29.740186ms)
  ✔ a commondir file (28.477266ms)
  ✔ an alternates file (27.810389ms)
  ✔ a gitlink staged, no .gitmodules (40.450879ms)
  ✔ a gitlink and .gitmodules staged (42.326092ms)
  ✔ a gitlink to a repository with its own gitlink (48.153293ms)
  ✔ a gitlink and .gitmodules committed (44.368178ms)
  ✔ a gitlink and submodule.active in config (41.946647ms)
  ✔ a .git/modules with no gitlink (32.589411ms)
✔ a clone the session rigged is kept, and git runs nothing and writes nothing outside it (1133.692328ms)
▶ a root that can't be cloned refuses with the project id and leaves nothing behind
  ✔ missing (10.176352ms)
  ✔ not a repository (9.713445ms)
  ✔ a plain directory inside another repository (13.948076ms)
  ✔ unreadable (9.682264ms)
  ✔ on no branch (11.804264ms)
  ✔ missing an object (14.517219ms)
✔ a root that can't be cloned refuses with the project id and leaves nothing behind (70.665926ms)
✔ a clone whose root is on no branch, or gone, is kept and named (26.87909ms)
✔ no credential or forge remote of the root reaches a clone (48.940445ms)
✔ every project in the business file gets its own clone at its own branch (37.533445ms)
✔ RUNNER_FILES is exactly what the runner and the harness sources it starts import (1.534689ms)
✔ sandboxProblem names a missing bwrap and a bwrap that fails (7.99565ms)
✔ every bind says why; the bundle and session file stay read-only over the run directory (1.266943ms)
✔ the host's git socket is bound only when given, read-only and before the writable binds (0.712189ms)
✔ a confined session's shell reaches its own workspace and run directory and nothing of the founder's or another session's (1806.484636ms)
✔ a bind that exposes a stand-in, or a missing workspace bind, fails the matching check (2536.910368ms)
✔ resolveSeat: by name under --repo resolves the repo layout (1.302687ms)
✔ resolveSeat: by path resolves the fleet layout (0.325584ms)
✔ resolveSeat: refusals for missing dir, missing launch.sh, non-executable launch.sh, invalid name, and unknown layout (0.708136ms)
✔ tmuxContext: outside tmux, default socket, custom socket, and exec failure (0.652047ms)
✔ makeRegistration produces a record that validates; each shape violation throws SeatError (0.795094ms)
✔ writeRegistration/readRegistration: round trip, permissions, absence, and malformed records (1.320273ms)
✔ updateTask: changes task, taskSetBy and updatedAt only, and refuses appropriately (1.15069ms)
✔ CLI launch: registers, execs the fake launch script, and passes args through (32.925776ms)
✔ CLI launch: --harness lands in the record (36.488142ms)
✔ CLI launch: the launch script's own exit code passes through (36.966874ms)
✔ CLI launch: relaunching a seat rewrites the one registration record (62.797984ms)
✔ CLI launch: omitting --task records an empty string, not null (32.286059ms)
✔ CLI seat task: updates only the task after a launch, and refuses on an unlaunched seat (87.007883ms)
✔ CLI refusals: no args, unknown flag, missing config, already-registered env, and exec failure (146.304003ms)
✔ samePath: equal paths, symlinked dirs, distinct dirs, and non-strings (0.416578ms)
✔ resolveSetBy: explicit --by wins over the environment; absent or empty environment gives unknown; invalid explicit or environment values refuse with exit 4 (0.589241ms)
✔ validateRegistration/readRegistration: taskSetBy is optional; a record without it (written before #1511) still loads unchanged; an invalid one is refused; the version does not change (1.301548ms)
✔ updateTask: records setBy, preserves startedAt and every unrelated field, upgrades an old record in place only when the task is set, and replaces a previous attribution (0.943349ms)
✔ CLI seat task: --by beats MOSAIC_AGENT_NAME, the environment beats nothing, empty environment is unknown, invalid --by or environment refuses with exit 4 and leaves the record byte for byte (284.457182ms)
✔ family: exactly one launch.max key in the model name, else null (0.667998ms)
✔ sessionEnv passes only the allowlist, the repo's bin on PATH, and the run id (0.656405ms)
✔ sessionExit gives a runner's signal death back as the signal; a session credential is one whole set of nonempty variables (0.244297ms)
✔ newRun: short ids, 0700 directories, and a refusal when the socket path won't fit (1.410005ms)
✔ session file and launch log: 0600, the session file written once (1.030812ms)
✔ endReason maps the runner's exit codes; a signal is killed (0.126822ms)
✔ Registry mirrors to sessions.json; readSessions marks live entries; bad files refuse (1.22466ms)
✔ stopSession refuses an unknown run, reports a stale one, and won't signal a pid that isn't a runner (0.936785ms)
✔ a session runs in its sandbox as pid 1 of its namespace, claims, answers, and stops on mosaic stop (243.294283ms)
✔ workRef and validBranch take only what a ref name can hold (1.157726ms)
✔ a push lands as the task's work ref, a fast-forward lands after it, and main is the root's (115.369255ms)
✔ a rewritten branch refuses non-fast-forward and the work ref stays (89.207373ms)
✔ a branch with no history in common with main refuses unrelated-history (48.019126ms)
✔ a bundle that needs commits the working repository lacks refuses missing-prerequisite (40.221798ms)
✔ main is fetched from the root again before each push, so a clone of a newer root pushes (105.784966ms)
✔ a root moved back after the clone leaves the push's base unknown: missing-prerequisite (64.985756ms)
✔ a commit with a broken object refuses invalid-bundle, and only because fsck is on (62.769494ms)
✔ only a v2 bundle with the named branch is read (48.488196ms)
✔ a branch named main, or named for another task, moves only this task's work ref (83.523863ms)
✔ a record that throws moves the work ref back, or removes a new one (107.62908ms)
✔ a work ref that can't go back refuses rollback-failed, naming the ref and the commit (321.245924ms)
✔ a root that can't be read refuses root-unreadable (27.536972ms)
✔ a git past its time gets SIGTERM, leaves no ref lock, and the next push lands (2143.732207ms)
✔ a git that ignores SIGTERM gets SIGKILL once the grace period is over (1038.317552ms)
✔ a working repository path that isn't a directory refuses (35.347574ms)
✔ review bundles a pushed commit as refs/mosaic/review, leaving out what the reviewer has (109.364368ms)
✔ review of a project with no working repository refuses unknown-commit (15.067683ms)
✔ the runner's git tools hold the host's limits and branch rule (1.208977ms)
ℹ tests 109
ℹ suites 0
ℹ pass 109
ℹ fail 0
ℹ cancelled 0
ℹ skipped 0
ℹ todo 0
ℹ duration_ms 4520.958598
