Repository navigation
Conversation
Two of these tests could not pass there. The lock test built the child's import specifier from a Windows path, which import() rejects, so the child printed nothing and the refusal it checks never appeared: the specifier is a file URL now. The omb-home describe runs the real control script under bash with a POSIX PATH, shell stubs, a unix socket at a path and the system tar, so it is POSIX only and is skipped on Windows like the other platform-specific tests here.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What and why
Two tests in the cloud-service suite cannot pass on Windows, and both of them are the test harness rather than the service.
apps/cloud-service/src/recheck.test.tsspawns a child process to prove the data-directory lock refuses a second writer. The child's specifier was built withjoin(process.cwd(), "apps/dashboard/server/data-dir-lock.ts"), which on Windows isD:\...\data-dir-lock.ts.import()rejects that, so the child died before printing anything and the assertion looking forREFUSED DataDirLockedErrorread an empty string. The child now gets apathToFileURL(...).hrefspecifier.apps/cloud-service/src/home-update.test.tshas a describe block that runs the real control script on the machine. The fixture stubs root commands as shell scripts, runs the script throughexecFileSync("bash", ...)with a POSIXPATH, presents docker as a unix socket at a path so the script's[ -S ]test finds it, and builds its package tarball with the systemtar. None of that holds on Windows:bashis not found oncePATHis replaced with the POSIX directories, a unix socket cannot be bound at a filesystem path, and GNU tar reads aC:\...argument as a remote host. Faking those away would mean rewriting the fixture around a second platform, so the block is nowdescribe.skipIf(process.platform === "win32"). That is the convention the repo already uses in its platform-specific tests, anddocs/development.mdasks for it directly: POSIX-only calls need a gated Windows equivalent rather than a silent failure.How it was checked
Before, on Windows:
pnpm exec vitest run apps/cloud-service/src/home-update.test.tsgave 4 failed and 9 passed, two of the failures timing out at the 40 s Windows limit because the docker stand-in'slisten()never settled, and two withtar (child): Cannot connect to C: resolve failed.pnpm exec vitest run apps/cloud-service/src/recheck.test.tsgave 1 failed withexpected '' to contain 'REFUSED DataDirLockedError'.After:
pnpm exec vitest run apps/cloud-service/src/home-update.test.ts apps/cloud-service/src/recheck.test.tsgives 23 passed, 4 skipped and 0 failed. The skipped four are the wholeomb-home on the machineblock; the other nine tests in that file still run, and nothing in the block changes on Linux or macOS.pnpm exec oxlint --deny-warningsover the two files reports no warnings and no errors.The guard tests around this pass as well:
scripts/testing/host-e2e.test.ts(the rule that flags tests skipped on Linux, which this skip is not),scripts/testing/comment-history.test.ts,scripts/testing/file-size-ratchet.test.tsandscripts/testing/verification-docs.test.ts.Notes for reviewers
I left the two seeded power simulations in
apps/cloud-service/src/power/alone. On a loaded Windows laptop they end withError: Test timed out in 40000ms(they run for 58 to 186 seconds against the doubled Windows timeout), and aTZ=UTCrun failed them the same way, so that is capacity on my machine rather than anything portable. They are worth a separate look if the Windows shard sees them too.Based on upstream
mainat289ccb24. No rebase was needed.