Linux: compile, test and run the analysis commands + format all files #1
Loading…
Reference in a new issue
No description provided.
Delete branch "upstream-pr/1"
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?
Imported from Zettrox/ztrx. Originally posted by LazyHatGuy on 2026-11-25T01:44:25Z.
Mirror of https://github.com/fxceless/victory-fork/pull/128
What this does
Makes
cargo test --workspaceandcargo run -p victory -- configpass on aLinux host. The tree was already mostly gated behind
cfg(windows); thiscloses the last leaks, and the Windows build is untouched: every edit is an
attribute or code moved verbatim under a gate.
cargo fmt --allwas also ran so the lint job passesWhat was leaking
victory-loaderdeclared thecrashmodule (VEH handler,windows_sys)unconditionally.
victory-gpureferencedhost::read_into,texture::committedandhost_resourcefrom code that compiles everywhere. On Linux a memory valuewait now counts as met, as unmapped memory already does.
victory-hleused the Win32 modal dialog, thexmemallocator hook,lifecycle's relaunch andfiles' drive mount from ungated paths. Thedialog is dismissed and a self-relaunch parks outside Windows.
apps/victory'stranslatecommand needs the host D3D compiler: likerun, it is present on Linux and says so.Tests
Unit tests that lean on a Windows host are gated with
cfg(all(test, windows)), following the pattern the tree already uses: the loader and PEtests parse the host's own test binary as a PE image (an ELF on Linux), and
two kernel tests assume Windows path semantics. Everything else runs on both:
23 test targets, 0 failures.
Hygiene
cargo check/clippy --workspace --all-targets,plain and
--all-features. Deps that only the Windows modules use (anyhow,tracing, miniz_oxide, opus-pure, victory-core, victory-pipeline,
victory-shader) moved under the existing
cfg(windows)target sections.fetch_updatekept with#[allow(deprecated)]:try_updateis newer thanthe pinned 1.98 toolchain.
Cargo.lockunchanged;--lockedpasses.Still Windows-only
Actually running a title: it needs host D3D12 and the Windows loader. Linux
gets the build, the tests, and the file-side commands —
config,inspect,census,lib-exports,shader-info.This PR was AI assisted
Imported from Zettrox/ztrx. Originally posted by Yoshi-233 on 2026-11-25T02:49:45Z.
I tested the PR head
0f44d9fa1af7from a clean checkout on native Ubuntu 24.04.5 x86-64 with Rust 1.98.1. Both commands exited 0:I counted 292 passed, 6 ignored across Cargo's test summaries. The CLI printed its cache/data paths with the game directory unset. The shader suite contributed 170 passes and the formats suite 24. No title files or GPU were needed for these two checks.
Imported from Zettrox/ztrx. Originally posted by futurepro62 on 2026-11-25T06:38:11Z.
Windows full-suite run, to go with Yoshi-233's Ubuntu run above, which could not cover the Windows-only crates. Tested exact head
0f44d9f(on its base90b529f).Tested
rust-toolchain.toml), DXC + dxil.dll 1.9.2602.17, debug.cargo test --workspace --locked: 496 passed, 0 failed, 7 ignored (main90b529fon this machine: 496 passed, 0 failed, 7 ignored).cargo clippy --workspace --all-targets --locked -- -D warnings(the CI lint step): passed.cargo clippy --workspace --all-targets --all-features --locked -- -D warnings(the CI lint step): passed.#[test]functions in the diff.Not tested
AI use
Imported from Zettrox/ztrx. Originally posted by louisdelombaerde on 2026-11-25T10:24:40Z.
Review: APPROVED
No description provided.
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.