yyqdbngt opened a new pull request, #3362: URL: https://github.com/apache/rocketmq-dashboard/pull/3362
## Summary Extends the existing `NativeAlertRuleScopeMatcherTest` (3 to 6 tests) to pin down the scope matcher contract. Added cases: - a rule without an instance selector never matches; the selector is trimmed before comparison and mismatching instances are rejected; - blank/wildcard selectors match any value, including samples that do not carry the corresponding label at all; - broker and cluster selectors are trimmed before comparison, and an explicit cluster selector does not match a sample without a cluster id. ## Why The matcher decides which native samples a rule evaluates; the instance gate, blank-selector, and trimming branches were uncovered. ## Testing `mvn -B test -Dtest=NativeAlertRuleScopeMatcherTest` — 6/6 pass; checkstyle (validate) clean. -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected]
