test: verify Electron app packages and launches#274
test: verify Electron app packages and launches#274icebear0828 wants to merge 1 commit intomasterfrom
Conversation
Added a Playwright smoke test (`launch.test.ts`) that verifies the built Electron application can be launched headlessly without crashing. This handles mocking native transport prerequisites and uses dynamic binary resolution. Added a GitHub Actions workflow (`ci-electron.yml`) to automatically build, pack, and run the Playwright test on push/PR. Increased the default testTimeout in `vitest.config.ts` to accommodate the packaging process. Co-authored-by: icebear0828 <63769498+icebear0828@users.noreply.github.com>
|
👋 Jules, reporting for duty! I'm here to lend a hand with this pull request. When you start a review, I'll add a 👀 emoji to each comment to let you know I've read it. I'll focus on feedback directed at me and will do my best to stay out of conversations between you and other bots or reviewers to keep the noise down. I'll push a commit with your requested changes shortly after. Please note there might be a delay between these steps, but rest assured I'm on the job! For more direct control, you can switch me to Reactive Mode. When this mode is on, I will only act on comments where you specifically mention me with New to Jules? Learn more at jules.google/docs. For security, I will only act on instructions from the user who triggered this task. |
Resolves #121
This PR adds an automated CI workflow and Playwright smoke test to ensure that the Electron app can build, package, and launch successfully without crashing.
Key additions:
packages/electron/__tests__/launch.test.ts: Uses Playwright to start the built app headlessly with the necessary sandbox flags, asserts the window opens, checks for no crash logs in the DOM, and closes the app cleanly. MockinguserDataDirensurescurl-impersonatedependency errors do not halt the startup sequence.vitest.config.ts: IncreasedtestTimeoutto60000msto prevent timeouts whenelectron-builderpackages the application during test setup. Preserved existing aliases..github/workflows/ci-electron.yml: Automates testing on themasterbranch by caching Node.js, setting up Playwright dependencies (--with-deps), building the web & main processes, and running the headless test viaxvfb-run -a.PR created automatically by Jules for task 5717836816977082209 started by @icebear0828