mirror of
https://github.com/profullstack/logicsrc.git
synced 2026-10-01 20:33:50 +00:00
spec-discovery test: accept a landing-page link in llms.txt, still require the docs URL
Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01RZV4zJ2pDZLNN3kE5jFCmV
This commit is contained in:
parent
68f3151699
commit
b2c23f724b
1 changed files with 6 additions and 1 deletions
|
|
@ -20,7 +20,12 @@ describe.each([
|
|||
});
|
||||
|
||||
it("includes a reachable docs URL and the full contract in the LLM feeds", async () => {
|
||||
expect(await llms().text()).toMatch(new RegExp(`\\[${name}\\]\\(https://[^)]+/docs/${slug}\\)`));
|
||||
// A spec with a landing page is linked there and cites its docs URL after
|
||||
// it; a docs-only spec is linked straight to /docs/<slug>. Both must name
|
||||
// the docs URL somewhere on the line.
|
||||
const text = await llms().text();
|
||||
expect(text).toMatch(new RegExp(`\\[${name}\\]\\(https://[^)]+/(docs/)?${slug}\\)`));
|
||||
expect(text).toContain(`/docs/${slug}`);
|
||||
expect(await llmsFull().text()).toContain(readDoc(slug)!.trim());
|
||||
});
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue