Repository navigation
test(install): take Write-OvisCommand whole after it gained a -Core switch - #5037
Conversation
…witch #5030 changed the function's header to 'function Write-OvisCommand([switch]$Core) {', so the test's slice started at -1 and pwsh never saw the function. Every GitHub-hosted run with pwsh (fork PRs) failed Fast checks; main's self-hosted runner has no pwsh and skips the test. The slice now ends at the function's own closing brace instead of '$newInstall =', which since #5030 also takes in code that needs USERPROFILE.
|
No actionable comments were generated in the recent review. Summary
Merge Risk:
|
|
Merged through Test-only fix for main's #5030 breaking scripts/install.astra-launcher.test.ts on runners with pwsh (all fork PR Fast checks). Verified with PowerShell 7.7.0: fails on main, passes here. |
Change
#5030 changed the header of
Write-OvisCommandininstall.ps1tofunction Write-OvisCommand([switch]$Core) {.scripts/install.astra-launcher.test.tscut the function out ofinstall.ps1by its old header, so the slice started at -1 and PowerShell never saw the function:main stays green because its self-hosted runner has no
pwshand skips these two tests. Every run on a GitHub-hosted runner, which haspwsh, fails Fast checks, so fork pull requests (#5016, #5017, #5021) are all red on this one test.The test now takes the function from its header to its own closing brace. Ending at
$newInstall =as before would, since #5030, also take in code that needsUSERPROFILE.Validation
With PowerShell 7.7.0 unpacked where the test looks for it (
$TMPDIR/launcher-pwsh/pwsh):scripts/conventions.test.ts: 59 pass.