#193 Re-enable Windows tests as deno compile for Windows lands
Opened by stack72 · 4/30/2026
Context
PR #1259 and the preceding Windows-support PRs got the test suite green on
Windows, but ~19 tests are skipped via Deno.test({ ignore: Deno.build.os === \"windows\" }). Those skips aren't fixes — they hide real Windows
gaps in production code so we could trend toward a working deno compile
target. This issue tracks the work to re-enable each one as the underlying
production support lands.
The shape: as we make each capability Windows-aware (shell driver, docker
driver, file lock, etc.), we can drop the corresponding ignore blocks
and exercise that code path in CI.
Skipped tests, grouped by root cause
1. command/shell model is POSIX-only (1 test)
The shell model shells out via sh -c and expects POSIX semantics
(pwd, /tmp, command substitution, > redirection).
src/domain/models/command/shell/shell_model_test.ts— respects workingDir
Production work needed: add Windows execution path that uses
PowerShell or cmd /c, and translate POSIX-isms or document them as
unsupported on Windows. Probably also need a per-platform default
workingDir.
2. Docker driver bakes in sh -c and POSIX mock scripts (10 tests)
DockerExecutionDriver.buildCommandArgs appends sh, -c, <command>
to the docker invocation. The mock-script tests write #!/bin/sh
shebangs and chmod +x, neither of which exist on Windows.
src/domain/drivers/docker_execution_driver_test.ts:- request with bundle dispatches to bundle mode
- request with run dispatches to command mode
- request with both bundle and run prefers bundle
- execute success with mock script
- execute failure returns error
- timeout produces error result
- bundle mode captures resources
- bundle mode captures stderr as logs
- bundle mode failure returns error
- bundle mode invalid JSON stdout fallback
Production work needed: the bundle-mode tests just need a
Windows-compatible mock (e.g. .cmd/.ps1 instead of shell scripts).
The command-mode tests are blocked on the production driver — it
hardcodes sh -c in buildCommandArgs. Either detect the host shell
or always exec the command directly without a shell wrapper.
3. keeb_shell_model integration tests use POSIX shell (4 tests)
Same root cause as #1 — these wire up real workflow runs that pipe
through command/shell. Will unblock automatically when #1 lands.
integration/keeb_shell_model_test.ts:- command/shell model executes simple shell commands
- workflow with command/shell models and dependencies
- command/shell model with cross-model expressions
- command/shell model with self-reference expressions
4. File lock dead-process detection is POSIX-only (1 test)
isProcessDead() uses Deno.kill(pid, \"SIGCONT\") to probe liveness.
Windows has no equivalent signal probe; the function falls back to TTL.
src/infrastructure/persistence/file_lock_test.ts— stale lock from dead process is immediately acquired
Production work needed: add Windows-aware liveness check (e.g.
WMI / tasklist / opening the process handle). Lower priority — TTL
fallback works, just slower on Windows.
5. POSIX file-mode permission checks (2 tests)
NTFS doesn't honour POSIX mode bits the same way. Two vault tests exercise insecure-permission rejection on the SSH key file.
src/domain/vaults/local_encryption_vault_provider_test.ts:- file permissions / should create .enc files with 0o600 permissions
- SSH key validation / should reject SSH key with insecure permissions (0644)
Production work needed: decide what "insecure permissions" means on Windows. Options: skip the check on Windows, use NTFS ACLs via PowerShell, or document Windows as unsupported for this vault provider.
6. JSON-encoded path substring matching (1 test)
The auto-resolver integration test asserts a JSON event line includes a path substring. JSON encoders double the backslashes, so a raw substring search against a forward-slash literal misses on Windows.
integration/auto_resolver_truncated_test.ts— auto-resolver surfaces truncated error and leaves the tree untouched
Production work needed: none, this is a test-only ergonomics
issue. Switch to parsing the JSON line and asserting on
event.missing[0] after normalizing separators, then drop the
ignore.
Suggested order
- Test-only fix: #6 (just a smarter assertion)
- POSIX file mode (#5): document-and-skip-on-Windows is fine for v1
- Shell driver Windows path (#1) — unlocks #3 for free
- Docker driver shell-wrapper rework (#2)
- File lock liveness (#4) — lowest urgency
Done when
grep -r 'ignore: Deno.build.os === \"windows\"' src/ integration/
returns no matches, and the Cross Platform Builds workflow passes
without skips.
Automoved by swampadmin from https://github.com/systeminit/swamp/issues/1260
Closed
No activity in this phase yet.
Sign in to post a ripple.