Skip to content

Conversation

BD103
Copy link
Member

@BD103 BD103 commented Sep 7, 2025

This was spun out from #542.

This PR is a multi-part fix to our CI and UI tests on Windows. I believe UI testing has been broken on Windows ever since I introduced it.

Why wasn't this caught earlier

Our CI was incorrectly reporting success even though tests were failing because Powershell, the default scripting language on Windows, doesn't fail-fast on an error.

We were running the tests and doc tests commands in the same CI step. Because the main cargo test command was not the final command run in that step, if it failed the job would still continue. As long as the doc tests passed, CI would be green.

In 436e8e2 I fixed this by splitting the commands into two separate steps. The alternative solution would be to switch the scripting language from Powershell to Bash.


TODO :)

@BD103 BD103 added A-Build-System Related to CI and GitHub Actions C-Bug A bug in the program S-Waiting-on-Author The author needs to make changes or address concerns before this can be merged O-Windows labels Sep 7, 2025
@BD103
Copy link
Member Author

BD103 commented Sep 19, 2025

Looks like we're hitting rust-lang/rust#99466. Since we don't run built scripts, the windows crate's lib directory isn't being added to the search path. (Here's the build.rs.) I probably need to add a special case for it.

@BD103 BD103 linked an issue Sep 25, 2025 that may be closed by this pull request
BD103 added 4 commits October 13, 2025 14:49
Powershell doesn't have a fail-fast mechanism like Bash, so when the first `cargo test` fails it isn't caught by CI on Windows. This is why the UI tests have failed on Windows for months even though CI was green.

https://docs.github.com/en/actions/reference/workflows-and-actions/workflow-syntax#exit-codes-and-error-action-preference
Using `&'a Path` causes deserialization to fail on Windows because the path contains backslashes. See <https://bd103.github.io/blog/2025-09-01-zero-copying-strings-serde> for more details.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

A-Build-System Related to CI and GitHub Actions C-Bug A bug in the program O-Windows S-Waiting-on-Author The author needs to make changes or address concerns before this can be merged

Projects

None yet

Development

Successfully merging this pull request may close these issues.

More than one libbevy.rlib was built for UI tests in Windows CI

1 participant