Skip to content

feat: add mobile sidebar toggle functionality in file manager tests - #799

Merged
pikann merged 2 commits into
masterfrom
fix/fix-failed-e2e-file-testings
Nov 20, 2026
Merged

pikann merged 2 commits into
masterfrom
fix/fix-failed-e2e-file-testings

Conversation

@pikann

@pikann pikann commented Nov 20, 2026 •

Copy link
Copy Markdown
Contributor

Summary

Fixes the File manager › a project starts with its default folders, listed in the sidebar section e2e test, which failed on both mobile-chrome and mobile-safari in run 44574828689.

Cause

On mobile viewports the sidebar is collapsed behind a toggle, so the Files, Recent, Starred and Trash links are not in the DOM and toBeVisible() timed out.

Change

apps/e2e/tests/files/file-manager.spec.ts: when the viewport is 768px wide or less, click the "Toggle Sidebar" button before asserting the sidebar links. This is the same pattern ui/sidebar-navigation.spec.ts uses.

Not addressed

Other failures in that run look timing-related and are out of scope here: the board-performance CPU-blocking budgets on chromium, a WebKit dialog-close animation in projects/management.spec.ts, and a sessions.spec.ts timeout on mobile-safari.

Testing

Not yet run locally; needs the dedicated e2e docker stack on a mobile project.

@pullfrog pullfrog Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Important

The new toggle opens the mobile sidebar but never dismisses it, so the test still fails on mobile-chrome and mobile-safari at the next step. Details inline.

Approach: right idea — open the collapsed mobile sidebar before asserting its links — but incomplete, because the mobile sidebar is a modal Sheet that has to be closed before the test touches <main> again.

Reviewed changes — the single commit a0d7c48c touching apps/e2e/tests/files/file-manager.spec.ts:

  • Mobile sidebar toggle — detects a <= 768 viewport and clicks the Toggle Sidebar button before asserting the Files/Recent/Starred/Trash links, so the phone projects can see the collapsed sidebar's contents.

Pullfrog  | Fix all ➔ | Fix 👍s ➔ | View workflow run | Using deepseek-v4.1-flash-1017 (free via Pullfrog for OSS) | 𝕏

@pullfrog pullfrog Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

✅ No new issues found.

Approach: sound — the mobile sheet is opened only when the viewport is narrow, then dismissed with the same Escape + toBeHidden sequence docs.spec.ts already uses, so the rest of the test runs against an interactive <main>.

Reviewed changes — commit 74237e35 since the prior pullfrog review on a0d7c48c, touching apps/e2e/tests/files/file-manager.spec.ts:

  • Sidebar dismissal — after the Files/Recent/Starred/Trash link loop, mobile runs press Escape and await the Sidebar dialog hidden, removing the modal overlay/inert state that blocked the subsequent right-click on Task attachments.
  • isMobile hoisted — the viewport check is computed once, so the open and close steps share one condition.

The dialog name (Sidebar) and the Escape behaviour match the base-ui Sheet in apps/web/src/components/ui/sidebar.tsx and the established closeSidebarIfOpen helper, so the fix closes the loop on the reported failure.

Pullfrog  | View workflow run | Using deepseek-v4.1-flash-1017 (free via Pullfrog for OSS) | 𝕏

@pikann
pikann merged commit 8246c52 into master Nov 20, 2026
2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant