Tests: shared helpers once in helpers.ts, not copied into each spec
- The panes view's pane, tid, frames, still, library, clickOpen and noFaults were copied into colours, panes3, panes4 (and partly forks, libraries, phone) with identical bodies; wide() into annotate and links; linksHere into review and reviewer; the one-key-per-frame loop of the latency tests into six specs (paced). They live in helpers.ts. The specs whose own still() or open() differ keep theirs. - `:` + type + Enter written out where command() does the same, the newDoc alias of addTop, nodes' copy of focusedTitle, forks.test's four isStr guards, an unused fixture and `void request`, Math.max(x, x). - panes3 and panes4 no longer call themselves rounds three and four. 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
52cb7c2065
commit
dbbe3effac
18 files changed
+176
-297
No files matched your search
@@ -5,17 +5,10 @@
|
||||
* again in a later revision, or listed as detached when its words are gone.
|
||||
*/
|
||||
import { expect, test, type Page } from "@playwright/test";
|
||||
import { autoLayout, command, idle, jump, keys, seedLinks, selected, settle, state, visit } from "./helpers";
|
||||
import { command, idle, jump, keys, seedLinks, selected, settle, state, visit, wide } from "./helpers";
|
||||
|
||||
const panes = (page: Page) => page.locator(".strip .pane");
|
||||
|
||||
async function wide(page: Page, path = "Fixed points") {
|
||||
await page.setViewportSize({ width: 1920, height: 1080 });
|
||||
await autoLayout(page);
|
||||
await visit(page, path);
|
||||
await page.waitForSelector(".strip .pane");
|
||||
await page.evaluate(() => document.fonts.ready);
|
||||
}
|
||||
async function column(page: Page, path: string) {
|
||||
await page.setViewportSize({ width: 1440, height: 900 });
|
||||
// After wide(), this page's layout follows the window, and 1440 px is wide enough for panes.
|
||||
|
||||
Reference in new issue
Block a user