unbridled-41 commented on PR #4953: URL: https://github.com/apache/rocketmq-dashboard/pull/4953#issuecomment-5777446144
Evidence-chain audit, re-executed from a clean worktree of this branch (`9fa8f5cd`). **Citations re-read with `grep -n` against `1ef5d860` and against this branch** `useInstanceFilter.ts:76-78` (the swallowing catch) and `:87-90` (the derived `selectedInstanceId`); `topic.tsx:474-481` (clear-and-stop) with `loadTopicPage` bailing at `:439`; `consumer.tsx:381-390`; `dlq.tsx:188-199`; `acl.tsx:128,135-136`; `message.tsx:493-497`. All present as described. The `acl.tsx`/`message.tsx` sentence was corrected in the description before this audit — it previously claimed those two render the same silent empty result, and `message.tsx` in fact shows a hint (a misleading one, not a silent one). **Pre-fix failure re-demonstrated** With all seven touched source files restored to `1ef5d860` and the new test kept: ``` FAIL src/pages/instance/__tests__/DLQPage.test.tsx > DLQ page > says so when the instance list itself failed to load TestingLibraryElementError: Unable to find an element with the text: /实例列表加载失败/. Tests 1 failed | 21 skipped (22) ``` **Commands re-run** ``` npx vitest run src/pages/instance src/components src/hooks → 18 files, 269/269 npx tsc --noEmit → clean npx eslint <the nine touched files> → 0 errors, 1 pre-existing react-refresh warning (dlq.tsx:82) ``` The full-suite run quoted in the other comment stands: 139 files / 1285 tests with 7 load-induced failures in three untouched files that pass in isolation (96/96). **Coverage statement, including what is deliberately not covered** The tested behaviour is the hook's (`instancesFailed` set on failure and cleared by the next successful load — `useInstanceFilter.test.tsx`) and the shared selector's (`InstanceSelect` renders the hint and the retry when `failed` — asserted through `DLQPage.test.tsx`). Four of the five pages' one-line prop pass-through is not asserted per page: the props are declared on each page's props type, so `tsc` fails if one is not passed, and adding four near-identical page tests for the same rendered string would assert the shared component four more times. The `message.tsx` wiring cannot be covered by its existing tests at all, because `MessagePage.test.tsx` and `MessagePageAsyncState.test.tsx` mock `useInstanceFilter` itself and return only the fields each test reads. No code or test change came out of this audit: the fix held and no branch of it is untested. -- 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]
