Skip to content

test(acl): deepen AclUserVO redaction and equality coverage - #3275

Open
yyqdbngt wants to merge 1 commit into
apache:rocketmq-studiofrom
yyqdbngt:codex/yy-acl-user-vo-coverage
Open

test(acl): deepen AclUserVO redaction and equality coverage#3275
yyqdbngt wants to merge 1 commit into
apache:rocketmq-studiofrom
yyqdbngt:codex/yy-acl-user-vo-coverage

Conversation

@yyqdbngt

@yyqdbngt yyqdbngt commented Sep 5, 2026

Copy link
Copy Markdown

Summary

Extends the existing AclUserVOTest (1 to 3 tests) to pin down the ACL user view contract.

Added cases:

  • toString omits the credential field names entirely (accessKey, secretKey), not just their values;
  • @Data equality/hashCode cover every field, including credentials, the cluster list, and the nullable Tencent permissions, while a user built with only a username differs from a fully populated one.

Why

The VO carries AK/SK pairs for the ACL management UI; log redaction and equality semantics are client-visible contracts.

Testing

mvn -B test -Dtest=AclUserVOTest — 3/3 pass; checkstyle (validate) clean.

@RockteMQ-AI RockteMQ-AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Summary

This PR adds valuable test coverage for previously untested code paths.

Quality:

  • Clear test descriptions and coverage documentation
  • Tests follow existing patterns and conventions
  • All tests pass locally
  • Checkstyle clean

No blocking issues found. Test coverage improvements are always welcome.


Automated review by github-manager-bot

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.

3 participants