WIP: test(builder): two builder checks that fail only on Windows pass there: their fixtures name Windows' programs and whole paths #2834
No reviewers
Labels
No labels
area/accessibility
area/audio
area/input
area/install
area/menu
area/mods
area/renderer
area/saves
area/tooling
area/upscaling
beanstalk: approved
beanstalk: failed
beanstalk: needs approval
beanstalk: running
beanstalk: tested
ci: approved
good first issue
gpu/amd
gpu/igpu
gpu/intel
gpu/nvidia
help wanted
kind
bug
kind
chore
kind
docs
kind
feature
kind
performance
kind
question
needs measurements
platform/linux
platform/macos
platform/steam-deck
platform/windows
preview
priority
critical
priority
high
priority
low
regression
risk
high
risk
low
risk
medium
status
blocked
status
confirmed
status
duplicate
status
invalid
status
needs-info
status
wontfix
ci: approved
No milestone
No project
No assignees
2 participants
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
MagicBeanDev/Longshot!2834
Loading…
Reference in a new issue
No description provided.
Delete branch "llun/Longshot:fix/mod-api-win-builder-tests"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Summary
For #2822 (into
mod-api). Two of the builder's Rust checks fail onmod-apionly on Windows (cargo test --target x86_64-pc-windows-gnullvm). Their fixtures assume Linux; the code they test is right on both systems. Tests only:mod-api, Windowsbuild-compile'stoolchain::tests::the_builder_s_llvm_comes_before_emsdk_and_the_pathLONGSHOT_LLVMholdsclangandld.lld, whichfind()looks for asclang.exeandld.lld.exeon Windows, so it found thePATH's clang (left: …\llvm-mingw\bin\clang.exe)std::env::consts::EXE_SUFFIXbuild-core'sdriver_caches::tests::the_caches_are_longshots_own_unless_one_is_namedplan()takesHOMEandXDG_CACHE_HOMEonly when whole, and/his not whole on Windows (left: [])C:on Windows,/on Linux as beforeRead first: the two tests, in
builder/crates/build-compile/src/toolchain.rsandbuilder/crates/build-core/src/driver_caches.rs.Testing
Tested: Windows 11.
cargo test -p build-core -p build-compile --target x86_64-pc-windows-gnullvmwith llvm-mingw: both checks fail onmod-api@eaf4a48bas the table says, and pass here. On Linux (WSL Ubuntu 24.04, Rust 1.99.1) both pass here, as before. Tests only, so there's no game run: the game runs none of it.cargo fmt --checkon both crates andmise run lintpass.Still failing on Windows on
mod-api, unchanged by this PR:build-core'sfiles_windows::tests::the_cache_takes_files_folders_renames_and_removes: the broker's write-only open and made folder, #2726's bug, commented there.build-compile'stests/compile_link.rsan_unchanged_rebuild_compiles_nothing_and_a_change_compiles_what_it_touches(and links nothing): an unchanged rebuild links again on Windows: its fixture's program and a bug in the link's key, fixed in #2835.Still to test: None.
Measurements
Nothing to measure: two tests' fixtures.
Risks
The sandbox: not touched. These are two tests' fixtures, and the sandbox's checks are not weakened.
None for players: only
#[cfg(test)]code changes, and neither check is weakened (Linux runs exactly what it ran). A revert is enough.Checklist
Ready for review
mod-api(#2822's head); the title is a Conventional Commit.mise run testpasses (any failure that also fails onmainis named). (These two pass. The two named above still fail on Windows onmod-api.mod-api's whole suite has other failures on Windows that this PR doesn't change.)main, or Measurements says why there is nothing to measure.third_party/untouched; nothing GPL-incompatible.When it applies
tests/that reads changed source is updated, not weakened.Assisted-by:/Co-Authored-By:trailers.Ready to merge
main, measured again or a comment says why the numbers still hold.🤖 Generated with Claude Code
Possibly related, for context:
The compile_link failure named in Testing is explained and fixed in #2835: its fixture linked prog (Windows writes prog.exe), and link_inputs took a Windows path's drive colon for an option's separator, so a link's output went into its own key and every link ran again.
Risks now says how this change stands with the sandbox (what it touches, and why the confined game reaches nothing more).
7d24c41c12fc262bd7e8Rebased onto mod-api's newest (
4cc50ca1: main's newest merged in), with no conflict; this PR's own checks were run again on the rebased head and pass as before. The merge touched none of this PR's files (#2827: only a comment in host/hos_main.c, far from its change), so the measurements and runs above hold; the After commit is the rebased head.fc262bd7e811f066e714Rebased onto
mod-api@816d2354(#2837, headless shots of the mods' UI), now11f066e7. No conflict, and the diff is the same as before (samegit patch-id). #2837 touches none of this PR's files.11f066e7146c1035304a6c1035304a78e48176a8Rebased onto
mod-api@c5e5b676: it was re-squashed onto main @46291934(#2833) twice today (cdbb8551, thenc5e5b676), which made this PR show main's and the whole mod API's diff. Now78e48176, the same diff as before (samegit patch-id), no conflict. main's #2833 changedtoolchain.rs, so I rancargo test -p build-compile -p build-coreagain on the rebased head (Windows, llvm-mingw): the same as before, with onlycompile_link'san_unchanged_rebuild_compiles_nothing_and_a_change_compiles_what_it_touchesfailing, as onmod-api(#2835 fixes it).View command line instructions
Checkout
From your project repository, check out a new branch and test the changes.Merge
Merge the changes and update on Forgejo.Warning: The "Autodetect manual merge" setting is not enabled for this repository, you will have to mark this pull request as manually merged afterwards.