Skip to content

ci(frontend): run the frontend test suite in CI - #24

Merged
GravityDarkLab merged 1 commit into
mainfrom
ci/frontend-test-job
Sep 11, 2026
Merged

GravityDarkLab merged 1 commit into
mainfrom
ci/frontend-test-job

Conversation

@GravityDarkLab

Copy link
Copy Markdown
Owner

What changed

  • New Test (frontend) job in CI — Frontend: bun run test in frontend/ (vitest, 276 tests). Mirrors the API workflow's Test job exactly — pinned actions/checkout@v7.0.0, oven-sh/setup-bun with Bun 1.4.2, the same actions/cache key, bun install --frozen.
  • The frontend Docker build job now also needs: test, matching how the API workflow gates its image on its tests.

Why

The frontend workflow only type-checked and built — its test suite never ran in CI, so a frontend regression could merge with every check green.

Why the distinct name

Required status checks are matched by job name. Test is already the API workflow's required check, so a second job with that name couldn't be told apart in branch protection. Note the same ambiguity already exists for Type-check and Docker build, which both workflows define.

Follow-up (needs a repo-settings change — not done here)

To make this blocking, add Test (frontend) to the required checks on main once this merges:

gh api -X POST repos/GravityDarkLab/Ons/branches/main/protection/required_status_checks/contexts -f 'contexts[]=Test (frontend)'

Testing

  • Same commands locally: bun install --frozenbun run test in frontend/ — 28 files, 276 tests passed.
  • New job passes in this PR's checks.

🤖 Generated with Claude Code

CI — Frontend only type-checked and built, so the 276 vitest tests never
ran on PRs and a frontend regression could merge green. Adds a test job
mirroring the API workflow's (same pinned actions, Bun 1.4.2, bun cache,
frozen install), and gates the frontend Docker build on it like the API
workflow does.

Named "Test (frontend)" rather than "Test": required status checks match
on job name, and "Test" is already the API workflow's required check.
Copilot AI lite review requested due to automatic review settings September 11, 2026 17:16

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

🟢 Approval recommended

No unresolved review comments remain.

Pull request overview

Adds frontend test execution to CI and gates the frontend Docker build on successful tests.

Changes:

  • Adds a Test (frontend) job using Bun and Vitest.
  • Updates Docker build dependencies to include frontend tests.
File summaries
File Summary
.github/workflows/ci-frontend.yml Adds frontend testing and test-gated Docker builds.
Review details
  • Files reviewed: 1/1 changed files
  • Comments generated: 0
  • Review effort level: Lite

💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.

@GravityDarkLab
GravityDarkLab merged commit d10a2b5 into main Sep 11, 2026
14 checks passed
@GravityDarkLab
GravityDarkLab deleted the ci/frontend-test-job branch September 11, 2026 17:20
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.

2 participants