Skip to content

[AgentOps] Standalone prod Docker + GitHub App integration fixes #896

[AgentOps] Standalone prod Docker + GitHub App integration fixes

[AgentOps] Standalone prod Docker + GitHub App integration fixes #896

Workflow file for this run

name: Tests
on:
push:
branches: [main]
pull_request:
merge_group:
workflow_dispatch:
concurrency:
group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }}
cancel-in-progress: ${{ startsWith(github.ref, 'refs/pull/') }}
permissions:
contents: read
jobs:
# ---------------------------------------------------------------------------
# Lint
# ---------------------------------------------------------------------------
lint:
name: Lint
runs-on: ubuntu-24.04
steps:
- uses: actions/checkout@v4
- name: Install uv
uses: astral-sh/setup-uv@v6
with:
python-version: "3.11"
- name: Install dependencies
run: uv sync --dev
- name: Ruff check
run: uv run ruff check .
- name: Ruff format check
run: uv run ruff format --check .
# ---------------------------------------------------------------------------
# Backend unit tests (tests/)
# ---------------------------------------------------------------------------
backend-tests:
name: Backend Tests
runs-on: ubuntu-24.04
needs: [lint]
steps:
- uses: actions/checkout@v4
- name: Install uv
uses: astral-sh/setup-uv@v6
with:
python-version: "3.11"
- name: Install dependencies
run: uv sync --dev
- name: Run backend tests with coverage
timeout-minutes: 15
run: |
uv run coverage run -m pytest tests/ --durations=10
uv run coverage xml -o coverage-backend.xml
uv run coverage report
- name: Upload coverage artifact
uses: actions/upload-artifact@v4
with:
name: coverage-backend
path: coverage-backend.xml
# ---------------------------------------------------------------------------
# Coverage summary
# ---------------------------------------------------------------------------
coverage:
name: Coverage Report
runs-on: ubuntu-24.04
needs: [backend-tests]
if: needs.backend-tests.result == 'success'
steps:
- uses: actions/checkout@v4
- name: Download coverage artifact
uses: actions/download-artifact@v4
with:
name: coverage-backend
- name: Summarize coverage
uses: irongut/CodeCoverageSummary@v1.3.0
with:
filename: coverage-backend.xml
badge: true
format: markdown
output: both
hide_complexity: true
- name: Print coverage summary
run: cat code-coverage-results.md >> "$GITHUB_STEP_SUMMARY"