app: pin inspect's dll_flags rendering with unit tests #502

Open
opened 2026-11-27 22:22:26 +00:00 by AnastasisKon · 4 comments
AnastasisKon commented 2026-11-27 22:22:26 +00:00 (Migrated from github.com)
Contributor

Imported from LakshanSivakumar/Native-Victory-macOS. Originally posted by AnastasisKon on 2026-11-27T22:22:26Z.


What

apps/victory/src/inspect.rs's dll_flags(v: u16) renders a PE's DllCharacteristics as the parenthesised names victory inspect prints. It is pure and untested; a flags-table edit could silently drop or reorder a name.

What this changes

Test-only: unit tests pin that no flags render empty, each known flag renders its name, several flags render in the table's fixed order (not bit order), and unknown bits are ignored.

How it was tested

  • cargo test -p victory (new tests in apps/victory/src/inspect.rs)
  • cargo clippy --workspace --all-targets --locked --target x86_64-pc-windows-gnullvm -- -D warnings
  • cargo xtask policy
  • Game run: not needed (test-only).
<!-- greyfinch-sync:LakshanSivakumar/Native-Victory-macOS:issue:6655390438 --> Imported from [LakshanSivakumar/Native-Victory-macOS](https://github.com/LakshanSivakumar/Native-Victory-macOS/issues/502). Originally posted by [AnastasisKon](https://github.com/AnastasisKon) on 2026-11-27T22:22:26Z. --- ## What `apps/victory/src/inspect.rs`'s `dll_flags(v: u16)` renders a PE's `DllCharacteristics` as the parenthesised names `victory inspect` prints. It is pure and untested; a flags-table edit could silently drop or reorder a name. ## What this changes Test-only: unit tests pin that no flags render empty, each known flag renders its name, several flags render in the table's fixed order (not bit order), and unknown bits are ignored. ## How it was tested - `cargo test -p victory` (new tests in `apps/victory/src/inspect.rs`) - `cargo clippy --workspace --all-targets --locked --target x86_64-pc-windows-gnullvm -- -D warnings` - `cargo xtask policy` - Game run: not needed (test-only).
AnastasisKon commented 2026-11-27 22:22:28 +00:00 (Migrated from github.com)
Author
Contributor

Imported from LakshanSivakumar/Native-Victory-macOS. Originally posted by AnastasisKon on 2026-11-27T22:22:28Z.


/claim

<!-- greyfinch-sync:LakshanSivakumar/Native-Victory-macOS:comment:7229273818 --> Imported from [LakshanSivakumar/Native-Victory-macOS](https://github.com/LakshanSivakumar/Native-Victory-macOS/issues/502#issuecomment-7229273818). Originally posted by [AnastasisKon](https://github.com/AnastasisKon) on 2026-11-27T22:22:28Z. --- /claim
github-actions[bot] commented 2026-11-27 22:22:39 +00:00 (Migrated from github.com)
Author
Contributor

Imported from LakshanSivakumar/Native-Victory-macOS. Originally posted by github-actions[bot] on 2026-11-27T22:22:39Z.


Claimed by @AnastasisKon. Open a draft pull request with Refs #502 in its description within 24 hours, or the claim expires.

<!-- greyfinch-sync:LakshanSivakumar/Native-Victory-macOS:comment:7229276482 --> Imported from [LakshanSivakumar/Native-Victory-macOS](https://github.com/LakshanSivakumar/Native-Victory-macOS/issues/502#issuecomment-7229276482). Originally posted by [github-actions[bot]](https://github.com/apps/github-actions) on 2026-11-27T22:22:39Z. --- Claimed by @AnastasisKon. Open a draft pull request with `Refs #502` in its description within 24 hours, or the claim expires.
AnastasisKon commented 2026-11-28 12:47:39 +00:00 (Migrated from github.com)
Author
Contributor

Imported from LakshanSivakumar/Native-Victory-macOS. Originally posted by AnastasisKon on 2026-11-28T12:47:39Z.


/release - done: PR #503 is merged upstream (2026-11-28T01:57Z). Same reason as #504: the work is on upstream main, the claim is just stale.

<!-- greyfinch-sync:LakshanSivakumar/Native-Victory-macOS:comment:7239470645 --> Imported from [LakshanSivakumar/Native-Victory-macOS](https://github.com/LakshanSivakumar/Native-Victory-macOS/issues/502#issuecomment-7239470645). Originally posted by [AnastasisKon](https://github.com/AnastasisKon) on 2026-11-28T12:47:39Z. --- /release - done: PR #503 is merged upstream (2026-11-28T01:57Z). Same reason as #504: the work is on upstream `main`, the claim is just stale.
github-actions[bot] commented 2026-11-28 12:47:47 +00:00 (Migrated from github.com)
Author
Contributor

Imported from LakshanSivakumar/Native-Victory-macOS. Originally posted by github-actions[bot] on 2026-11-28T12:47:47Z.


Released. This issue is free to claim.

<!-- greyfinch-sync:LakshanSivakumar/Native-Victory-macOS:comment:7239472230 --> Imported from [LakshanSivakumar/Native-Victory-macOS](https://github.com/LakshanSivakumar/Native-Victory-macOS/issues/502#issuecomment-7239472230). Originally posted by [github-actions[bot]](https://github.com/apps/github-actions) on 2026-11-28T12:47:47Z. --- Released. This issue is free to claim.
Sign in to join this conversation.
No labels
No milestone
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Reference
LakshanSivakumar/Native-Victory-macOS#502
No description provided.