Add a CI workflow that runs the checks and tests on every push #100

Closed
opened 2026-10-09 15:37:29 -04:00 by goddard · 1 comment
Collaborator

Nothing runs the checks or tests automatically, so a breakage is only caught when someone runs them locally.

  • No branch has ever had a workflow file under .gitea/workflows or .github/workflows, even though Actions is enabled on the repo.
  • #49 ("add actions to repo") was closed on 2026-09-27 without a workflow being added.
  • package.json:14-28 already has everything CI needs: npm run check (style check and svelte-check), npm test (its pretest step builds the report and launch bundles) and npm run test:agent (the Python agent tests).
  • In a fresh clone the test build fails until svelte-kit sync has run. npm run check runs it, so it has to come before npm test.

Fix

  • Add a Gitea Actions workflow that runs npm ci, npm run check, npm test and npm run test:agent on pushes and pull requests
  • Run npm run build in the same workflow so the Docker build step is covered
  • Add the lint step from #77 once it lands
Nothing runs the checks or tests automatically, so a breakage is only caught when someone runs them locally. - No branch has ever had a workflow file under `.gitea/workflows` or `.github/workflows`, even though Actions is enabled on the repo. - #49 ("add actions to repo") was closed on 2026-09-27 without a workflow being added. - `package.json:14-28` already has everything CI needs: `npm run check` (style check and svelte-check), `npm test` (its pretest step builds the report and launch bundles) and `npm run test:agent` (the Python agent tests). - In a fresh clone the test build fails until `svelte-kit sync` has run. `npm run check` runs it, so it has to come before `npm test`. **Fix** - [x] Add a Gitea Actions workflow that runs `npm ci`, `npm run check`, `npm test` and `npm run test:agent` on pushes and pull requests - [x] Run `npm run build` in the same workflow so the Docker build step is covered - [x] Add the lint step from #77 once it lands
goddard added the
priority
low
type/maintainability
labels 2026-10-09 15:37:29 -04:00
josh was assigned by goddard 2026-10-09 15:37:29 -04:00
Author
Collaborator

Reviewed 5cf284f413. The workflow runs every check, the build and lint, and its first run on this commit passed, so I'm closing this.

Checklist

  • Workflow runs the checks and tests on pushes and pull requests. .gitea/workflows/ci.yml triggers on push and pull_request, then runs npm ci, npm run check, npm test and npm run test:agent in a node:22-bookworm container. npm run check runs before the tests, so svelte-kit sync has already run in the fresh checkout. Run 835 passed every step on this commit. svelte-check found 0 errors and 0 warnings, the app tests passed (208 files, 2,629 tests), and the agent tests passed (285 tests).
  • Run npm run build. The last step runs the same npm run build as the Dockerfile, including agent packaging and the report and launch bundles. It passed in run 835.
  • Add the lint step from #77. npm run lint runs after the type check, and run 835 reports that all files match Prettier and ESLint passes.

Review notes

  • VITEST_MAX_WORKERS: '2' takes effect: Vitest 4.1.11 reads that variable into maxWorkers. The test step took about 3 minutes on the runner, and the whole job took about 5.
  • The development guide now describes the workflow and its runner requirements: Docker jobs with the ubuntu-latest label.
  • Minor and non-blocking: a red run only blocks merges if main's branch protection requires the checks status. Goddard can't see branch protection settings, so I couldn't check whether it does.
Reviewed 5cf284f413b42f1c7ca7d94cd34b6a887aaba835. The workflow runs every check, the build and lint, and its first run on this commit passed, so I'm closing this. **Checklist** - [x] **Workflow runs the checks and tests on pushes and pull requests.** `.gitea/workflows/ci.yml` triggers on `push` and `pull_request`, then runs `npm ci`, `npm run check`, `npm test` and `npm run test:agent` in a `node:22-bookworm` container. `npm run check` runs before the tests, so `svelte-kit sync` has already run in the fresh checkout. [Run 835](https://gitea.thewrightserver.net/josh/electric-cherry/actions/runs/835) passed every step on this commit. svelte-check found 0 errors and 0 warnings, the app tests passed (208 files, 2,629 tests), and the agent tests passed (285 tests). - [x] **Run `npm run build`.** The last step runs the same `npm run build` as the Dockerfile, including agent packaging and the report and launch bundles. It passed in run 835. - [x] **Add the lint step from #77.** `npm run lint` runs after the type check, and run 835 reports that all files match Prettier and ESLint passes. **Review notes** - `VITEST_MAX_WORKERS: '2'` takes effect: Vitest 4.1.11 reads that variable into `maxWorkers`. The test step took about 3 minutes on the runner, and the whole job took about 5. - The development guide now describes the workflow and its runner requirements: Docker jobs with the `ubuntu-latest` label. - Minor and non-blocking: a red run only blocks merges if `main`'s branch protection requires the `checks` status. Goddard can't see branch protection settings, so I couldn't check whether it does.
Sign in to join this conversation.