Browser tests and README: tops found by title, addresses named from titles
The browser tests find sections by their titles from the library root and open the starter trees at /doc/<name made from the title>; a renamed document's address follows its title. The README's addresses, text-format targets and /api/docs say the same. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_014yB6q4BHMwptTX3YFtkRab
This commit is contained in:
1 parent
44d2e437eb
commit
6c97772ec9
11 files changed
+68
-66
No files matched your search
+2
-2
@@ -3,7 +3,7 @@ import { expect, test, type Page } from "@playwright/test";
|
||||
import { idle, jump, keys, settle, state } from "./helpers";
|
||||
|
||||
async function open(page: Page) {
|
||||
await page.goto("/doc/infinite-expand");
|
||||
await page.goto("/doc/infinispand");
|
||||
await page.waitForSelector("article");
|
||||
}
|
||||
|
||||
@@ -121,7 +121,7 @@ test("an outside agent edits over HTTP with the same ops, and the open page foll
|
||||
await open(page);
|
||||
const tree = await (await request.get("/api/tree/main")).json();
|
||||
// The tree is the whole library; its documents are the root's sections.
|
||||
expect(Object.values<any>(tree.nodes).filter((n) => n.parent === tree.root).map((n) => n.slug)).toContain("infinite-expand");
|
||||
expect(Object.values<any>(tree.nodes).filter((n) => n.parent === tree.root).map((n) => n.title)).toContain("Infinispand");
|
||||
const target = Object.values<any>(tree.nodes).find((n) => n.title === "The first document");
|
||||
expect(target).toBeTruthy();
|
||||
const res = await request.post("/api/ops/main", {
|
||||
|
||||
Reference in new issue
Block a user