name: CI on: push: branches: [main] pull_request: jobs: check: runs-on: ubuntu-latest services: mysql: image: mysql:8.4 env: MYSQL_ROOT_PASSWORD: rootpassword MYSQL_DATABASE: v2x_test MYSQL_USER: v2x MYSQL_PASSWORD: v2xpassword ports: - 3306:3306 options: >- --health-cmd="mysqladmin ping -h 127.0.0.1 -uroot -prootpassword" --health-interval=5s --health-timeout=5s --health-retries=20 env: # CI reaches MySQL over the mapped port; Keycloak is never contacted # because the auth tests mint their own tokens against a stub JWKS. DATABASE_URL: mysql+asyncmy://v2x:v2xpassword@127.0.0.1:3306/v2x_test?charset=utf8mb4 TEST_DATABASE_URL: mysql+asyncmy://v2x:v2xpassword@127.0.0.1:3306/v2x_test?charset=utf8mb4 APP_ENV: test steps: - uses: actions/checkout@v4 - uses: astral-sh/setup-uv@v5 with: version: "0.9.7" enable-cache: true - run: uv sync --frozen - name: Lint run: | uv run ruff check . uv run ruff format --check . - name: Type check run: uv run mypy - name: Test run: uv run pytest --cov --cov-report=term-missing