Skip to content

armgit / Pulse

Public Imported from GitHub
0

Real-time monitoring dashboard for Proxmox VE, PBS, Docker, Kubernetes, TrueNAS and vSphere. Self-hosted, with alerts for failed backups, full disks, unhealthy containers and offline nodes.

Check the reporting link without scanning every link for visibility

pulse-triage[bot]5040616ecbcc
diff --git a/frontend-modern/src/utils/__tests__/recoveryHelp.test.ts b/frontend-modern/src/utils/__tests__/recoveryHelp.test.ts
index 5344d8675d..134f6a210f 100644
--- a/frontend-modern/src/utils/__tests__/recoveryHelp.test.ts
+++ b/frontend-modern/src/utils/__tests__/recoveryHelp.test.ts
@@ -122,9 +122,14 @@ describe('recovery help', () => {
it('resolves safe issue reporting to the actual troubleshooting heading', () => {
const rendered = document.createElement('article');
rendered.innerHTML = renderDocMarkdown(guide, 'RECOVERY');
- const link = within(rendered).getByRole<HTMLAnchorElement>('link', {
- name: 'safe issue reporting',
+ // This detached article tests a link's identity and destination, not the
+ // visibility of every link in the guide. Check the chosen link's accessible
+ // name directly instead of scanning all ancestors' styles for every link.
+ const link = within(rendered).getByText<HTMLAnchorElement>('safe issue reporting', {
+ selector: 'a',
+ exact: true,
});
+ expect(link).toHaveAccessibleName('safe issue reporting');
expect(link.textContent).toBe('safe issue reporting');
expect(link?.hasAttribute('data-doc-link')).toBe(true);
const destination = new URL(link!.getAttribute('href')!, 'https://pulse.example.invalid');