Compare commits

...
Author SHA1 Message Date
pedrooot c3546bf7da test(ui): settle attack-paths viewport before finding click 2026-10-22 01:17:58 +02:00
2 changed files with 6 additions and 3 deletions

No files matched your search

@@ -632,8 +632,9 @@ describe("auto-fitting the viewport", () => {
await graph.executeQuery();
await graph.waitForGraphStable(3);
await graph.expandAllFindings();
const beforeFilter = graph.viewportTransform;
// Expanding starts its own fit; settle it so the click targets a still node
// and the change below can only come from the filtered-view fit.
const beforeFilter = await graph.waitForViewportSettled();
expect(beforeFilter).toBeTruthy();
await graph.clickFirstFindingNode();
+3 -1
View File
@@ -96,7 +96,9 @@ export default defineConfig(() => {
// vertically and ends up overlapping the graph, so Playwright
// can't click nodes. Use a standard desktop viewport.
viewport: { width: 1280, height: 800 },
provider: playwright(),
// Playwright waits forever for an actionable element by default;
// fail inside the test budget so the log names the blocker.
provider: playwright({ actionTimeout: 10_000 }),
headless: true,
instances: [{ browser: "chromium" }],
},