Merge pull request #1 from ArshVermaGit/ArshVermaGit-main #3
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: Python CI | |
| on: | |
| push: | |
| branches: [main, develop] | |
| paths: | |
| - "**.py" | |
| - "pyproject.toml" | |
| - "requirements.txt" | |
| - ".github/workflows/python-ci.yml" | |
| pull_request: | |
| branches: [main] | |
| paths: | |
| - "**.py" | |
| - "pyproject.toml" | |
| - "requirements.txt" | |
| - ".github/workflows/python-ci.yml" | |
| jobs: | |
| test: | |
| name: Test Python | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v6 | |
| - name: Set up Python | |
| uses: actions/setup-python@v6 | |
| with: | |
| python-version: "3.12" | |
| cache: "pip" | |
| - name: Install dependencies | |
| run: | | |
| python -m pip install --upgrade pip | |
| if [ -f requirements.txt ]; then pip install -r requirements.txt; fi | |
| pip install pytest pytest-asyncio pytest-cov httpx pydantic structlog google-genai opentelemetry-api opentelemetry-sdk opentelemetry-exporter-otlp tenacity redis | |
| - name: Run tests | |
| run: | | |
| export AUTH_DISABLED=true | |
| python -m pytest tests/unit/ -v --tb=short | |
| - name: Lint check | |
| run: | | |
| pip install ruff black | |
| ruff check . | |
| black --check . |