Repository navigation
test(platform): install-layout assertions read the path on any platform - #30
Merged
Merged
Conversation
Windows CI checks the tree out with CRLF-free but drive-lettered paths: uri.path is '/d:/a/...' there, so Directory(uri.path + '/lib') failed with errno 123, and toFilePath() separates with '\', so the endsWith 'state/default' assertion could never hold. Directory.path and Uri.path are the platform-independent spellings; both assertions keep their intent.
r'\\' is a two-character string, so the replaceAll matched nothing on Windows: paths kept their backslashes, lib/src/io/ was not found, and every native adapter was reported as outside its own directory. Invisible on Linux, and invisible on Windows until the walk that reached this line was fixed. The pattern is '\\'.
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.
Fixes two Windows-only failures in the
windows-latestCI job (seen on develop run 38029954030):Directory(_packageRoot().uri.path + '/lib')— on Windowsuri.pathis/d:/a/..., leading slash before the drive letter, so the recursive walk threw FileSystemException errno 123. Now usesDirectory.path, which is the native spelling on every platform.paths.resolve('state/default').toFilePath()assertedendsWith('state/default')—toFilePath()separates with\\on Windows. Now asserts on the returnedUri's.path, which is always/-separated, keeping the assertion's intent (the join landed beneath the root).Verified:
melos run analyze,melos run formatand thealteri_one_platformtest suite pass locally (44/44). The Windows behaviour itself cannot be exercised on this Linux container; the CI Windows job is the real gate. Notemelos exec --fail-fastcancels the remaining packages after the first failure, soalteri_one_protocoland the root package tests have not actually run on Windows yet — further Windows-only defects may surface in the same job.Refs #29