Harden real-runtime workflow validation

This commit is contained in:
vorotamoroz
2026-08-31 00:35:29 +00:00
parent 3a23b7a6b0
commit 9a28d46287
8 changed files with 72 additions and 42 deletions
+12 -7
View File
@@ -38,7 +38,12 @@ export function modalByTitle(page: Page, title: string): Locator {
}
export async function captureGuideDialogue(port: number, filename: string, title: string): Promise<string> {
return await captureObsidianElement(port, filename, (page) => modalByTitle(page, title).locator(".modal").first());
return await captureObsidianElement(
port,
filename,
(page) => modalByTitle(page, title).locator(".modal").first(),
uiTimeoutMs
);
}
export async function assertVerticalActionLayout(port: number, title: string): Promise<void> {
@@ -182,16 +187,16 @@ export async function captureAndStartInitialisation(
? "Setup Complete: Preparing This P2P Device"
: p2pAdditionalDevice
? "Setup Complete: Preparing to Fetch from Another Device"
: mode === "new"
? "Setup Complete: Preparing to Initialise Server"
: "Setup Complete: Preparing to Fetch Synchronisation Data";
: mode === "new"
? "Setup Complete: Preparing to Initialise Server"
: "Setup Complete: Preparing to Fetch Synchronisation Data";
const button = p2pFirstDevice
? "Restart and Prepare This Device"
: p2pAdditionalDevice
? "Restart and Select Source Device"
: mode === "new"
? "Restart and Initialise Server"
: "Restart and Fetch Data";
: mode === "new"
? "Restart and Initialise Server"
: "Restart and Fetch Data";
if (p2pAdditionalDevice) {
await withObsidianPage(port, async (page) => {
const modal = modalByTitle(page, title);