Skip to content

CI: Implement Automated Quality Gate for Tests and Linting #287

Description

@kunalverma2512

Description

Background & Motivation

Currently, our repository relies on manual verification and the honor system to ensure that new Pull Requests do not break existing functionality or introduce code style violations. As the project scales, this manual overhead is unsustainable and error-prone. A single unformatted file or broken unit test merged into main can degrade the overall codebase health and developer velocity.

Impact of Not Resolving

Without an automated gate, regressions will inevitably reach production. Reviewers will waste valuable time pointing out missing semicolons, unused variables, or failing tests rather than focusing on architectural logic and security.

Required Work

Implement a GitHub Actions workflow that automatically runs on pull_request and push to the main branch.

  • Checkout the repository and setup Node.js.
  • Install dependencies for both frontend and backend using a frozen lockfile strategy (npm ci).
  • Run npm run lint across the repository to enforce ESLint and Prettier standards.
  • Run npm test across the repository to execute the vitest (frontend) and node:test (backend) suites.
  • The workflow must explicitly fail and block the PR from being merged if either the linter or tests fail.

Metadata

Metadata

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions