tools: test run-native.sh's argument checks, and refuse --console=-x (#580) #585
No reviewers
Labels
No labels
accessibility
bug
claimed
documentation
duplicate
enhancement
good first issue
help wanted
invalid
question
tester report
urgent
wontfix
No milestone
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
github/LakshanSivakumar--Native-Victory-macOS!585
Loading…
Reference in a new issue
No description provided.
Delete branch "github-bot/gh-581"
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?
@AnastasisKon on GitHub · 2026-11-28 10:03 UTC · original
AnastasisKon:vibe/run-native-args-tests-4f9c68→main· +85 −1 · 3 files · 1 commits · openWhat this changes
Refs #584.
run-native.sh's first job is refusing bad input clearly — no argument, two targets,--secondswithout a value or with a non-number, a value past the timer range,--consolewithout a model, a path that is not a file, and a folder whose download does not holdgame_*master.exeyet. All of those paths exist and none was tested (console-default.shcovers only the RAM-to-model rule).--console -his refused, because the next word starts with-and is therefore a switch, not a model.--console=-hwas accepted and handed to the game as the model, so a forgotten model surfaced as the game's own parser error. Both forms now answer the same way.tools/macos/tests/run-native-args.shpins every check above: the usage paths, each refused value, a path that is not a file, a folder holding nogame_*master.exe, and a folder holding a file of the wrong name. Each case asserts both the exit status (2, or 0 for--help) and the message. Every case stops before a game would be launched, so it needs no game and no build.macos-scriptsCI job, beside the other script tests.The two "no executable" cases are exactly what a partial download or the wrong folder produces, which is the most common way a first run fails.
How it was tested
/bin/bash tools/macos/tests/run-native-args.sh→run-native arguments: ok.macos-scriptstests, run asci.ymlruns them:target-directory.sh,console-default.sh,verify-target.sh,verify-msc.sh,msc-check.sh,tester-report.sh,run-summary-compare.sh,run-summary.sh --self-test,tools/corpus/compare.sh --self-test— all pass.cargo xtask policy: 399 files ok.ci.ymlparses, and the new step sits in themacos-scriptsjob.No game_*master.exe found in /Volumes/…, exit 2, nothing launched.game_scarlett_master.exe.Checklist
VICTORY_*variable and documented: none added323af7f33atob48fdb90e6@AnastasisKon on GitHub · 2026-11-28 12:26 UTC · original
Rebased onto current main (ci.yml step list conflicted with the rustup-path test step; both kept). Bash test, cargo tests, clippy (windows target, --locked, -D warnings) and cargo xtask policy all pass locally.
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.