Skip to content

test(cli): cover cors parser alias and force#134

Draft
overtrue wants to merge 1 commit intomainfrom
codex/test-gap-detection-20260416220055
Draft

test(cli): cover cors parser alias and force#134
overtrue wants to merge 1 commit intomainfrom
codex/test-gap-detection-20260416220055

Conversation

@overtrue
Copy link
Copy Markdown
Contributor

Summary

Adds focused parser coverage for recent bucket CORS command surfaces.

The recent CORS command work supports both nested bucket commands and the deprecated top-level rc cors form. Existing tests covered several nested command paths, but they did not assert that the top-level get alias resolves to the list operation or that the CORS --force flag is preserved through nested list parsing.

This PR adds two narrow CLI parser tests in crates/cli/src/commands/mod.rs:

  • rc cors get local/my-bucket maps to CorsCommands::List.
  • rc bucket cors list local/my-bucket --force keeps force = true.

No runtime CORS behavior or S3 request code is changed.

Validation

  • cargo fmt --all --check
  • cargo test -p rustfs-cli cors
  • cargo clippy --workspace -- -D warnings
  • cargo test --workspace

Note: make pre-commit was requested, but this checkout has no Makefile and make reports No rule to make target pre-commit.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant