chore(deps): PR #279 fixes + upgrade cypress 13 → 15#281
Merged
Conversation
Fixes flagged in PR 279 Copilot review: - drop duplicate EXPOSE and redundant distro ruby packages from Dockerfile - clean up ruby-build install.sh invocation (PREFIX env, not bogus positional) - mysqladmin healthcheck uses --password= so empty DB_PASSWORD doesn't prompt - drop redundant gem install bundler / bundle install from CI (ruby/setup-ruby with bundler-cache handles it) - document E2E as a throwaway container (docker compose run --rm) so it doesn't collide with the main web service Dev stack improvements (more Sail-like): - APP_PORT / FORWARD_DB_PORT support for port forwarding (defaults preserved) - faster db healthcheck polling (interval 2s, start_period 30s) so the stack comes up in seconds instead of waiting 30s between probes - wait-on promoted to a real devDependency (no more npx download on every run) and bumped timeout to 60s to absorb rails boot - cypress_cache named volume so the cypress binary persists and is shared with throwaway run --rm containers - README documents combined dev + test DB setup, explains headless vs interactive E2E, and covers a host-side test server sidecar on port 3001 for running cypress interactively without flipping RAILS_ENV on the dev stack
- cypress: ^13.17.0 → ^15.13.1 - cypress-real-events: ^1.13.0 → ^1.15.0 - eslint-plugin-cypress: ^4.1.0 → ^6.3.0 Primary motivation: Cypress 13's bundled Electron ~27 hangs on the spec-list screen when opening the UI on recent macOS. Cypress 15 ships Electron 37, which resolves the hang. Also picks up two majors of upstream fixes and security updates. Node 22 already satisfies Cypress 15's Node 20+ requirement. No code changes were required: no use of removed/renamed APIs (cy.exec().code, SelectorPlayground, Webpack preprocessor, etc.), and the only cy.origin spec (happyPath.cy.ts) crosses registrable domains so Cypress 14's injectDocumentDomain default flip is a no-op for us.
The cypress_cache volume previously hardcoded /home/vscode/.cache/Cypress.
The Dockerfile already parameterizes the container user via ARG USERNAME
(default vscode), but compose couldn't follow if anyone ever built with
--build-arg USERNAME=other.
Using ${USERNAME:-vscode} directly would collide with the host shell's
$USERNAME (typically set to the host user on Linux), so we use the
APP_USER namespace instead — matches the existing APP_PORT /
FORWARD_DB_PORT pattern in this compose file.
Default behavior unchanged: /home/vscode/.cache/Cypress.
jxjj
marked this pull request as ready for review
April 15, 2026 00:00
There was a problem hiding this comment.
Pull request overview
Upgrades the end-to-end testing toolchain (Cypress 13 → 15) and adjusts the dev Docker stack/docs to support newer macOS/Electron behavior and smoother local Cypress usage.
Changes:
- Bump
cypress,cypress-real-events, andeslint-plugin-cypress(plus lockfile updates) and addwait-onas an explicit dev dependency. - Tweak Dockerfile/compose for dev ergonomics (Ruby install cleanup, Cypress cache volume/ownership, port/env var normalization, improved DB healthcheck).
- Update README Cypress guidance, including a “run Cypress from host against a containerized test server” workflow.
Reviewed changes
Copilot reviewed 4 out of 5 changed files in this pull request and generated 3 comments.
Show a summary per file
| File | Description |
|---|---|
| package.json | Upgrades Cypress-related deps; increases wait-on timeout; adds wait-on dependency. |
| package-lock.json | Lockfile updates for Cypress 15 and transitive dependency changes. |
| docker/Dockerfile | Ruby install cleanup and pre-creates Cypress cache directory for correct volume ownership. |
| docker-compose.yml | Improves DB healthcheck, parameterizes ports, and adds a named Cypress cache volume. |
| README.md | Updates dev/test instructions, especially for running Cypress headlessly vs from host. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
cmcfadden
approved these changes
Apr 15, 2026
- bind test:e2e:server to 0.0.0.0:3000 so host-run Cypress can reach the containerized Rails server through published port mapping - clarify README: headless container section now covers both devcontainer shell and docker compose exec workflows
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
npm run cypress:openlaunched the UI but the spec list never loaded — consistent with Cypress 13's bundled Electron 27 misbehaving on recent macOS. Cypress 15 ships Electron 37, which renders correctly.cypress13.17 → 15.13,cypress-real-events1.13 → 1.15, andeslint-plugin-cypress4.1 → 6.3.