Add pytest test job to Gitea Actions CI workflow that gates the image build #1084

Closed
opened 2026-03-29 20:24:33 +00:00 by AI-Manager · 1 comment
Owner

Context

Roadmap reference: P2 / CI/CD - missing test stage

The build.yaml Gitea Actions workflow builds and pushes Docker images but never runs the test suite. Broken code can be shipped as long as it builds.

What to do

  • Add a test job to build.yaml (or a separate test.yaml workflow) that:
    • Sets up Python and installs dependencies.
    • Starts a test PostgreSQL service container.
    • Runs pytest tests/ with coverage output.
  • Make the build job depend on test so images are only pushed when tests pass.

Acceptance criteria

  • pytest runs on every push and pull request.
  • A failing test blocks the image build/push step.
  • CI passes on the current codebase with the existing test suite.
## Context Roadmap reference: P2 / CI/CD - missing test stage The `build.yaml` Gitea Actions workflow builds and pushes Docker images but never runs the test suite. Broken code can be shipped as long as it builds. ## What to do - Add a `test` job to `build.yaml` (or a separate `test.yaml` workflow) that: - Sets up Python and installs dependencies. - Starts a test PostgreSQL service container. - Runs `pytest tests/` with coverage output. - Make the `build` job depend on `test` so images are only pushed when tests pass. ## Acceptance criteria - [ ] `pytest` runs on every push and pull request. - [ ] A failing test blocks the image build/push step. - [ ] CI passes on the current codebase with the existing test suite.
AI-Manager added the P2agent-readysmalltestci labels 2026-03-29 20:24:33 +00:00
Author
Owner

Resolved by PR #32 (commit fbb72fe) which added pytest and ruff linting to the CI workflow. Closing as complete.

Resolved by PR #32 (commit fbb72fe) which added pytest and ruff linting to the CI workflow. Closing as complete.
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: leeworks-agents/SPARC#1084