Skip to content

fix: fix tests not working on Windows - #4502

Merged
warcholjakub merged 2 commits into
VirtusLab:mainfrom
warcholjakub:fix/3428/windows-fix
Sep 28, 2026
Merged

warcholjakub merged 2 commits into
VirtusLab:mainfrom
warcholjakub:fix/3428/windows-fix

Conversation

@warcholjakub

@warcholjakub warcholjakub commented Sep 23, 2026 •

Copy link
Copy Markdown
Collaborator

Fixes #3428

So the tests ran scalafix, and since it couldn't find any rules it exited with sys.exit(256). On macOS and Linux exit code has 8 bits and 256 is "translated" into 0 (hence the lack of error). On Windows the error code has 32 bits, so it doesn't happen and the tests result in an error.

Checklist

  • tested the solution locally and it works
  • ran the code formatter (scala-cli fmt .)
  • ran scalafix (./mill -i __.fix)
  • ran reference docs auto-generation (./mill -i 'generate-reference-doc[]'.run)

How much have your relied on LLM-based tools in this contribution?

Moderately

How was the solution tested?

CI works

@warcholjakub warcholjakub changed the title [WIP] fix: fix tests not working on Windows fix: fix tests not working on Windows Sep 24, 2026
@warcholjakub

Copy link
Copy Markdown
Collaborator Author

Also, I guess when we introduce the feature mentioned in #3330 this fix wouldn't be needed.

@Gedochao

Copy link
Copy Markdown
Contributor

Also, I guess when we introduce the feature mentioned in #3330 this fix wouldn't be needed.

I mean, a user could always explicitly try to run no rules at all...

@warcholjakub

Copy link
Copy Markdown
Collaborator Author

Also, I guess when we introduce the feature mentioned in #3330 this fix wouldn't be needed.

I mean, a user could always explicitly try to run no rules at all...

True

@warcholjakub
warcholjakub merged commit da8fa11 into VirtusLab:main Sep 28, 2026
113 of 125 checks passed
@warcholjakub
warcholjakub deleted the fix/3428/windows-fix branch September 28, 2026 09:18
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Make fix sub-command test suite pass on Windows

2 participants