Loyal-Young opened a new pull request, #5172: URL: https://github.com/apache/rocketmq-dashboard/pull/5172
### Which Issue(s) This PR Fixes Fixes #4046. ### Brief Description Strengthen the metrics data-source query contract test so it requires omitted optional credential fields to be absent from the serialized request. Add the complementary case that verifies supplied username, password, and bearer token reach the query endpoint. Runtime code is unchanged. ### How Did You Test This Change? - `cd web && npm test -- src/api/metrics.test.ts`: 10 tests passed. - `cd web && npm run lint`: passed with 11 existing warnings outside the changed test. - `git diff --check`: passed. - `cd web && npm run build`: TypeScript compilation and Vite transformation completed, then the existing distribution-license gate failed on the `toggle-selection` checksum/source check. This is tracked separately in #5084 and affects the unchanged base branch. ### AI assistance AI assistance was used to inspect the existing test, identify that loose equality did not require credential fields to be absent, and draft the two request-contract assertions. The focused test and lint results above were checked locally. ### Checklist - [x] One coherent change; unrelated modifications are not bundled in - [x] Commit subject follows Conventional Commits - [x] Focused tests cover absent and supplied optional credentials - [x] No new source files or UI text -- 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]
