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.

Keep the token-file guide test aligned with native fragment links

pulse-triage[bot]9fe8fa6d1655
diff --git a/frontend-modern/src/features/docs/__tests__/agentTokenFileGuide.test.ts b/frontend-modern/src/features/docs/__tests__/agentTokenFileGuide.test.ts
index 81c40f387c..73d72364e2 100644
--- a/frontend-modern/src/features/docs/__tests__/agentTokenFileGuide.test.ts
+++ b/frontend-modern/src/features/docs/__tests__/agentTokenFileGuide.test.ts
@@ -20,8 +20,10 @@ describe('agent token-file help in the shipped Markdown renderer', () => {
const link = Array.from(article.querySelectorAll('a')).find(
(anchor) => anchor.textContent === 'token-file format guidance',
);
- expect(link?.getAttribute('href')).toBe(`/docs/UNIFIED_AGENT#${id}`);
- expect(link?.hasAttribute('data-doc-link')).toBe(true);
+ // Same-document fragments stay native; .md links alone are rewritten by
+ // resolveDocLink. The real-browser test verifies the Docs focus handler.
+ expect(link?.getAttribute('href')).toBe(`#${id}`);
+ expect(link?.hasAttribute('data-doc-link')).toBe(false);
expect(link?.hasAttribute('target')).toBe(false);
expect(article.querySelector(`#${id}`)?.textContent).toBe('Token-file format is not shell syntax');
expect(guide).toBe(