YC (S26) | Open Computer History | Continuously record your company computer work, map your workflows, help you find work worth automating, and power your agents' context
Rust agentsagiaiai-memoryaudio-recordingcomputer-visionhermeshermes-agentllmlocal-ailocal-firstmachine-learningmcpmultimodalopenclawprivacyrewindscreen-recordingspeech-to-textycombinator
test(e2e): cover Windows retention confirmation UX
Louis Beaumont65ac03549477
diff --git a/apps/screenpipe-app-tauri/components/settings/retention-settings.tsx b/apps/screenpipe-app-tauri/components/settings/retention-settings.tsxindex d692d1f8c..e256d683c 100644--- a/apps/screenpipe-app-tauri/components/settings/retention-settings.tsx+++ b/apps/screenpipe-app-tauri/components/settings/retention-settings.tsx@@ -337,6 +337,7 @@ export function RetentionSettings() {<div className="space-y-2 pl-6"><ModeRow+ testId="retention-mode-media"checked={effective === "media"}recommendedicon={<Film className="h-4 w-4" />}@@ -345,6 +346,7 @@ export function RetentionSettings() {onClick={() => handleSelectMode("media")}/><ModeRow+ testId="retention-mode-all"checked={effective === "all"}icon={<Trash2 className="h-4 w-4" />}title="everything"@@ -352,6 +354,7 @@ export function RetentionSettings() {onClick={() => handleSelectMode("all")}/><ModeRow+ testId="retention-mode-off"checked={effective === "off"}title="off"body="keep everything forever. you'll need to monitor disk usage manually."@@ -425,7 +428,7 @@ export function RetentionSettings() {if (!open) setPendingRecent(null);}}>- <AlertDialogContent>+ <AlertDialogContent data-testid="retention-recent-delete-dialog"><AlertDialogHeader><AlertDialogTitle>delete the last {pendingRecent} minutes?@@ -455,7 +458,7 @@ export function RetentionSettings() {if (!open) setPendingMode(null);}}>- <AlertDialogContent>+ <AlertDialogContent data-testid="retention-mode-confirm-dialog"><AlertDialogHeader><AlertDialogTitle>{pendingMode === "media"@@ -518,8 +521,9 @@ export function RetentionSettings() {</Select></div><AlertDialogFooter>- <AlertDialogCancel>cancel</AlertDialogCancel>+ <AlertDialogCancel data-testid="retention-mode-cancel">cancel</AlertDialogCancel><AlertDialogAction+ data-testid="retention-mode-confirm"onClick={confirmEnable}className={pendingMode === "all"@@ -543,6 +547,7 @@ function ModeRow({recommended,icon,onClick,+ testId,}: {checked: boolean;title: string;@@ -550,10 +555,12 @@ function ModeRow({recommended?: boolean;icon?: React.ReactNode;onClick: () => void;+ testId?: string;}) {return (<buttontype="button"+ data-testid={testId}onClick={onClick}className={`w-full text-left flex gap-3 rounded border p-2.5 transition-colors ${checkeddiff --git a/apps/screenpipe-app-tauri/e2e/README.md b/apps/screenpipe-app-tauri/e2e/README.mdindex aa0a55037..8948c0f73 100644--- a/apps/screenpipe-app-tauri/e2e/README.md+++ b/apps/screenpipe-app-tauri/e2e/README.md@@ -162,7 +162,7 @@ Saves to `e2e/videos/`.| `timeline.spec.ts` | Navigates to Timeline; seeds a capture event; verifies at least one frame renders || `windows-core-recording.spec.ts` | Windows opt-in. Enables real vision recording and requires API auth, health/load, audio/device, vision, and search endpoints to stay responsive. In CI it uses `SCREENPIPE_E2E_SEED=onboarding,no-audio` so hosted runners exercise OCR without booting Whisper. When the runner exposes usable desktop frames, it also shows a foreground marker window and verifies OCR indexing/query search plus Timeline frame metadata, visible scrubber clicks, and arrow-key frame stepping; hosted runners without frames self-skip those capture-dependent assertions. || `windows-system-integration.spec.ts` | Windows-only. Verifies isolated data dir, native DLL/WebView2 runtime, display/DPI topology, localhost-only API binding, process health, Defender visibility, audio service/device health, concurrent local API load, focus churn, rapid Home-window routing, Home close/reopen backend survival, and absence of Windows crash-report events during the suite |-| `windows-user-journey.spec.ts` | Windows-only. Drives Home search button -> floating Search input -> Timeline -> Home, and opens Recording settings to reveal Windows audio troubleshooting controls from the real UI |+| `windows-user-journey.spec.ts` | Windows-only. Drives Home search button -> floating Search input -> Timeline -> Home, opens Recording settings to reveal Windows audio troubleshooting controls, and previews the Storage retention safety confirmation without applying destructive cleanup || `hd-recording-pipeline.spec.ts` | macOS opt-in. Starts an HD timer session via `/capture/hd/start`; asserts the controller goes active, a non-empty `hd_*.mp4` chunk is written, and OCR keeps indexing during HD (high-fps + indexing decouple, #3699/#3707) || `settings-sections.spec.ts` | Navigates General → Recording → AI → Speakers settings; verifies content and no crash || `audio-fallback.spec.ts` | macOS opt-in spec for the Screenpipe Cloud → local Whisper fallback alert and `/notify` history |diff --git a/apps/screenpipe-app-tauri/e2e/specs/windows-user-journey.spec.ts b/apps/screenpipe-app-tauri/e2e/specs/windows-user-journey.spec.tsindex 8c76c09ae..99fe008c8 100644--- a/apps/screenpipe-app-tauri/e2e/specs/windows-user-journey.spec.ts+++ b/apps/screenpipe-app-tauri/e2e/specs/windows-user-journey.spec.ts@@ -245,4 +245,59 @@ describe("Windows user journey", function () {}}});++ it("opens Storage settings and previews local retention before cancelling", async function () {+ if (!isWindows) this.skip();++ await openHomeWindow();++ const settingsNav = await $('[data-testid="nav-settings"]');+ await settingsNav.waitForDisplayed({ timeout: t(15_000) });+ await settingsNav.click();++ const storageNav = await $('[data-testid="settings-nav-storage"]');+ await storageNav.waitForDisplayed({ timeout: t(15_000) });+ await storageNav.click();++ await waitForBodyText(+ (bodyText) =>+ bodyText.includes("local disk, cloud archive, and sync") &&+ bodyText.includes("auto-delete old data") &&+ bodyText.includes("video + audio only"),+ "Storage settings did not show the local retention controls",+ );++ const mediaRetentionMode = await $('[data-testid="retention-mode-media"]');+ await mediaRetentionMode.waitForExist({ timeout: t(20_000) });+ await mediaRetentionMode.scrollIntoView();+ await mediaRetentionMode.click();++ const confirmation = await $('[data-testid="retention-mode-confirm-dialog"]');+ await confirmation.waitForDisplayed({ timeout: t(20_000) });++ await waitForBodyText(+ (bodyText) =>+ bodyText.includes("enable media eviction?") &&+ bodyText.includes("screenpipe will delete video and audio files") &&+ bodyText.includes("transcripts, ocr text") &&+ bodyText.includes("enable eviction"),+ "Retention confirmation dialog did not explain the media eviction safety tradeoff",+ );++ const cancel = await $('[data-testid="retention-mode-cancel"]');+ await cancel.waitForDisplayed({ timeout: t(10_000) });+ await cancel.click();++ await browser.waitUntil(+ async () => !(await $('[data-testid="retention-mode-confirm-dialog"]').isExisting().catch(() => false)),+ {+ timeout: t(10_000),+ interval: 250,+ timeoutMsg: "Retention confirmation dialog stayed open after cancel",+ },+ );++ const retentionScreenshot = await saveScreenshot("windows-user-journey-storage-retention");+ expect(existsSync(retentionScreenshot)).toBe(true);+ });});