Draft
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
This adds focused parser coverage for the
--purgeflag introduced onrm.The recent
rm --purgework already had behavioral coverage for the delete path and a help-contract check for flag discoverability, but the CLI parser itself still had no direct assertion that the flag is accepted through both command entrypoints that shareRmArgs: the legacyrc rmform and the noun-firstrc object removeform.This change adds two parser tests in
crates/cli/src/commands/mod.rsthat verify both entrypoints preserve the target path and setpurge = true. The scope stays limited to the recentrmchange surface and does not touch production code.Root Cause
PR #82 wired
--purgeintoRmArgs, but parser coverage incommands::testsdid not exercise that new flag. That left a small regression window where clap wiring could drift for one entrypoint without a focused unit test catching it.Validation
make pre-commitis not defined in this checkout, so I ran the repository's required checks directly:cargo test -p rustfs-cli purge_flag --libcargo fmt --all --checkcargo clippy --workspace -- -D warningscargo test --workspace